GranularJet.cpp File Reference
#include <sstream>
#include <iostream>
#include <iomanip>
#include <cmath>
#include <Species/LinearViscoelasticSlidingFrictionSpecies.h>
#include "Funnel.h"

Functions

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

Function Documentation

◆ main()

int main ( int argc  UNUSED,
char *argv[]  UNUSED 
)
14 {
16 
17  // Particle properties
18  problem.setFixedParticleRadius(.3e-3);
19  problem.setInflowParticleRadius(.3e-3);
20 
21  //Contact properties
22  auto species = problem.speciesHandler.copyAndAddObject(LinearViscoelasticSlidingFrictionSpecies());
23  species->setSlidingFrictionCoefficient(0.5);
24  species->setDensity(1442.0); //sand
25  species->setCollisionTimeAndRestitutionCoefficient(4e-4, 1.0 - (0.12 * (50.0 / 15.0)), species->getMassFromRadius(
26  problem.getInflowParticleRadius()));//eps=0.6
27  species->setSlidingStiffness(species->getStiffness() * 2.0 / 7.0);
28  species->setSlidingDissipation(species->getDissipation() * 2.0 / 7.0);
29 
30  logger(INFO, "Setting k to % and disp to % with radius: %",
31  species->getStiffness(), species->getDissipation(), problem.getInflowParticleRadius());
32 
33  // Default problem parameters
34  problem.setChuteLength(0.25);
35  problem.setChuteWidth(0.15);
36  problem.setChuteAngle(26.7);
37  problem.setRoughBottomType(MONOLAYER_DISORDERED);
38 
39  //funr; // Funnel radius.
40  //funO[2]; // (x,y) location of the center of the top of the funnel.
41  //funa; // Angle of the funnel
42  //funH; // Heigth of the funnel
43  //funHf; // Falling heigth
44  //funD; // Funnel diameter at the downside of the funnel.
45  //funnz; //Number of particles along the heigth of the funnel
46  //funfr; // Filling ratio of the funnel
47  //fundiag; //The diagonal of the filling region
48  //funrmax; //The maximum range for r
49  problem.set_funa(60.0); // Angle of the funnel
50  problem.set_funD(0.015); // Funnel diameter at the downside of the funnel.
51  problem.set_funHf(0.05); // Falling heigth
52  problem.set_funnz(25.0); //Number of particles along the heigth of the funnel
53  //problem.set_funO(0, 0.5*(problem.getYMax()+problem.getYMin())); // (x,y) location of the center of the top of the funnel.
54  problem.set_funfr(0.3); // Filling ratio of the funnel
55 
56  problem.setInflowVelocity(0);
57  problem.setInflowVelocityVariance(0.01);
58  problem.setMaxFailed(1);
59 
60  logger(INFO, "Chute inflow height: % Chute inflow velocity: % Chute inflow velocity variance: %",
61  problem.getInflowHeight(), problem.getInflowVelocity(), problem.getInflowVelocityVariance());
62 
63  //Discretization parameters
64  //problem.setHGridMaxLevels(1);
65  //problem.setHGridNumberOfBucketsToPower(1e6); //automated
66  double mass = species->getMassFromRadius(
67  0.5 * (problem.getMinInflowParticleRadius() + problem.getMaxInflowParticleRadius()));
68  problem.setTimeStep(0.02 * species->getCollisionTime(mass));
69  problem.setTimeMax(.5e-2);
70  problem.setSaveCount(10);
71 
72  logger(INFO, " dt = % tmax = %", problem.getTimeStep(), problem.getTimeMax());
73  // logger(INFO, "Maximum allowed speed of particles: %", problem.getMaximumVelocity()); // speed
74  // allowed before particles move through each other!
75 
76 
77  problem.readArguments(argc, argv);
78  problem.set_funO(-0.9 * problem.get_funHf() * sin(problem.getChuteAngle()), 0.5 * (problem.getYMax() +
79  problem.getYMin())); // (x,y) location of the center of the top of the funnel.
80  problem.setName_();
81  problem.solve();
82 }
AnnoyingScalar sin(const AnnoyingScalar &x)
Definition: AnnoyingScalar.h:137
@ MONOLAYER_DISORDERED
Definition: Chute.h:32
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Species< LinearViscoelasticNormalSpecies, SlidingFrictionSpecies > LinearViscoelasticSlidingFrictionSpecies
Definition: LinearViscoelasticSlidingFrictionSpecies.h:12
Logger< MERCURYDPM_LOGLEVEL > logger("MercuryKernel")
Definition of different loggers with certain modules. A user can define its own custom logger here.
Definition: Funnel.h:17
#define INFO(i)
Definition: mumps_solver.h:54
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References e(), INFO, logger, MONOLAYER_DISORDERED, problem, and sin().