Test for fluidAgent->Run() function.
940 double time_final = 0.05;
941 double timestep = 2.0e-3;
948 std::string fluidDir;
949 std::string simStaticDir;
950 fluidDir = IRAD::Sys::CWD() +
"/SimpleStatic/fluid";
951 simStaticDir = IRAD::Sys::CWD() +
"/SimpleStatic";
952 if(!(IRAD::Sys::FILEEXISTS(fluidDir)||(IRAD::Sys::FILEEXISTS(simStaticDir)))){
953 std::cout <<
"SimpleStatic / fluid Folders do not exists!" << std::endl;
955 result.UpdateResult(
"fsiCoupler:Works",works);
959 IntDir = IRAD::Sys::ChDir(simStaticDir);
961 std::cout <<
"GetInputData Error: Could not change directory to "
962 << fluidDir <<
". Exiting (fail). " << std::endl;
964 result.UpdateResult(
"fsiCoupler:Works",works);
966 std::system(
"chmod 755 Allclean Allrun AllrunPar makeLinks makeSerialLinks removeSerialLinks");
967 std::system(
"./Allclean");
968 std::system(
"./Allrun");
969 IntDir = IRAD::Sys::ChDir(fluidDir);
971 std::cout <<
"GetInputData Error: Could not change directory to "
972 << fluidDir <<
". Exiting (fail). " << std::endl;
974 result.UpdateResult(
"fsiCoupler:Works",works);
979 std::string fluidSolverName(
"OpenFoamFSI");
980 std::string solidSolverName(
"ElmerCSC");
981 std::string transferServiceName(
"SurfX");
982 std::string runMode(
"1");
984 std::cout <<
"COM loading all this junks" << std::endl;
985 COM_load_module(fluidSolverName.c_str(),
"FluidsComponentInterface");
986 COM_load_module(solidSolverName.c_str(),
"StructuresComponentInterface");
987 COM_load_module(
"SurfUtil",
"SurfUtil");
988 COM_load_module(
"Simpal",
"Simpal");
991 componentInterfaceNames.push_back(
"FluidsComponentInterface");
992 componentInterfaceNames.push_back(
"StructuresComponentInterface");
993 componentInterfaceNames.push_back(
"TransferInterface");
994 componentInterfaceNames.push_back(
"SurfUtil");
995 componentInterfaceNames.push_back(
"Simpal");
1003 int maxSubSteps = 1000;
1004 int dumpinterval = 1;
1007 double *fluidDisp1 = NULL;
1008 double *fluidDisp2 = NULL;
1009 double *solidDisp1 = NULL;
1010 double *solidDisp2 = NULL;
1024 std::cout <<
"simultime is =" << simultime << std::endl;
1032 double *tractions = NULL;
1034 int isize = cap*stride;
1042 result.UpdateResult(
"FluidAgentRun:Works",works);
std::string getSolidIntName()
solidagent * getStructureAgent()
double getSimulationTime()
virtual int Run(double endTime)
int TransferDisplacementsToFluid(solidagent *solidAgent, fluidagent *fluidAgent)
int verblevel
track verbosity level for tests
fsicoupling fsiCoupler
Instantiation of class for use with the fsiCoupler & Agent tests.
void SetRunMode(const std::string &inMode)
fluidagent * getFluidAgent()
virtual int InitializeTimeStep(double time)
std::vector< std::string > componentInterfaceNames
bool tractionCheck(double *tractions, int isize)
void SetVerbLevel(int verb)
double getSimulationFinalTime()
std::string getFluidIntName()
virtual int Initialize(std::vector< std::string > &componentInterfaceNames, double finalTime, double timeStep)