AngleOfRepose.cpp File Reference
#include <sstream>
#include <iostream>
#include <iomanip>
#include <cmath>
#include "ChuteWithHopper.h"
#include "Species/LinearViscoelasticSlidingFrictionSpecies.h"
#include "Walls/InfiniteWall.h"

Classes

class  AngleOfRepose
 

Functions

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

Function Documentation

◆ main()

int main ( int argc  ,
char argv[] 
)
290 {
291  AngleOfRepose problem;
292 
293  //Problem parameters
294  //~ problem.setTimeMax(1000.0);
295  problem.setTimeMax(1.0);
296 
297  //Chute properties
298  problem.setChuteAngle(0.0);
299  //~ problem.setChuteLength(200.0);
300  problem.setChuteLength(20.0);
301  problem.setChuteWidth(problem.getChuteLength());
302  problem.Height = std::max(5.,problem.getChuteLength() * 0.5 * tan( 25.0 *constants::pi/180.0));
303  problem.setMaxFailed(1);
304 
305  int study_num;
306  if (argc>1) {
307  study_num=atoi(argv[1]);
308  } else
309  {
310  study_num = 0;
311  logger(ERROR, "Please enter study number");
312  }
313  problem.run(study_num);
314 }
Logger< MERCURYDPM_LOGLEVEL > logger("MercuryKernel")
Definition of different loggers with certain modules. A user can define its own custom logger here.
LL< Log::ERROR > ERROR
Error log level.
Definition: Logger.cc:53
Definition: AngleOfRepose.cpp:35
Mdouble Height
Definition: AngleOfRepose.cpp:119
void run(int study_num)
Definition: AngleOfRepose.cpp:163
Mdouble getChuteLength() const
Allows chute length to be accessed.
Definition: ChuteWithHopper.cc:531
void setChuteLength(Mdouble chuteLength) override
sets xMax to chuteLength+hopperlength_, and thus specifies the length off the runoff chute
Definition: ChuteWithHopper.cc:541
void setChuteWidth(Mdouble chuteWidth)
Sets the chute width (Y-direction)
Definition: Chute.cc:1039
void setMaxFailed(unsigned int maxFailed)
Sets the number of times a particle will be tried to be added to the insertion boundary.
Definition: Chute.cc:827
void setChuteAngle(Mdouble chuteAngle)
Sets gravity vector according to chute angle (in degrees)
Definition: Chute.cc:768
void setTimeMax(Mdouble newTMax)
Sets a new value for the maximum simulation duration.
Definition: DPMBase.cc:873
const Mdouble pi
Definition: ExtendedMath.h:45
T tan(T x)
Definition: ExtendedMath.h:178

References ERROR, ChuteWithHopper::getChuteLength(), AngleOfRepose::Height, logger, constants::pi, AngleOfRepose::run(), Chute::setChuteAngle(), ChuteWithHopper::setChuteLength(), Chute::setChuteWidth(), Chute::setMaxFailed(), DPMBase::setTimeMax(), and mathsFunc::tan().