In this file, 1 Particle and 4 Walls are loaded from files "1Particle4Walls.ini" and "1Particle4Walls.restart".
The particles are aligned such that the single nonfixed particle rotates sinusoidally without moving. This is to test the behaviour of the tangential spring and the file loading routines.
38 "1 0 0 0 0 .96 1 .96\n"
39 "0.48 0 0.48 0 0 0 0.5 0 0 0 0 0 0 0\n"
43 "restart_version 1.0 name 1Particle4WallsRestartUnitTest_restart\n"
44 "dataFile name 1Particle4WallsRestartUnitTest_restart.data fileType ONE_FILE saveCount 5 counter 0 nextSavedTimeStep 0\n"
45 "fStatFile name 1Particle4WallsRestartUnitTest_restart.fstat fileType ONE_FILE saveCount 5 counter 0 nextSavedTimeStep 0\n"
46 "eneFile name 1Particle4WallsRestartUnitTest_restart.ene fileType ONE_FILE saveCount 5 counter 0 nextSavedTimeStep 0\n"
47 "restartFile name 1Particle4WallsRestartUnitTest_restart.restart fileType ONE_FILE saveCount 5 counter 0 nextSavedTimeStep 0\n"
48 "statFile name 1Particle4WallsRestartUnitTest_restart.stat fileType ONE_FILE saveCount 5 counter 0 nextSavedTimeStep 0\n"
49 "xMin 0 xMax 1 yMin 0 yMax 1 zMin 0 zMax 1\n"
50 "timeStep 1e-04 time 0 ntimeSteps 0 timeMax 0.01\n"
51 "systemDimensions 3 particleDimensions 3 gravity 0 0 0\n"
53 "LinearViscoelasticSlidingFrictionSpecies id 0 density 1.9098593 stiffness 200000 dissipation 0 slidingStiffness 57142.857 slidingDissipation 0 frictionCoefficient 0.5 frictionCoefficientStatic 0.5\n"
55 "InfiniteWall id 0 indSpecies 0 position 0 0 0 orientation 0 0 0 1 velocity 0 0 0 angularVelocity 0 0 0 0 force 0 0 0 torque 0 0 0 normal -1 0 0 factor 1\n"
56 "InfiniteWall id 1 indSpecies 0 position 0.96 0 0 orientation 0 0 0 1 velocity 0 0 0 angularVelocity 0 0 0 0 force 0 0 0 torque 0 0 0 normal 1 0 0 factor 1\n"
57 "InfiniteWall id 2 indSpecies 0 position 0 0 0 orientation 0 0 0 1 velocity 0 0 0 angularVelocity 0 0 0 0 force 0 0 0 torque 0 0 0 normal 0 0 -1 factor 1\n"
58 "InfiniteWall id 3 indSpecies 0 position 0 0 0.96 orientation 0 0 0 1 velocity 0 0 0 angularVelocity 0 0 0 0 force 0 0 0 torque 0 0 0 normal 0 0 1 factor 1\n"
61 "BaseParticle id 0 indSpecies 0 position 0.48 0 0.48 orientation 0 0 0 1 velocity 0 0 0 angularVelocity 0 60 0 0 force 0 0 0 torque 0 0 0 radius 0.5 invMass 1 invInertia 10\n"
63 "LinearViscoelasticSlidingFrictionInteraction particleWallIds 0 0 timeStamp 0 force 0 0 0 torque 0 0 0 slidingSpring 0 0 0\n"
64 "LinearViscoelasticSlidingFrictionInteraction particleWallIds 0 1 timeStamp 0 force 0 0 0 torque 0 0 0 slidingSpring 0 0 0\n"
65 "LinearViscoelasticSlidingFrictionInteraction particleWallIds 0 2 timeStamp 0 force 0 0 0 torque 0 0 0 slidingSpring 0 0 0\n"
66 "LinearViscoelasticSlidingFrictionInteraction particleWallIds 0 3 timeStamp 0 force 0 0 0 torque 0 0 0 slidingSpring 0 0 0\n"
70 problem.
setName(
"1Particle4WallsRestartUnitTest");
bool writeToFile(std::string filename, std::string filecontent)
Writes a string to a file.
void solve()
The work horse of the code.
The DPMBase header includes quite a few header files, defining all the handlers, which are essential...
Logger< MERCURY_LOGLEVEL > logger("MercuryKernel")
virtual const Vec3D & getAngularVelocity() const
Returns the angular velocity of this interactable.
void setAppend(bool newAppendFlag)
Allows to set the append option.
bool isEqualTo(const Vec3D &other, const double tol) const
Checks if the length this Vec3D is equal the length of other with a certain tolerance.
int readRestartFile()
Reads all the particle data corresponding to the current saved time step. Which is what the restart f...
void setName(const std::string &name)
Allows to set the name of all the files (ene, data, fstat, restart, stat)
ParticleHandler particleHandler
An object of the class ParticleHandler, contains the pointers to all the particles created...
T * getObject(const unsigned int id)
Gets a pointer to the Object at the specified index in the BaseHandler.
LL< Log::FATAL > FATAL
Fatal log level.
virtual void writeRestartFile()
Stores all the particle data for current save time step. Calls the write function.
virtual const Vec3D & getVelocity() const
Returns the velocity of this interactable.
Implementation of a 3D vector (by Vitaliy).