Skip to content
Snippets Groups Projects
Commit 2d264199 authored by peters's avatar peters
Browse files

Finish parameter constructor.

parent 323580b0
No related branches found
No related tags found
1 merge request!56Clean up Configuration File mess. Closes #18
...@@ -44,31 +44,42 @@ ...@@ -44,31 +44,42 @@
#define INTERFACE_T 4 #define INTERFACE_T 4
#define INTERFACE_B 5 #define INTERFACE_B 5
//////////////////////////////////////////////////////////////////////////
// precision (change between double and float)
//
#include "Core/DataTypes.h" #include "Core/DataTypes.h"
//////////////////////////////////////////////////////////////////////////
#include <string> #include <string>
#include <vector> #include <vector>
// Initial condition
typedef struct InitCond{ struct InitCondition
{
real Re; real Re;
real factorPressBC; real factorPressBC {1.0};
real Diffusivity, Temp, TempBC; real Diffusivity {0.001};
real RealX, RealY; real Temp {0.0};
int numprocs, myid, maxdev; real TempBC {1.0};
unsigned int tend, tout, tStartOut, tCalcMedStart, tCalcMedEnd, tDoCheckPoint, tDoRestart; real RealX {1.0};
unsigned int PressInID, PressOutID; real RealY {1.0};
unsigned int PressInZ, PressOutZ; int numprocs, myid;
std::vector<uint> devices; int maxdev {1};
uint tDoCheckPoint {0};
uint tDoRestart {0};
uint tCalcMedStart {0};
uint tCalcMedEnd {10};
uint tend {10};
uint tout {1};
uint tStartOut {0};
uint PressInID {0};
uint PressOutID {0};
uint PressInZ {1};
uint PressOutZ {2};
std::vector<uint> devices {1, 0}; // one device with ID = 0
std::vector<int> GridX, GridY, GridZ, DistX, DistY, DistZ; std::vector<int> GridX, GridY, GridZ, DistX, DistY, DistZ;
std::vector<real> scaleLBMtoSI, translateLBMtoSI; std::vector<real> scaleLBMtoSI, translateLBMtoSI;
std::vector<real> minCoordX, minCoordY, minCoordZ, maxCoordX, maxCoordY, maxCoordZ; std::vector<real> minCoordX, minCoordY, minCoordZ, maxCoordX, maxCoordY, maxCoordZ;
std::vector<bool> NeedInterface; std::vector<bool> NeedInterface;
std::string fname, oPath, oPrefix; std::string fname, oPath;
std::string oPrefix {"MyFile"};
std::string geometryFileC, geometryFileM, geometryFileF; std::string geometryFileC, geometryFileM, geometryFileF;
std::string kFull, geoFull, geoVec, coordX, coordY, coordZ, neighborX, neighborY, neighborZ, neighborWSB, scaleCFC, scaleCFF, scaleFCC, scaleFCF, scaleOffsetCF, scaleOffsetFC; std::string kFull, geoFull, geoVec, coordX, coordY, coordZ, neighborX, neighborY, neighborZ, neighborWSB, scaleCFC, scaleCFF, scaleFCC, scaleFCF, scaleOffsetCF, scaleOffsetFC;
std::string noSlipBcPos, noSlipBcQs, noSlipBcValue; std::string noSlipBcPos, noSlipBcQs, noSlipBcValue;
...@@ -89,16 +100,31 @@ typedef struct InitCond{ ...@@ -89,16 +100,31 @@ typedef struct InitCond{
std::string cpTop, cpBottom, cpBottom2; std::string cpTop, cpBottom, cpBottom2;
std::string concentration, streetVelocity; std::string concentration, streetVelocity;
std::string geomNormalX, geomNormalY, geomNormalZ, inflowNormalX, inflowNormalY, inflowNormalZ, outflowNormalX, outflowNormalY, outflowNormalZ; std::string geomNormalX, geomNormalY, geomNormalZ, inflowNormalX, inflowNormalY, inflowNormalZ, outflowNormalX, outflowNormalY, outflowNormalZ;
unsigned int timeStepForMP; uint timeStepForMP {10};
real clockCycleForMP; real clockCycleForMP {1.0};
real vis, vis_ratio; real vis {0.001};
real u0, u0_ratio; real vis_ratio {1.0};
real delta_rho, delta_press; real u0 {0.01};
bool printFiles, readGeo, doRestart, doCheckPoint, isGeo, isProp, isCp, calcMedian, GeometryValues, isConc, is2ndOrderMoments, is3rdOrderMoments, isHighOrderMoments, isWale, isMeasurePoints, isInitNeq; real u0_ratio {1.0};
real delta_rho {0.0};
real delta_press {1.0};
bool printFiles {false};
bool doRestart {false};
bool doCheckPoint {false};
bool readGeo, isGeo, isProp, isCp;
bool GeometryValues {false};
bool is2ndOrderMoments {false};
bool is3rdOrderMoments {false};
bool isHighOrderMoments {false};
bool calcMedian {false};
bool isConc {false};
bool isWale {false};
bool isMeasurePoints {false};
bool isInitNeq {false};
bool isGeoNormal, isInflowNormal, isOutflowNormal; bool isGeoNormal, isInflowNormal, isOutflowNormal;
bool simulatePorousMedia; bool simulatePorousMedia {false};
bool streetVelocityFile; bool streetVelocityFile {false};
} InitCondition; };
//Interface Cells //Interface Cells
typedef struct ICellCF{ typedef struct ICellCF{
......
This diff is collapsed.
...@@ -743,16 +743,18 @@ public: ...@@ -743,16 +743,18 @@ public:
protected: protected:
private: private:
bool compOn; bool compOn;
bool diffOn; bool diffOn {false};
bool isF3; bool isF3;
bool calcDragLift, calcCp; bool calcDragLift {false};
bool writeVeloASCII; bool calcCp {false};
bool calcPlaneConc; bool writeVeloASCII {false};
bool calcPlaneConc {false};
bool isBodyForce; bool isBodyForce;
int diffMod; int diffMod {27};
int coarse, fine, maxlevel; int maxlevel {0};
int coarse, fine;
int factor_gridNZ; int factor_gridNZ;
int D3Qxx; int D3Qxx {27};
InitCondition ic; InitCondition ic;
double memsizeGPU; double memsizeGPU;
unsigned int limitOfNodesForVTK; unsigned int limitOfNodesForVTK;
...@@ -761,8 +763,8 @@ private: ...@@ -761,8 +763,8 @@ private:
//Kernel //Kernel
std::string mainKernel; std::string mainKernel {"CumulantK17Comp"};
bool multiKernelOn; bool multiKernelOn {false};
std::vector<int> multiKernelLevel; std::vector<int> multiKernelLevel;
std::vector<std::string> multiKernel; std::vector<std::string> multiKernel;
...@@ -770,11 +772,13 @@ private: ...@@ -770,11 +772,13 @@ private:
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
//particles //particles
int particleBasicLevel, particleInitLevel; int particleBasicLevel {0};
int numberOfParticles; int particleInitLevel {0};
bool calcParticles; int numberOfParticles {0};
real stickToSolid; bool calcParticles {false};
real startXHotWall, endXHotWall; real stickToSolid {(real) 0.0};
real startXHotWall {(real) 0.0};
real endXHotWall {(real) 0.0};
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
//CUDA random number generation //CUDA random number generation
curandState* devState; curandState* devState;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment