6 #if !defined(DEM_INLET_H)
27 #include "custom_utilities/AuxiliaryFunctions.h"
36 class ParticleCreatorDestructor;
59 if(!smp.
Has(rThisVariable))
KRATOS_ERROR<<
"The SubModelPart '"<<smp.
Name()<<
"' does not have the variable '"<<rThisVariable.
Name()<<
"'";
61 virtual void CheckSubModelPart(
ModelPart& smp);
63 virtual void InitializeStep(
ModelPart& r_modelpart);
64 void DettachElements(
ModelPart& r_modelpart,
unsigned int& max_Id);
65 void DettachClusters(
ModelPart& r_clusters_modelpart,
unsigned int& max_Id);
66 bool OneNeighbourInjectorIsInjecting(
const Element::Pointer&
element);
69 void SetNormalizedMaxIndentationForRelease(
const double value);
70 void SetNormalizedMaxIndentationForNewParticleCreation(
const double value);
71 int GetPartialNumberOfParticlesInjectedSoFar(
const int i);
72 int GetTotalNumberOfParticlesInjectedSoFar();
73 double GetPartialMassInjectedSoFar(
const int i);
74 double GetTotalMassInjectedSoFar();
75 virtual double SetMaxDistributionRadius(
ModelPart& mp);
76 virtual double SetDistributionMeanRadius(
ModelPart& mp);
77 virtual double GetMaxRadius(
ModelPart& mp);
86 void UpdateInjectedParticleVelocity(
Element &particle,
Element &injector_element);
87 virtual void FixInjectorConditions(
Element* p_element);
88 virtual void FixInjectionConditions(
Element* p_element,
Element* p_injector_element);
90 virtual void UpdateTotalThroughput(
SphericParticle& r_spheric_particle);
91 virtual void UpdateTotalThroughput(
Cluster3D& r_cluster);
92 virtual void UpdatePartialThroughput(
SphericParticle& r_spheric_particle,
const int i);
93 virtual void UpdatePartialThroughput(
Cluster3D& r_cluster,
const int i);
94 double GetInputNumberOfParticles(
const ModelPart& mp);
95 virtual void CheckDistanceAndSetFlag(
ModelPart& r_modelpart);
98 std::vector<double> mPartialParticleToInsert;
99 std::vector<double> mLastInjectionTimes;
101 bool mFirstInjectionIsDone;
102 bool mBallsModelPartHasSphericity;
103 bool mBallsModelPartHasRotation;
104 bool mStrategyForContinuum;
105 int mTotalNumberOfParticlesInjected;
106 std::vector<int> mNumberOfParticlesInjected;
107 std::map<int, std::string> mOriginInletSubmodelPartIndexes;
108 double mTotalMassInjected;
110 std::vector<double> mMassInjected;
111 std::mt19937 mGenerator;
116 double mNormalizedMaxIndentationForRelease;
117 double mNormalizedMaxIndentationForNewParticleCreation;
118 std::vector<PropertiesProxy> mFastProperties;
119 std::vector<bool> mLayerRemoved;
123 bool mWarningTooSmallInlet;
124 bool mWarningTooSmallInletForMassFlow;
125 void ThrowWarningTooSmallInlet(
const ModelPart& mp);
126 void ThrowWarningTooSmallInletForMassFlow(
const ModelPart& mp);
127 std::vector<ModelPart*> mListOfSubModelParts;
128 std::map<std::string, std::unique_ptr<RandomVariable>> mInletsRandomVariables;
129 std::map<std::string, Parameters> mInletsRandomSettings;
Definition: cluster3D.h:29
DEM_Inlet & operator=(const DEM_Inlet &)=delete
ModelPart::ElementsContainerType ElementsArrayType
Definition: inlet.h:44
GlobalPointersVector< Element >::iterator ParticleWeakIteratorType
Definition: inlet.h:42
KRATOS_CLASS_POINTER_DEFINITION(DEM_Inlet)
virtual ~DEM_Inlet()
Destructor.
Definition: inlet.h:53
void CheckIfSubModelPartHasVariable(ModelPart &smp, const Variable< TDataType > &rThisVariable)
Definition: inlet.h:58
DEM_Inlet(const DEM_Inlet &)=delete
GlobalPointersVector< Element > ParticleWeakVectorType
Definition: inlet.h:43
bool Has(const Variable< TDataType > &rThisVariable) const
Checks if the data container has a value associated with a given variable.
Definition: data_value_container.h:382
Base class for all Elements.
Definition: element.h:60
This class is a vector which stores global pointers.
Definition: global_pointers_vector.h:61
This class aims to manage meshes for multi-physics simulations.
Definition: model_part.h:77
MeshType::ElementsContainerType ElementsContainerType
Element container. A vector set of Elements with their Id's as key.
Definition: model_part.h:168
std::string & Name()
Definition: model_part.h:1811
This class provides to Kratos a data structure for I/O based on the standard of JSON.
Definition: kratos_parameters.h:59
Definition: create_and_destroy.h:33
Definition: spheric_particle.h:31
const std::string & Name() const
Definition: variable_data.h:201
Variable class contains all information needed to store and retrive data from a data container.
Definition: variable.h:63
#define KRATOS_ERROR
Definition: exception.h:161
int seed
Definition: GenerateWind.py:138
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
int angle_in_degrees
Definition: angle_finder.py:23
int dimension
Definition: isotropic_damage_automatic_differentiation.py:123
integer i
Definition: TensorModule.f:17
Definition: mesh_converter.cpp:33