KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Functions
Kratos::CppTestsUtilities Namespace Reference

Functions

void Create2DGeometry (ModelPart &rModelPart, const std::string &rEntityName="Element2D3N", const bool Initialize=true, const bool Elements=true)
 This method creates a simple geometry in 2D (triangles) More...
 
void CreateTestModelPartTriangle2D3N (ModelPart &rModelPart)
 This method creates a pure (Element) simple geometry in 2D (triangles) More...
 
void Create2DQuadrilateralsGeometry (ModelPart &rModelPart, const std::string &rEntityName="Element2D4N", const bool Initialize=true, const bool Elements=true)
 This method creates a simple geometry in 2D (quadrilaterals) More...
 
void Create3DGeometry (ModelPart &rModelPart, const std::string &rElementName="Element3D4N", const bool Initialize=true)
 This method creates a simple geometry in 3D (tetrahedra) More...
 
void CreateTestModelPartTetrahedra3D4N (ModelPart &rModelPart)
 This method creates a pure (Element) simple geometry in 3D (tetrahedra) More...
 
void Create3DHexahedraGeometry (ModelPart &rModelPart, const std::string &rElementName="Element3D8N", const bool Initialize=true)
 This method creates a simple geometry in 3D (hexahedra) More...
 
void Create3DQuadraticGeometry (ModelPart &rModelPart, const std::string &rElementName="Element3D10N", const bool Initialize=true)
 This method creates a simple geometry in 3D (tetrahedra quadratic) More...
 
void CreateSphereTriangularMesh (ModelPart &rModelPart, const std::string &rConditionName="SurfaceCondition3D3N", const double Radius=0.25, const std::array< double, 3 > &rCenter={0.0, 0.0, 0.0})
 This method creates a simple geometry sphere of triangles. More...
 
ModelPartCreateCubeSkinModelPart (Model &rCurrentModel, const double HalfX=0.6, const double HalfY=0.9, const double HalfZ=0.3, const DataCommunicator &rDataCommunicator=Testing::GetDefaultDataCommunicator())
 Create a cube skin model part. More...
 
ModelPartCreateCubeModelPart (Model &rCurrentModel, const DataCommunicator &rDataCommunicator=Testing::GetDefaultDataCommunicator())
 Create a cube model part. More...
 

Function Documentation

◆ Create2DGeometry()

void Kratos::CppTestsUtilities::Create2DGeometry ( ModelPart rModelPart,
const std::string &  rEntityName = "Element2D3N",
const bool  Initialize = true,
const bool  Elements = true 
)

This method creates a simple geometry in 2D (triangles)

Parameters
rModelPartReference to the ModelPart containing the problem
rEntityNameThe entity name considered
InitializeIf initialize the entities
ElementsIf create elements or conditions

◆ Create2DQuadrilateralsGeometry()

void Kratos::CppTestsUtilities::Create2DQuadrilateralsGeometry ( ModelPart rModelPart,
const std::string &  rEntityName = "Element2D4N",
const bool  Initialize = true,
const bool  Elements = true 
)

This method creates a simple geometry in 2D (quadrilaterals)

Parameters
rModelPartReference to the ModelPart containing the problem
rEntityNameThe entity name considered
InitializeIf initialize the entities
ElementsIf create elements or conditions

◆ Create3DGeometry()

void Kratos::CppTestsUtilities::Create3DGeometry ( ModelPart rModelPart,
const std::string &  rElementName = "Element3D4N",
const bool  Initialize = true 
)

This method creates a simple geometry in 3D (tetrahedra)

Parameters
rModelPartReference to the ModelPart containing the problem
rElementNameThe element name considered
InitializeIf initialize the elements

◆ Create3DHexahedraGeometry()

void Kratos::CppTestsUtilities::Create3DHexahedraGeometry ( ModelPart rModelPart,
const std::string &  rElementName = "Element3D8N",
const bool  Initialize = true 
)

This method creates a simple geometry in 3D (hexahedra)

Parameters
rModelPartReference to the ModelPart containing the problem
rElementNameThe element name considered
InitializeIf initialize the elements

◆ Create3DQuadraticGeometry()

void Kratos::CppTestsUtilities::Create3DQuadraticGeometry ( ModelPart rModelPart,
const std::string &  rElementName = "Element3D10N",
const bool  Initialize = true 
)

This method creates a simple geometry in 3D (tetrahedra quadratic)

Parameters
rModelPartReference to the ModelPart containing the problem
rElementNameThe element name considered
InitializeIf initialize the elements

◆ CreateCubeModelPart()

ModelPart & Kratos::CppTestsUtilities::CreateCubeModelPart ( Model rCurrentModel,
const DataCommunicator rDataCommunicator = Testing::GetDefaultDataCommunicator() 
)

Create a cube model part.

Parameters
rCurrentModelThe current model.
rDataCommunicatorThe data communicator.
Returns
The created cube model part.

◆ CreateCubeSkinModelPart()

ModelPart & Kratos::CppTestsUtilities::CreateCubeSkinModelPart ( Model rCurrentModel,
const double  HalfX = 0.6,
const double  HalfY = 0.9,
const double  HalfZ = 0.3,
const DataCommunicator rDataCommunicator = Testing::GetDefaultDataCommunicator() 
)

Create a cube skin model part.

Parameters
rCurrentModelThe current model.
HalfXThe half-length of the cube in the X-direction.
HalfYThe half-length of the cube in the Y-direction.
HalfZThe half-length of the cube in the Z-direction.
rDataCommunicatorThe data communicator.
Returns
ModelPart& The created cube skin model part.

◆ CreateSphereTriangularMesh()

void Kratos::CppTestsUtilities::CreateSphereTriangularMesh ( ModelPart rModelPart,
const std::string &  rConditionName = "SurfaceCondition3D3N",
const double  Radius = 0.25,
const std::array< double, 3 > &  rCenter = {0.0, 0.0, 0.0} 
)

This method creates a simple geometry sphere of triangles.

Parameters
rModelPartReference to the ModelPart containing the problem
rConditionNameThe condition name considered
RadiusThe radius of the sphere
rCenterThe center of the sphere

◆ CreateTestModelPartTetrahedra3D4N()

void Kratos::CppTestsUtilities::CreateTestModelPartTetrahedra3D4N ( ModelPart rModelPart)

This method creates a pure (Element) simple geometry in 3D (tetrahedra)

Parameters
rModelPartReference to the ModelPart containing the problem

◆ CreateTestModelPartTriangle2D3N()

void Kratos::CppTestsUtilities::CreateTestModelPartTriangle2D3N ( ModelPart rModelPart)

This method creates a pure (Element) simple geometry in 2D (triangles)

Parameters
rModelPartReference to the ModelPart containing the problem