TexGen
|
Class used to generate voxel mesh of prism domain for output to ABAQUS. More...
#include <PrismVoxelMesh.h>
Public Member Functions | |
CPrismVoxelMesh (string Type="CPrismPeriodicBoundaries") | |
virtual | ~CPrismVoxelMesh (void) |
int | OutputHexElements (ostream &Output, bool bOutputMatrix, bool bOutputYarn, int Filetype) |
Outputs hex elements for the elements in the element map. More... | |
virtual void | SaveVoxelMesh (CTextile &Textile, string OutputFilename, int XVoxNum, int YVoxNum, int ZVoxNum, bool bOutputMatrix, bool bOutputYarns, int iBoundaryConditions, int iElementType=0, int FileType=INP_EXPORT) |
void | AddElementInfo (vector< POINT_INFO > &RowInfo) |
Add a row of element information. More... | |
void | OutputOrientationsAndElementSets (string Filename) |
Outputs yarn orientations and element sets to .ori and .eld files. More... | |
CTextileMaterials & | GetMaterials () |
Protected Member Functions | |
bool | CalculateVoxelSizes (CTextile &Textile) |
Calculate voxel size based on number of voxels on each axis and domain size. More... | |
void | GetElementMap (CTextile &Textile) |
Creates a map of elements which are within the prism outline. More... | |
void | OutputNodes (ostream &Output, CTextile &Textile, int Filetype=INP_EXPORT) |
Outputs nodes to .inp file and gets element information. More... | |
void | OutputOrientationsAndElementSets (string Filename, ostream &Output) |
Outputs yarn orientations and element sets to .ori and .eld files. More... | |
void | SaveVoxelMeshToVTK (string Filename, CTextile &Textile) |
Add nodes for whole domain. More... | |
void | SaveToAbaqus (string Filename, CTextile &Textile, bool bOutputMatrix, bool bOutputYarn, int iBoundaryConditions, int iElementType) |
void | SaveToSCIRun (string Filename, CTextile &Textile) |
Save voxel mesh in SCIRun .pts and .hex format without boundary conditions. More... | |
void | OutputMatrixElementSet (string Filename, ostream &Output, int iNumHexElements, bool bMatrixOnly) |
Outputs all elements when only outputting matrix. More... | |
void | OutputAllNodesSet (string Filename, ostream &Output) |
Output node set containing all nodes. More... | |
virtual void | OutputPeriodicBoundaries (ostream &Output, CTextile &Textile, int iBoundaryConditions, bool bMatrixOnly) |
Output periodic boundary conditions to .inp file. More... | |
Protected Attributes | |
XYZ | m_RotatedVoxSize [3] |
x, y, z lengths of rotated voxels More... | |
XYZ | m_StartPoint |
Reference point for generating voxel grid (Point 0 of domain mesh) More... | |
map< pair< int, int >, bool > | m_ElementMap |
Map of x,z elements within prism polygon. More... | |
int | m_NumElements |
Number of elements in x-z slice which are output. More... | |
CTextileMaterials | m_Materials |
CMesh | m_Mesh |
Find intersections of yarn surfaces with grid of lines from node points in each axis. More... | |
int | m_XVoxels |
Number of voxels along x,y and z axes. More... | |
int | m_YVoxels |
int | m_ZVoxels |
pair< XYZ, XYZ > | m_DomainAABB |
Domain limits. More... | |
vector< POINT_INFO > | m_ElementsInfo |
Element information as calculated by GetPointInformation. More... | |
CPeriodicBoundaries * | m_PeriodicBoundaries |
Class used to generate voxel mesh of prism domain for output to ABAQUS.
Definition at line 30 of file PrismVoxelMesh.h.
CPrismVoxelMesh::CPrismVoxelMesh | ( | string | Type = "CPrismPeriodicBoundaries" | ) |
Definition at line 30 of file PrismVoxelMesh.cpp.
|
virtual |
Definition at line 36 of file PrismVoxelMesh.cpp.
|
inherited |
Add a row of element information.
Definition at line 704 of file VoxelMesh.cpp.
References TexGen::CVoxelMesh::m_ElementsInfo.
|
protectedvirtual |
Calculate voxel size based on number of voxels on each axis and domain size.
Implements TexGen::CVoxelMesh.
Definition at line 41 of file PrismVoxelMesh.cpp.
References TexGen::CTextile::GetDomain(), GetElementMap(), TexGen::CDomainPrism::GetPolygonLimits(), TexGen::CDomain::GetPrismDomain(), m_RotatedVoxSize, m_StartPoint, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, and TexGen::CVoxelMesh::m_ZVoxels.
|
protected |
Creates a map of elements which are within the prism outline.
Definition at line 118 of file PrismVoxelMesh.cpp.
References TexGen::CTextile::GetDomain(), TexGen::GetMinMaxXY(), TexGen::CDomainPrism::GetPoints(), TexGen::CDomain::GetPrismDomain(), m_ElementMap, m_NumElements, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_ZVoxels, TexGen::Max(), TexGen::Min(), TexGen::PointInside(), TexGen::XYZ::x, TexGen::XY::x, TexGen::XYZ::y, and TexGen::XY::y.
Referenced by CalculateVoxelSizes().
|
inlineinherited |
Definition at line 57 of file VoxelMesh.h.
|
protectedinherited |
Output node set containing all nodes.
Definition at line 584 of file VoxelMesh.cpp.
References TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, and TexGen::CVoxelMesh::m_ZVoxels.
Referenced by TexGen::CVoxelMesh::SaveToAbaqus().
|
virtual |
Outputs hex elements for the elements in the element map.
Reimplemented from TexGen::CVoxelMesh.
Definition at line 149 of file PrismVoxelMesh.cpp.
References TexGen::CMesh::AddElement(), TexGen::CMesh::HEX, TexGen::INP_EXPORT, m_ElementMap, TexGen::CVoxelMesh::m_ElementsInfo, TexGen::CVoxelMesh::m_Mesh, m_NumElements, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, TexGen::CVoxelMesh::m_ZVoxels, and TexGen::SCIRUN_EXPORT.
|
protectedinherited |
Outputs all elements when only outputting matrix.
Definition at line 567 of file VoxelMesh.cpp.
Referenced by TexGen::CVoxelMesh::SaveToAbaqus().
|
protectedvirtual |
Outputs nodes to .inp file and gets element information.
Implements TexGen::CVoxelMesh.
Definition at line 61 of file PrismVoxelMesh.cpp.
References TexGen::CMesh::AddNode(), TexGen::CTextile::GetPointInformation(), TexGen::INP_EXPORT, m_ElementMap, TexGen::CVoxelMesh::m_ElementsInfo, TexGen::CVoxelMesh::m_Mesh, m_RotatedVoxSize, m_StartPoint, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, TexGen::CVoxelMesh::m_ZVoxels, TexGen::VTU_EXPORT, TexGen::XYZ::x, TexGen::XYZ::y, and TexGen::XYZ::z.
|
inherited |
Outputs yarn orientations and element sets to .ori and .eld files.
Definition at line 470 of file VoxelMesh.cpp.
References TexGen::AddExtensionIfMissing(), and TexGen::CVoxelMesh::OutputOrientationsAndElementSets().
Referenced by TexGen::CVoxelMesh::OutputOrientationsAndElementSets(), and TexGen::CVoxelMesh::SaveToAbaqus().
|
protectedinherited |
Outputs yarn orientations and element sets to .ori and .eld files.
Definition at line 478 of file VoxelMesh.cpp.
References TexGen::CrossProduct(), TexGen::CVoxelMesh::m_ElementsInfo, TexGen::Normalise(), TexGen::StripPath(), TGERROR, TGLOG, TexGen::WriteElementsHeader(), TexGen::WriteOrientationsHeader(), and TexGen::WriteValues().
|
protectedvirtualinherited |
Output periodic boundary conditions to .inp file.
Reimplemented in TexGen::COctreeVoxelMesh, and TexGen::CStaggeredVoxelMesh.
Definition at line 594 of file VoxelMesh.cpp.
References TexGen::CPeriodicBoundaries::CreatePeriodicBoundaries(), TexGen::CTextile::GetDomain(), TexGen::CDomain::GetMesh(), TexGen::CVoxelMesh::m_PeriodicBoundaries, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, TexGen::CVoxelMesh::m_ZVoxels, TexGen::CPeriodicBoundaries::SetDomainSize(), TexGen::CPeriodicBoundaries::SetEdges(), TexGen::CPeriodicBoundaries::SetFaceA(), TexGen::CPeriodicBoundaries::SetFaceB(), TexGen::CPeriodicBoundaries::SetFaceC(), and TexGen::CPeriodicBoundaries::SetVertex().
Referenced by TexGen::CVoxelMesh::SaveToAbaqus().
|
protectedinherited |
Save voxel mesh in Abaqus .inp format with periodic boundary conditions bOutputMatrix and bOutput yarn specify which of these are saved to the Abaqus file
Definition at line 287 of file VoxelMesh.cpp.
References TexGen::AddExtensionIfMissing(), TexGen::CTextile::GetNumYarns(), TexGen::CVoxelMesh::m_Materials, TexGen::NO_BOUNDARY_CONDITIONS, TexGen::CVoxelMesh::OutputAllNodesSet(), TexGen::CVoxelMesh::OutputHexElements(), TexGen::CTextileMaterials::OutputMaterials(), TexGen::CVoxelMesh::OutputMatrixElementSet(), TexGen::CVoxelMesh::OutputNodes(), TexGen::CVoxelMesh::OutputOrientationsAndElementSets(), TexGen::CVoxelMesh::OutputPeriodicBoundaries(), TexGen::CTextileMaterials::SetupMaterials(), TEXGEN, TGERROR, and TGLOG.
Referenced by TexGen::CVoxelMesh::SaveVoxelMesh().
|
protectedinherited |
Save voxel mesh in SCIRun .pts and .hex format without boundary conditions.
Definition at line 358 of file VoxelMesh.cpp.
References TexGen::CVoxelMesh::OutputHexElements(), TexGen::CVoxelMesh::OutputNodes(), TexGen::RemoveExtension(), TexGen::SCIRUN_EXPORT, TGERROR, and TGLOG.
|
virtualinherited |
Save the voxel mesh as an Abaqus input file with periodic boundary conditions
CTextile | Textile - textile to be exported as refined voxel mesh |
string | OutputFilename - filename to save to |
int | XVoxNum - number of voxels in x direction |
int | YVoxNum - number of voxels in y direction |
int | ZVoxNum - number of voxels in z direction |
bOutputMatrix | True to output the matrix area of the mesh |
bOutputYarns | True to output the yarn areas |
iBoundaryConditions | as in enum PERIODIC_BOUNDARY_CONDITIONS |
iElementType | 0 for C3D8R, 1 for C3D8 |
int | Filetype as in enum EXPORT_TYPE |
Definition at line 51 of file VoxelMesh.cpp.
References TexGen::CVoxelMesh::CalculateVoxelSizes(), TexGen::CTimer::check(), TexGen::CTextile::GetDomain(), TexGen::INP_EXPORT, TexGen::CVoxelMesh::m_ElementsInfo, TexGen::CVoxelMesh::m_XVoxels, TexGen::CVoxelMesh::m_YVoxels, TexGen::CVoxelMesh::m_ZVoxels, TexGen::ReplaceFilenameSpaces(), TexGen::CVoxelMesh::SaveToAbaqus(), TexGen::CVoxelMesh::SaveVoxelMeshToVTK(), TexGen::CTimer::start(), TexGen::CTimer::stop(), TGERROR, and TGLOG.
Referenced by TexGen::COctreeVoxelMesh::SaveVoxelMesh().
|
protectedinherited |
Add nodes for whole domain.
Add hex elements Save voxel mesh in VTK format without boundary conditions
Definition at line 246 of file VoxelMesh.cpp.
References TexGen::AddExtensionIfMissing(), TexGen::CMeshDataBase::ELEMENT, TexGen::CMeshData< T >::m_Data, TexGen::CVoxelMesh::m_ElementsInfo, TexGen::CVoxelMesh::m_Mesh, TexGen::CVoxelMesh::OutputHexElements(), TexGen::CVoxelMesh::OutputNodes(), TexGen::CMesh::SaveToVTK(), and TexGen::VTU_EXPORT.
Referenced by TexGen::CVoxelMesh::SaveVoxelMesh().
Domain limits.
Definition at line 121 of file VoxelMesh.h.
Referenced by TexGen::CRectangularVoxelMesh::CalculateVoxelSizes(), TexGen::COctreeVoxelMesh::CreateP4ESTRefinement(), TexGen::COctreeVoxelMesh::isBoundary(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::COctreeVoxelMesh::OutputPeriodicBoundaries(), TexGen::COctreeVoxelMesh::SaveVoxelMesh(), and TexGen::COctreeVoxelMesh::smoothing().
|
protected |
Map of x,z elements within prism polygon.
Definition at line 55 of file PrismVoxelMesh.h.
Referenced by GetElementMap(), OutputHexElements(), and OutputNodes().
|
protectedinherited |
Element information as calculated by GetPointInformation.
Definition at line 123 of file VoxelMesh.h.
Referenced by TexGen::CVoxelMesh::AddElementInfo(), TexGen::COctreeVoxelMesh::checkIndex(), TexGen::COctreeVoxelMesh::extractSurfaceNodeSets(), TexGen::COctreeVoxelMesh::fillMaterialInfo(), OutputHexElements(), TexGen::CVoxelMesh::OutputHexElements(), TexGen::COctreeVoxelMesh::OutputNodes(), OutputNodes(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::CRotatedVoxelMesh::OutputNodes(), TexGen::CShearedVoxelMesh::OutputNodes(), TexGen::CVoxelMesh::OutputOrientationsAndElementSets(), TexGen::COctreeVoxelMesh::OutputSurfaces(), TexGen::CVoxelMesh::SaveVoxelMesh(), TexGen::CVoxelMesh::SaveVoxelMeshToVTK(), and TexGen::COctreeVoxelMesh::~COctreeVoxelMesh().
|
protectedinherited |
Definition at line 60 of file VoxelMesh.h.
Referenced by TexGen::CVoxelMesh::SaveToAbaqus().
|
protectedinherited |
Find intersections of yarn surfaces with grid of lines from node points in each axis.
Calculate intersections for one orientation of grid lines Output data with iMaxPerLine elements per line Mesh stored when saving to VTK
Definition at line 112 of file VoxelMesh.h.
Referenced by OutputHexElements(), TexGen::CVoxelMesh::OutputHexElements(), OutputNodes(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::CRotatedVoxelMesh::OutputNodes(), TexGen::CShearedVoxelMesh::OutputNodes(), and TexGen::CVoxelMesh::SaveVoxelMeshToVTK().
|
protected |
Number of elements in x-z slice which are output.
Definition at line 58 of file PrismVoxelMesh.h.
Referenced by GetElementMap(), and OutputHexElements().
|
protectedinherited |
Definition at line 126 of file VoxelMesh.h.
Referenced by TexGen::CVoxelMesh::CVoxelMesh(), TexGen::COctreeVoxelMesh::OutputPeriodicBoundaries(), TexGen::CStaggeredVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::OutputPeriodicBoundaries(), TexGen::CStaggeredVoxelMesh::SetOffset(), and TexGen::CVoxelMesh::~CVoxelMesh().
|
protected |
x, y, z lengths of rotated voxels
Definition at line 50 of file PrismVoxelMesh.h.
Referenced by CalculateVoxelSizes(), and OutputNodes().
|
protected |
Reference point for generating voxel grid (Point 0 of domain mesh)
Definition at line 52 of file PrismVoxelMesh.h.
Referenced by CalculateVoxelSizes(), and OutputNodes().
|
protectedinherited |
Number of voxels along x,y and z axes.
Definition at line 115 of file VoxelMesh.h.
Referenced by CalculateVoxelSizes(), TexGen::CRectangularVoxelMesh::CalculateVoxelSizes(), TexGen::CRotatedVoxelMesh::CalculateVoxelSizes(), TexGen::CShearedVoxelMesh::CalculateVoxelSizes(), TexGen::CStaggeredVoxelMesh::CalculateVoxelSizes(), TexGen::COctreeVoxelMesh::ConvertOctreeToNodes(), GetElementMap(), TexGen::CVoxelMesh::OutputAllNodesSet(), OutputHexElements(), TexGen::CVoxelMesh::OutputHexElements(), OutputNodes(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::CRotatedVoxelMesh::OutputNodes(), TexGen::CShearedVoxelMesh::OutputNodes(), TexGen::CStaggeredVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::storePointInfo(), and TexGen::COctreeVoxelMesh::writeTempFile().
|
protectedinherited |
Definition at line 116 of file VoxelMesh.h.
Referenced by CalculateVoxelSizes(), TexGen::CRectangularVoxelMesh::CalculateVoxelSizes(), TexGen::CRotatedVoxelMesh::CalculateVoxelSizes(), TexGen::CShearedVoxelMesh::CalculateVoxelSizes(), TexGen::COctreeVoxelMesh::ConvertOctreeToNodes(), TexGen::CVoxelMesh::OutputAllNodesSet(), OutputHexElements(), TexGen::CVoxelMesh::OutputHexElements(), OutputNodes(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::CRotatedVoxelMesh::OutputNodes(), TexGen::CShearedVoxelMesh::OutputNodes(), TexGen::CStaggeredVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::storePointInfo(), and TexGen::COctreeVoxelMesh::writeTempFile().
|
protectedinherited |
Definition at line 117 of file VoxelMesh.h.
Referenced by CalculateVoxelSizes(), TexGen::CRectangularVoxelMesh::CalculateVoxelSizes(), TexGen::CRotatedVoxelMesh::CalculateVoxelSizes(), TexGen::CShearedVoxelMesh::CalculateVoxelSizes(), TexGen::COctreeVoxelMesh::ConvertOctreeToNodes(), GetElementMap(), TexGen::CVoxelMesh::OutputAllNodesSet(), OutputHexElements(), TexGen::CVoxelMesh::OutputHexElements(), OutputNodes(), TexGen::CRectangularVoxelMesh::OutputNodes(), TexGen::CRotatedVoxelMesh::OutputNodes(), TexGen::CShearedVoxelMesh::OutputNodes(), TexGen::CStaggeredVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::OutputPeriodicBoundaries(), TexGen::CVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::SaveVoxelMesh(), TexGen::COctreeVoxelMesh::storePointInfo(), and TexGen::COctreeVoxelMesh::writeTempFile().