MercuryDPM  0.11
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
CoilSelfTest.cpp File Reference

Go to the source code of this file.

Classes

class  CoilSelfTest
 [CST:headers] More...
 

Functions

int main (int argc UNUSED, char *argv[] UNUSED)
 [CST:class] More...
 

Function Documentation

int main ( int argc  UNUSED,
char *argv[]  UNUSED 
)

[CST:class]

[CST:main]

Definition at line 150 of file CoilSelfTest.cpp.

References helpers::getSaveCountFromNumberOfSavesAndTimeMaxAndTimestep(), DPMBase::getTimeMax(), DPMBase::getTimeStep(), Files::setName(), Files::setSaveCount(), DPMBase::setSystemDimensions(), DPMBase::setTimeMax(), DPMBase::setTimeStep(), and DPMBase::solve().

150  {
151 
152  // create CoilSelfTest object
153  CoilSelfTest problem;
154 
155  // set some basic problem properties
156  problem.setName("CoilSelfTest");
157  problem.setSystemDimensions(3);
158  problem.setTimeStep(0.02 * 0.05);
159  problem.setTimeMax(2.0);
161 
162  // actually solving the problem
163  problem.solve();
164 
165 }
void solve()
The work horse of the code.
Definition: DPMBase.cc:1895
void setTimeMax(Mdouble newTMax)
Allows the upper time limit to be changed.
Definition: DPMBase.cc:179
void setSystemDimensions(unsigned int newDim)
Allows for the dimension of the simulation to be changed.
Definition: DPMBase.cc:453
void setName(const std::string &name)
Allows to set the name of all the files (ene, data, fstat, restart, stat)
Definition: Files.cc:149
void setSaveCount(unsigned int saveCount)
Sets File::saveCount_ for all files (ene, data, fstat, restart, stat)
Definition: Files.cc:138
[CST:headers]
void setTimeStep(Mdouble newDt)
Allows the time step dt to be changed.
Definition: DPMBase.cc:353
Mdouble getTimeStep() const
Allows the time step dt to be accessed.
Definition: DPMBase.cc:368
unsigned int getSaveCountFromNumberOfSavesAndTimeMaxAndTimestep(unsigned int numberOfSaves, Mdouble timeMax, Mdouble timestep)
Returns the correct saveCount if the total number of saves, the final time and the time step is known...
Definition: Helpers.cc:343
Mdouble getTimeMax() const
Allows the user to access the total simulation time during the simulation. Cannot change it though...
Definition: DPMBase.cc:194