Chute with hopper

Problem description:

Hopper3dDemo.cpp treats particles which flow from a hopper onto an inclined chute below. The entire code of this problem can be viewed here: Particles on a chute with a multilayered bottom (code).

Headers

#include <sstream>
#include <iostream>
#include <iomanip>
#include <cmath>

Before the main function

Main function

int main()
{
//Problem parameters
problem.setName("HopperSelfTest");
Mdouble tc = 4.0e-4; // particle collision time
problem.setTimeStep(0.02 * tc);
problem.setTimeMax(0.01);
//Particle properties
problem.setInflowParticleRadius(0.32e-3, 0.40e-3);
problem.setFixedParticleRadius(0.36e-3);
species.setHandler(&problem.speciesHandler);
species.setDensity(2400.0);
Mdouble meanRadius = 0.5 * (problem.getMinInflowParticleRadius() + problem.getMaxInflowParticleRadius());
Mdouble mass = species.getMassFromRadius(meanRadius);
species.setCollisionTimeAndRestitutionCoefficient(tc, 0.95, mass);
species.setSlidingFrictionCoefficient(0.5);
problem.speciesHandler.copyAndAddObject(species);
//Chute properties
problem.setRoughBottomType(MONOLAYER_ORDERED); // try also MONOLAYER_DISORDERED, MULTILAYER or FLAT
problem.setChuteAngleAndMagnitudeOfGravity(10.0,9.8); // in degrees (relative to horizontal)
problem.setChuteLength(40.0e-3);
problem.setChuteWidth(3.2e-3 / 2.0);
//Hopper properties
Mdouble ExitHeight = 10.0e-3;
Mdouble ExitLength = ExitHeight;
Mdouble hopperAngle_ = 60.0;
Mdouble hopperLength_ = 4.0 * ExitLength;
// Mdouble hopperLowestPoint_ = ExitHeight - ExitLength * std::tan(problem.getChuteAngle());
// Mdouble hopperHeight_ = hopperLowestPoint_ + 1.1 * 0.5 * (hopperLength_ + ExitLength) / std::tan(hopperAngle_ * constants::pi / 180.0); // NB: this is not DEDUCED, but SET!!! (BvdH)
Mdouble hopperHeight_ = 24.1139e-3;
problem.setHopper(ExitLength, ExitHeight, hopperAngle_, hopperLength_, hopperHeight_);
// Output properties
problem.setSaveCount(51);
//'time step ratio': size of minimum particle over maximum distance travelled
// by any particle per time step (i.e., should be >> 1 )
logger(INFO, "time step ratio: %", problem.getTimeStepRatio());
//solve
problem.solve();
}
@ MONOLAYER_ORDERED
Definition: Chute.h:32
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.
int main(int argc, char *argv[])
Definition: T_protectiveWall.cpp:194
void setHandler(SpeciesHandler *handler)
Sets the pointer to the handler to which this species belongs.
Definition: BaseSpecies.cc:70
ChuteWithHopper has a hopper as inflow.
Definition: ChuteWithHopper.h:18
void setDensity(Mdouble density)
Definition: ParticleSpecies.cc:88
Mdouble getMassFromRadius(Mdouble radius) const
Definition: ParticleSpecies.cc:103
Contains material and contact force properties.
Definition: Species.h:14
#define INFO(i)
Definition: mumps_solver.h:54
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

(Return to Overview of advanced tutorials)