This tutorial present a simple case of sintering between two particles. The code can be found in SinterPair.cpp.
{
public:
{
"set xlabel 'time [s]'\n"
"set ylabel 'x/a [nm]'\n"
"plot 'SinterPair"+
r+
".fstat' u ($1):(sqrt($7/r)) w lp\n"
);
const Mdouble restitutionCoefficient = 0.1;
s.setStiffnessAndRestitutionCoefficient(stiffness,restitutionCoefficient,mass);
s.setPlasticParameters(stiffness, 10*stiffness, stiffness, 0.16);
const Mdouble collisionTime =
s.getCollisionTime(mass);
s.setSinterAdhesion(0.013*stiffness);
p.setPosition(-
p.getPosition());
}
{
}
};
Array< double, 1, 3 > e(1./3., 0.5, 2.)
double Mdouble
Definition: GeneralDefine.h:13
Logger< MERCURYDPM_LOGLEVEL > logger("MercuryKernel")
Definition of different loggers with certain modules. A user can define its own custom logger here.
float * p
Definition: Tutorial_Map_using.cpp:9
std::enable_if<!std::is_pointer< U >::value, U * >::type copyAndAddObject(const U &object)
Creates a copy of a Object and adds it to the BaseHandler.
Definition: BaseHandler.h:360
T * getLastObject()
Gets a pointer to the last Object in this BaseHandler.
Definition: BaseHandler.h:642
Mdouble getRadius() const
Returns the particle's radius.
Definition: BaseParticle.h:331
void setSaveCount(unsigned int saveCount)
Sets File::saveCount_ for all files (ene, data, fstat, restart, stat)
Definition: DPMBase.cc:386
SpeciesHandler speciesHandler
A handler to that stores the species type i.e. LinearViscoelasticSpecies, etc.
Definition: DPMBase.h:1433
void setName(const std::string &name)
Allows to set the name of all the files (ene, data, fstat, restart, stat)
Definition: DPMBase.cc:400
Mdouble getTime() const
Returns the current simulation time.
Definition: DPMBase.cc:799
void setMin(const Vec3D &min)
Sets the minimum coordinates of the problem domain.
Definition: DPMBase.cc:1109
ParticleHandler particleHandler
An object of the class ParticleHandler, contains the pointers to all the particles created.
Definition: DPMBase.h:1443
void setParticlesWriteVTK(bool writeParticlesVTK)
Sets whether particles are written in a VTK file.
Definition: DPMBase.cc:933
void setTimeStep(Mdouble newDt)
Sets a new value for the simulation time step.
Definition: DPMBase.cc:1225
void setTimeMax(Mdouble newTMax)
Sets a new value for the maximum simulation duration.
Definition: DPMBase.cc:864
void setMax(const Vec3D &max)
Sets the maximum coordinates of the problem domain.
Definition: DPMBase.cc:1073
Mdouble getTimeMax() const
Returns the maximum simulation duration.
Definition: DPMBase.cc:879
void setGravity(Vec3D newGravity)
Sets a new value for the gravitational acceleration.
Definition: DPMBase.cc:1374
This adds on the hierarchical grid code for 3D problems.
Definition: Mercury3D.h:16
[St:headers]
Definition: SinterPair.cpp:14
void printTime() const override
Displays the current simulation time and the maximum simulation duration.
Definition: SinterPair.cpp:67
SinterPair(Mdouble radius)
Definition: SinterPair.cpp:16
Contains material and contact force properties.
Definition: Species.h:14
A spherical particle is the most simple particle used in MercuryDPM.
Definition: SphericalParticle.h:16
RealScalar s
Definition: level1_cplx_impl.h:130
std::string toString(Mdouble value, unsigned precision)
converts a floating point number into a string with a given precision
Definition: StringHelpers.cc:17
bool writeToFile(const std::string &filename, const std::string &filecontent)
Writes a string to a file.
Definition: FileIOHelpers.cc:29
std::string string(const unsigned &i)
Definition: oomph_definitions.cc:286
{
sp0.solve();
sp1.solve();
sp2.solve();
"set xlabel 'time [s]'\n"
"set ylabel 'x/a'\n"
"plot [0:200] 'SinterPair5e-07.fstat' u ($1):(sqrt($7/5e-07)) w lp lt rgb 'royalblue'\n"
"replot 'SinterPair1.5e-06.fstat' u ($1):(sqrt($7/1.5e-06)) w lp lt rgb 'light-red'\n"
"replot 'SinterPair2e-06.fstat' u ($1):(sqrt($7/2e-06)) w lp lt rgb 'sea-green'"
);
logger(
INFO,
"Execute 'gnuplot SinterPair.gnu' to view output");
}
#define UNUSED
Definition: GeneralDefine.h:18
int main(int argc, char *argv[])
Definition: T_protectiveWall.cpp:194
#define INFO(i)
Definition: mumps_solver.h:54