[asl] 45/177: Moving testPhysics to examples
Ghislain Vaillant
ghisvail-guest at moszumanska.debian.org
Thu Aug 27 09:22:37 UTC 2015
This is an automated email from the git hooks/post-receive script.
ghisvail-guest pushed a commit to branch master
in repository asl.
commit fab6bdc06356d27fd912c89e765c2275d363f6ed
Author: AvtechScientific <AvtechScientific at users.noreply.github.com>
Date: Mon Jun 22 11:52:07 2015 +0300
Moving testPhysics to examples
---
CMakeLists.txt | 1 +
{test/testPhysics => examples}/CMakeLists.txt | 0
.../elastic/CMakeLists.txt | 0
.../elastic/acousticWaves.cc | 0
.../elastic/cubeGravity.cc | 0
.../elastic/cubeIncompressibleGravity.cc | 0
.../elastic/cubePoroelasticGravity.cc | 0
.../elastic/poroelastic.cc | 0
{test/testPhysics => examples}/flow/CMakeLists.txt | 6 +--
{test/testPhysics => examples}/flow/bus_wind.cc | 0
{test/testPhysics => examples}/flow/compressor.cc | 0
{test/testPhysics => examples}/flow/flow.cc | 0
{test/testPhysics => examples}/flow/flow2.cc | 0
{test/testPhysics => examples}/flow/flow3.cc | 0
.../testPhysics => examples}/flow/flowKDPGrowth.cc | 0
.../flow/flowRotatingCylinders.cc | 0
.../flow/locomotive_in_tunnel.cc | 0
.../flow/locomotive_laminar.cc | 4 +-
.../flow/locomotive_stability.cc | 0
.../flow/multicomponent_flow.cc | 58 ++++++++++-----------
.../flow/multiphase_flow.cc | 0
.../flow/pitot_tube_ice.cc | 0
.../heatTransfer/CMakeLists.txt | 0
.../heatTransfer/surfaceFlux.cc | 0
{test => examples}/input_data/bus.stl | Bin
{test => examples}/input_data/locomotive.stl | Bin
.../jumpingObjects/CMakeLists.txt | 0
.../jumpingObjects/jumpingBox.cc | 0
.../levelSet/CMakeLists.txt | 0
.../levelSet/levelSetBasic.cc | 0
.../levelSet/levelSetFacetedGrowth.cc | 0
.../levelSet/levelSetNormalGrowth.cc | 0
.../massTransferSM/CMakeLists.txt | 0
.../massTransferSM/testSMDiff.cc | 0
.../massTransferSM/testSMDiff3C.cc | 0
.../massTransferSM/testSMPhi.cc | 0
.../massTransferSM/testSMPhiBV.cc | 0
test/CMakeLists.txt | 2 -
test/input_data/asl.ini | 8 ---
39 files changed, 35 insertions(+), 44 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 11bcda2..1f9a669 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -37,6 +37,7 @@ include_directories(SYSTEM ${OpenCL_INCLUDE_DIRS} ${Boost_INCLUDE_DIRS})
add_subdirectory(src)
add_subdirectory(test)
+add_subdirectory(examples)
add_subdirectory(doc)
# Packaging
diff --git a/test/testPhysics/CMakeLists.txt b/examples/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/CMakeLists.txt
rename to examples/CMakeLists.txt
diff --git a/test/testPhysics/elastic/CMakeLists.txt b/examples/elastic/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/elastic/CMakeLists.txt
rename to examples/elastic/CMakeLists.txt
diff --git a/test/testPhysics/elastic/acousticWaves.cc b/examples/elastic/acousticWaves.cc
similarity index 100%
rename from test/testPhysics/elastic/acousticWaves.cc
rename to examples/elastic/acousticWaves.cc
diff --git a/test/testPhysics/elastic/cubeGravity.cc b/examples/elastic/cubeGravity.cc
similarity index 100%
rename from test/testPhysics/elastic/cubeGravity.cc
rename to examples/elastic/cubeGravity.cc
diff --git a/test/testPhysics/elastic/cubeIncompressibleGravity.cc b/examples/elastic/cubeIncompressibleGravity.cc
similarity index 100%
rename from test/testPhysics/elastic/cubeIncompressibleGravity.cc
rename to examples/elastic/cubeIncompressibleGravity.cc
diff --git a/test/testPhysics/elastic/cubePoroelasticGravity.cc b/examples/elastic/cubePoroelasticGravity.cc
similarity index 100%
rename from test/testPhysics/elastic/cubePoroelasticGravity.cc
rename to examples/elastic/cubePoroelasticGravity.cc
diff --git a/test/testPhysics/elastic/poroelastic.cc b/examples/elastic/poroelastic.cc
similarity index 100%
rename from test/testPhysics/elastic/poroelastic.cc
rename to examples/elastic/poroelastic.cc
diff --git a/test/testPhysics/flow/CMakeLists.txt b/examples/flow/CMakeLists.txt
similarity index 89%
rename from test/testPhysics/flow/CMakeLists.txt
rename to examples/flow/CMakeLists.txt
index 2bf9e84..16e59b6 100644
--- a/test/testPhysics/flow/CMakeLists.txt
+++ b/examples/flow/CMakeLists.txt
@@ -21,9 +21,9 @@ add_executable(flowKDPGrowth flowKDPGrowth.cc)
target_link_libraries(flowKDPGrowth aslnum aslvtk asl)
set_property(TARGET flowKDPGrowth PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/flowKDPGrowth)
-add_executable(flowAroundObject flowAroundObject.cc)
-target_link_libraries(flowAroundObject aslnum aslvtk asl)
-set_property(TARGET flowAroundObject PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/flowAroundObject)
+add_executable(locomotive_laminar locomotive_laminar.cc)
+target_link_libraries(locomotive_laminar aslnum aslvtk asl)
+set_property(TARGET locomotive_laminar PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/locomotive_laminar)
add_executable(compressor compressor.cc)
target_link_libraries(compressor aslnum aslvtk asl)
diff --git a/test/testPhysics/flow/bus_wind.cc b/examples/flow/bus_wind.cc
similarity index 100%
rename from test/testPhysics/flow/bus_wind.cc
rename to examples/flow/bus_wind.cc
diff --git a/test/testPhysics/flow/compressor.cc b/examples/flow/compressor.cc
similarity index 100%
rename from test/testPhysics/flow/compressor.cc
rename to examples/flow/compressor.cc
diff --git a/test/testPhysics/flow/flow.cc b/examples/flow/flow.cc
similarity index 100%
rename from test/testPhysics/flow/flow.cc
rename to examples/flow/flow.cc
diff --git a/test/testPhysics/flow/flow2.cc b/examples/flow/flow2.cc
similarity index 100%
rename from test/testPhysics/flow/flow2.cc
rename to examples/flow/flow2.cc
diff --git a/test/testPhysics/flow/flow3.cc b/examples/flow/flow3.cc
similarity index 100%
rename from test/testPhysics/flow/flow3.cc
rename to examples/flow/flow3.cc
diff --git a/test/testPhysics/flow/flowKDPGrowth.cc b/examples/flow/flowKDPGrowth.cc
similarity index 100%
rename from test/testPhysics/flow/flowKDPGrowth.cc
rename to examples/flow/flowKDPGrowth.cc
diff --git a/test/testPhysics/flow/flowRotatingCylinders.cc b/examples/flow/flowRotatingCylinders.cc
similarity index 100%
rename from test/testPhysics/flow/flowRotatingCylinders.cc
rename to examples/flow/flowRotatingCylinders.cc
diff --git a/test/testPhysics/flow/locomotive_in_tunnel.cc b/examples/flow/locomotive_in_tunnel.cc
similarity index 100%
rename from test/testPhysics/flow/locomotive_in_tunnel.cc
rename to examples/flow/locomotive_in_tunnel.cc
diff --git a/test/testPhysics/flow/flowAroundObject.cc b/examples/flow/locomotive_laminar.cc
similarity index 98%
rename from test/testPhysics/flow/flowAroundObject.cc
rename to examples/flow/locomotive_laminar.cc
index 30768a3..bd4e5d1 100644
--- a/test/testPhysics/flow/flowAroundObject.cc
+++ b/examples/flow/locomotive_laminar.cc
@@ -22,7 +22,7 @@
/**
- \example flow.cc
+ \example locomotive_laminar.cc
*/
#include <utilities/aslUValue.h>
@@ -85,7 +85,7 @@ int main()
std::cout<<"Flow: Data initialization...";
- auto object(asl::readSurface("train1.stl", bl));
+ auto object(asl::readSurface("locomotive.stl", bl));
asl::Block block(object->getInternalBlock());
diff --git a/test/testPhysics/flow/locomotive_stability.cc b/examples/flow/locomotive_stability.cc
similarity index 100%
rename from test/testPhysics/flow/locomotive_stability.cc
rename to examples/flow/locomotive_stability.cc
diff --git a/test/testPhysics/flow/multicomponent_flow.cc b/examples/flow/multicomponent_flow.cc
similarity index 78%
rename from test/testPhysics/flow/multicomponent_flow.cc
rename to examples/flow/multicomponent_flow.cc
index 23d57a7..78c7dee 100644
--- a/test/testPhysics/flow/multicomponent_flow.cc
+++ b/examples/flow/multicomponent_flow.cc
@@ -69,9 +69,9 @@ class Parameters
asl::Parameter<double> pumpL;
asl::Parameter<double> pumpD;
- asl::Parameter<double> oilInVel;
- asl::Parameter<double> waterInVel;
- asl::Parameter<double> gasInVel;
+ asl::Parameter<double> component2InVel;
+ asl::Parameter<double> component1InVel;
+ asl::Parameter<double> component3InVel;
void load(int argc, char * argv[],
@@ -93,9 +93,9 @@ Parameters::Parameters():
tubeD(0.05, "tubeD", "tube's diameter"),
pumpL(0.025, "pumpL", "pump's length"),
pumpD(0.03, "pumpD", "pump's diameter"),
- oilInVel(0.08, "oil_in_velocity", "flow velocity in the oil input"),
- waterInVel(0.16, "water_in_velocity", "flow velocity in the water input"),
- gasInVel(0.1, "gas_in_velocity", "flow velocity in the gas input")
+ component1InVel(0.16, "component1_in_velocity", "flow velocity in the component1 input"),
+ component2InVel(0.08, "component2_in_velocity", "flow velocity in the component2 input"),
+ component3InVel(0.1, "component3_in_velocity", "flow velocity in the component3 input")
{
}
@@ -157,10 +157,10 @@ int main(int argc, char *argv[])
auto mcfMapMem(asl::generateDataContainerACL_SP<FlT>(block, 1, 1u));
asl::initData(mcfMapMem, generateMixer(block, params));
- auto waterFrac(asl::generateDataContainerACL_SP<FlT>(block, 1, 1u));
- asl::initData(waterFrac, 0);
- auto gasFrac(asl::generateDataContainerACL_SP<FlT>(block, 1, 1u));
- asl::initData(gasFrac, 0);
+ auto component1Frac(asl::generateDataContainerACL_SP<FlT>(block, 1, 1u));
+ asl::initData(component1Frac, 0);
+ auto component3Frac(asl::generateDataContainerACL_SP<FlT>(block, 1, 1u));
+ asl::initData(component3Frac, 0);
std::cout<<"Finished"<<endl;
@@ -178,10 +178,10 @@ int main(int argc, char *argv[])
lbgkUtil->initF(acl::generateVEConstant(.0, .0, .0));
auto flowVel(lbgk->getVelocity());
- auto nmWater(asl::generateFDAdvectionDiffusion(waterFrac, 0.01, flowVel, templ, true));
- nmWater->init();
- auto nmGas(asl::generateFDAdvectionDiffusion(gasFrac, 0.01, flowVel, templ));
- nmGas->init();
+ auto nmcomponent1(asl::generateFDAdvectionDiffusion(component1Frac, 0.01, flowVel, templ, true));
+ nmcomponent1->init();
+ auto nmcomponent3(asl::generateFDAdvectionDiffusion(component3Frac, 0.01, flowVel, templ));
+ nmcomponent3->init();
std::vector<asl::SPNumMethod> bc;
std::vector<asl::SPNumMethod> bcV;
@@ -190,24 +190,24 @@ int main(int argc, char *argv[])
bc.push_back(generateBCNoSlip(lbgk, mcfMapMem));
bc.push_back(generateBCConstantPressure(lbgk,1.,{asl::ZE}));
bc.push_back(generateBCConstantPressureVelocity(lbgk, 1.,
- makeAVec(0.,0.,params.oilInVel.v()),
+ makeAVec(0.,0.,params.component2InVel.v()),
{asl::Z0}));
bc.push_back(generateBCConstantPressureVelocity(lbgk, 1.,
- makeAVec(0.,-params.waterInVel.v(),0.),
+ makeAVec(0.,-params.component1InVel.v(),0.),
{asl::YE}));
bc.push_back(generateBCConstantPressureVelocity(lbgk,1.,
- makeAVec(0.,params.gasInVel.v(),0.),
+ makeAVec(0.,params.component3InVel.v(),0.),
{asl::Y0}));
bcDif.push_back(generateBCNoSlipVel(lbgk, mcfMapMem));
- bc.push_back(generateBCConstantGradient(waterFrac, 0., mcfMapMem, templ));
- bc.push_back(generateBCConstantGradient(gasFrac, 0., mcfMapMem, templ));
- bc.push_back(generateBCConstantValue(waterFrac, 1., {asl::YE}));
- bc.push_back(generateBCConstantValue(gasFrac, 0., {asl::YE, asl::Z0, asl::ZE}));
- bc.push_back(generateBCConstantValue(waterFrac, 0., {asl::Y0, asl::Z0, asl::ZE}));
- bc.push_back(generateBCConstantValue(gasFrac, 1., {asl::Y0}));
-// bc.push_back(generateBCConstantGradient(waterFrac, 0.,templ, {asl::ZE}));
-// bc.push_back(generateBCConstantGradient(gasFrac, 0.,templ, {asl::ZE}));
+ bc.push_back(generateBCConstantGradient(component1Frac, 0., mcfMapMem, templ));
+ bc.push_back(generateBCConstantGradient(component3Frac, 0., mcfMapMem, templ));
+ bc.push_back(generateBCConstantValue(component1Frac, 1., {asl::YE}));
+ bc.push_back(generateBCConstantValue(component3Frac, 0., {asl::YE, asl::Z0, asl::ZE}));
+ bc.push_back(generateBCConstantValue(component1Frac, 0., {asl::Y0, asl::Z0, asl::ZE}));
+ bc.push_back(generateBCConstantValue(component3Frac, 1., {asl::Y0}));
+// bc.push_back(generateBCConstantGradient(component1Frac, 0.,templ, {asl::ZE}));
+// bc.push_back(generateBCConstantGradient(component3Frac, 0.,templ, {asl::ZE}));
initAll(bc);
initAll(bcDif);
@@ -219,8 +219,8 @@ int main(int argc, char *argv[])
asl::WriterVTKXML writer("multicomponent_flow");
writer.addScalars("map", *mcfMapMem);
- writer.addScalars("water", *waterFrac);
- writer.addScalars("gas", *gasFrac);
+ writer.addScalars("component1", *component1Frac);
+ writer.addScalars("component3", *component3Frac);
writer.addScalars("rho", *lbgk->getRho());
writer.addVector("v", *flowVel);
@@ -235,8 +235,8 @@ int main(int argc, char *argv[])
{
lbgk->execute();
executeAll(bcDif);
- nmWater->execute();
- nmGas->execute();
+ nmcomponent1->execute();
+ nmcomponent3->execute();
executeAll(bc);
if(!(i%100))
diff --git a/test/testPhysics/flow/multiphase_flow.cc b/examples/flow/multiphase_flow.cc
similarity index 100%
rename from test/testPhysics/flow/multiphase_flow.cc
rename to examples/flow/multiphase_flow.cc
diff --git a/test/testPhysics/flow/pitot_tube_ice.cc b/examples/flow/pitot_tube_ice.cc
similarity index 100%
rename from test/testPhysics/flow/pitot_tube_ice.cc
rename to examples/flow/pitot_tube_ice.cc
diff --git a/test/testPhysics/heatTransfer/CMakeLists.txt b/examples/heatTransfer/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/heatTransfer/CMakeLists.txt
rename to examples/heatTransfer/CMakeLists.txt
diff --git a/test/testPhysics/heatTransfer/surfaceFlux.cc b/examples/heatTransfer/surfaceFlux.cc
similarity index 100%
rename from test/testPhysics/heatTransfer/surfaceFlux.cc
rename to examples/heatTransfer/surfaceFlux.cc
diff --git a/test/input_data/bus.stl b/examples/input_data/bus.stl
similarity index 100%
rename from test/input_data/bus.stl
rename to examples/input_data/bus.stl
diff --git a/test/input_data/locomotive.stl b/examples/input_data/locomotive.stl
similarity index 100%
rename from test/input_data/locomotive.stl
rename to examples/input_data/locomotive.stl
diff --git a/test/testPhysics/jumpingObjects/CMakeLists.txt b/examples/jumpingObjects/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/jumpingObjects/CMakeLists.txt
rename to examples/jumpingObjects/CMakeLists.txt
diff --git a/test/testPhysics/jumpingObjects/jumpingBox.cc b/examples/jumpingObjects/jumpingBox.cc
similarity index 100%
rename from test/testPhysics/jumpingObjects/jumpingBox.cc
rename to examples/jumpingObjects/jumpingBox.cc
diff --git a/test/testPhysics/levelSet/CMakeLists.txt b/examples/levelSet/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/levelSet/CMakeLists.txt
rename to examples/levelSet/CMakeLists.txt
diff --git a/test/testPhysics/levelSet/levelSetBasic.cc b/examples/levelSet/levelSetBasic.cc
similarity index 100%
rename from test/testPhysics/levelSet/levelSetBasic.cc
rename to examples/levelSet/levelSetBasic.cc
diff --git a/test/testPhysics/levelSet/levelSetFacetedGrowth.cc b/examples/levelSet/levelSetFacetedGrowth.cc
similarity index 100%
rename from test/testPhysics/levelSet/levelSetFacetedGrowth.cc
rename to examples/levelSet/levelSetFacetedGrowth.cc
diff --git a/test/testPhysics/levelSet/levelSetNormalGrowth.cc b/examples/levelSet/levelSetNormalGrowth.cc
similarity index 100%
rename from test/testPhysics/levelSet/levelSetNormalGrowth.cc
rename to examples/levelSet/levelSetNormalGrowth.cc
diff --git a/test/testPhysics/massTransferSM/CMakeLists.txt b/examples/massTransferSM/CMakeLists.txt
similarity index 100%
rename from test/testPhysics/massTransferSM/CMakeLists.txt
rename to examples/massTransferSM/CMakeLists.txt
diff --git a/test/testPhysics/massTransferSM/testSMDiff.cc b/examples/massTransferSM/testSMDiff.cc
similarity index 100%
rename from test/testPhysics/massTransferSM/testSMDiff.cc
rename to examples/massTransferSM/testSMDiff.cc
diff --git a/test/testPhysics/massTransferSM/testSMDiff3C.cc b/examples/massTransferSM/testSMDiff3C.cc
similarity index 100%
rename from test/testPhysics/massTransferSM/testSMDiff3C.cc
rename to examples/massTransferSM/testSMDiff3C.cc
diff --git a/test/testPhysics/massTransferSM/testSMPhi.cc b/examples/massTransferSM/testSMPhi.cc
similarity index 100%
rename from test/testPhysics/massTransferSM/testSMPhi.cc
rename to examples/massTransferSM/testSMPhi.cc
diff --git a/test/testPhysics/massTransferSM/testSMPhiBV.cc b/examples/massTransferSM/testSMPhiBV.cc
similarity index 100%
rename from test/testPhysics/massTransferSM/testSMPhiBV.cc
rename to examples/massTransferSM/testSMPhiBV.cc
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 9d9652c..a8b457c 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -2,5 +2,3 @@ add_subdirectory(testABD)
add_subdirectory(testACL)
add_subdirectory(testAGL)
add_subdirectory(testMath)
-add_subdirectory(testPhysics)
-
diff --git a/test/input_data/asl.ini b/test/input_data/asl.ini
deleted file mode 100644
index 75d4553..0000000
--- a/test/input_data/asl.ini
+++ /dev/null
@@ -1,8 +0,0 @@
-
-# Sample ASL configuration file
-# If desired platform and device are not detected
-# the user will be warned and the automatically found device will be used
-
-platform = Advanced Micro Devices, Inc.
-device = AMD FX(tm)-6300 Six-Core Processor
-
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/asl.git
More information about the debian-science-commits
mailing list