4 #ifndef ANALYTIC_MODEL_PART_FILLER_H
5 #define ANALYTIC_MODEL_PART_FILLER_H
44 template<
class b
idiiter>
46 size_t left = std::distance(begin,
end);
47 while (num_random--) {
49 std::advance(r, rand()%
left);
50 std::swap(*begin, *r);
57 void GetRandomSample(std::vector<int>& random_positions_vector_to_fill,
58 const int n_positions,
59 const int n_random_positions);
61 void FillAnalyticModelPartGivenFractionOfParticlesToTransform(
const double fraction_of_particles_to_convert,
64 std::string analytic_sub_model_part_name =
"");
68 virtual std::string
Info()
const;
71 virtual void PrintInfo(std::ostream& rOStream)
const;
74 virtual void PrintData(std::ostream& rOStream)
const;
PeriodicInterfaceProcess & operator=(const PeriodicInterfaceProcess &)=delete
std::string Info() const override
Turn back information as a string.
Definition: periodic_interface_process.hpp:93
Definition: analytic_model_part_filler.h:28
KRATOS_CLASS_POINTER_DEFINITION(AnalyticModelPartFiller)
bidiiter random_unique(bidiiter begin, bidiiter end, size_t num_random)
Definition: analytic_model_part_filler.h:45
virtual ~AnalyticModelPartFiller()
Destructor.
Definition: analytic_model_part_filler.h:41
AnalyticModelPartFiller()
Default constructor.
Definition: analytic_model_part_filler.h:38
ModelPart::ElementsContainerType ElementsArrayType
Definition: analytic_model_part_filler.h:34
ModelPart::ElementsContainerType::iterator ElementsIteratorType
Definition: analytic_model_part_filler.h:35
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
Definition: create_and_destroy.h:33
end
Definition: DEM_benchmarks.py:180
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
left
Definition: exact_hinsberg_test.py:140