83#ifdef __MPI_PARALLEL_MODE
105 outputManager = std::make_unique<OutputManager>(this);
108 this->engineeringModel = e;
110 this->serialNumber = serNum;
112 dType = _unknownMode;
120#ifdef __MPI_PARALLEL_MODE
126Domain :: ~Domain() { }
158#ifdef __MPI_PARALLEL_MODE
165Domain :: giveElement(
int n)
176Domain :: giveGlobalElement(
int n)
179 if ( el->giveGlobalNumber() == n ) {
188Domain :: giveElementPlaceInArray(
int iGlobalElNum)
const
195 OOFEM_ERROR(
"returning -1 for iGlobalElNum: %d.", iGlobalElNum );
201Domain :: giveDofManPlaceInArray(
int iGlobalDofManNum)
const
208 OOFEM_ERROR(
"returning -1 for iGlobalDofManNum: %d.", iGlobalDofManNum );
214Domain :: giveElementsWithMaterialNum(
int iMaterialNum)
const
226Domain :: giveLoad(
int n)
229 if ( n < 1 || n > (
int)
bcList.size() ) {
236 OOFEM_ERROR(
"cannot cast boundary condition %d to Load class", n);
239 return static_cast< Load *
>(
bcList[n-1].get() );
246Domain :: giveBc(
int n)
249 if ( n < 1 || n > (
int)
bcList.size() ) {
258Domain :: giveIc(
int n)
261 if ( n < 1 || n > (
int)
icList.size() ) {
271Domain :: giveFunction(
int n)
275 OOFEM_ERROR(
"undefined load-time function (%d)", n);
284Domain :: giveMaterial(
int n)
296Domain :: giveSide(
int n)
305 OOFEM_ERROR(
"incompatible type of dofManager %d, can not convert", n);
317Domain :: giveDofManager(
int n)
329Domain :: giveGlobalDofManager(
int n)
332 if ( dman->giveGlobalNumber() == n ) {
342Domain :: giveCrossSection(
int n)
354Domain :: giveNonlocalBarrier(
int n)
366Domain :: giveSet(
int n)
369 if ( n < 1 || n > (
int)
setList.size() ) {
378Domain :: giveXfemManager()
389Domain :: hasXfemManager()
396Domain :: hasFractureManager()
402Domain :: giveFractureManager()
419Domain :: giveEngngModel()
445void Domain :: resizeDofManagers(
int _newSize) {
dofManagerList.resize(_newSize); }
446void Domain :: resizeElements(
int _newSize) {
elementList.resize(_newSize); }
447void Domain :: resizeCrossSectionModels(
int _newSize) {
crossSectionList.resize(_newSize); }
448void Domain :: resizeMaterials(
int _newSize) {
materialList.resize(_newSize); }
450void Domain :: resizeBoundaryConditions(
int _newSize) {
bcList.resize(_newSize); }
451void Domain :: resizeInitialConditions(
int _newSize) {
icList.resize(_newSize); }
452void Domain :: resizeFunctions(
int _newSize) {
functionList.resize(_newSize); }
453void Domain :: resizeSets(
int _newSize) {
setList.resize(_newSize); }
464void Domain :: py_setSet(
int i,
Set *obj) {
setList[i-1].reset(obj); }
468void Domain :: setCrossSection(
int i, std::unique_ptr<CrossSection> obj) {
crossSectionList[i-1] = std::move(obj); }
469void Domain :: setMaterial(
int i, std::unique_ptr<Material> obj) {
materialList[i-1] = std::move(obj); }
470void Domain :: setNonlocalBarrier(
int i, std::unique_ptr<NonlocalBarrier> obj) {
nonlocalBarrierList[i-1] = std::move(obj); }
471void Domain :: setBoundaryCondition(
int i, std::unique_ptr<GeneralBoundaryCondition> obj) {
bcList[i-1] = std::move(obj); }
472void Domain :: setInitialCondition(
int i, std::unique_ptr<InitialCondition> obj) {
icList[i-1] = std::move(obj); }
473void Domain :: setFunction(
int i, std::unique_ptr<Function> obj) {
functionList[i-1] = std::move(obj); }
474void Domain :: setSet(
int i, std::unique_ptr<Set> obj) {
setList[i-1] = std::move(obj); }
475void Domain :: setXfemManager(std::unique_ptr<XfemManager> obj) {
xfemManager = std::move(obj); }
477void Domain :: clearBoundaryConditions() {
bcList.clear(); }
489 std :: string name, topologytype;
490 int componentRecPriority = 2;
533 int dofManagerIndex0=0;
534 for(
auto& ir: dofManagerRecs){
539 std :: unique_ptr< DofManager > dman(
classFactory.createDofManager(name.c_str(), dofManagerIndex0+1,
this) );
541 OOFEM_ERROR(
"Couldn't create node of type: %s\n", name.c_str());
544 dman->initializeFrom(ir, componentRecPriority);
545 dman->setGlobalNumber(num);
563 for(
auto& ir: elemRecs){
567 std :: unique_ptr< Element >elem(
classFactory.createElement(name.c_str(), elemIndex0+1,
this) );
569 OOFEM_ERROR(
"Couldn't create element: %s", name.c_str());
571 elem->initializeFrom(ir, componentRecPriority);
572 elem->setGlobalNumber(num);
590 std::unique_ptr< Set > set = std::make_unique<Set>(num,
this);
592 OOFEM_ERROR(
"Couldn't create set: %s", name.c_str());
595 set->initializeFrom(ir);
598 if ( num < 1 || num > (
int)setRecs.
size() ) {
603 setList[num - 1] = std :: move(set);
605 OOFEM_ERROR(
"Set entry already exist (num=%d)", num);
625 std::unique_ptr< ContactSurface >surface(
classFactory.createContactSurface(name.c_str(), num,
this) );
627 OOFEM_ERROR(
"Couldn't create contact surface: %s", name.c_str() );
630 surface->initializeFrom(ir);
633 if ( num < 1 || num > (
int)contactSurfRecs.
size() ) {
634 OOFEM_ERROR(
"Invalid contact surface number (num=%d)", num);
640 OOFEM_ERROR(
"Contact surface entry already exist (num=%d)", num);
655 std :: unique_ptr< CrossSection >crossSection(
classFactory.createCrossSection(name.c_str(), num,
this) );
656 if ( !crossSection ) {
657 OOFEM_ERROR(
"Couldn't create crosssection: %s", name.c_str());
660 crossSection->initializeFrom(ir);
663 if ( ( num < 1 ) || ( num > (
int)csRecs.
size() ) ) {
664 OOFEM_ERROR(
"Invalid crossSection number (num=%d)", num);
670 OOFEM_ERROR(
"crossSection entry already exist (num=%d)", num);
688 std :: unique_ptr< Material >mat(
classFactory.createMaterial(name.c_str(), num,
this) );
690 OOFEM_ERROR(
"Couldn't create material: %s", name.c_str());
693 mat->initializeFrom(ir);
696 if ( ( num < 1 ) || ( num > (
int)matRecs.size() ) ) {
697 OOFEM_ERROR(
"Invalid material number (num=%d)", num);
703 OOFEM_ERROR(
"material entry already exist (num=%d)", num);
721 std :: unique_ptr< NonlocalBarrier >barrier(
classFactory.createNonlocalBarrier(name.c_str(), num,
this) );
723 OOFEM_ERROR(
"Couldn't create barrier: %s", name.c_str());
726 barrier->initializeFrom(ir);
729 if ( ( num < 1 ) || ( num > (
int)barrRecs.size() ) ) {
730 OOFEM_ERROR(
"Invalid barrier number (num=%d)", num);
736 OOFEM_ERROR(
"barrier entry already exist (num=%d)", num);
756 std :: unique_ptr< GeneralBoundaryCondition >bc(
classFactory.createBoundaryCondition(name.c_str(), num,
this) );
758 OOFEM_ERROR(
"Couldn't create boundary condition: %s", name.c_str());
761 bc->initializeFrom(ir);
764 if ( ( num < 1 ) || ( num > (
int)bcRecs.
size() ) ) {
765 OOFEM_ERROR(
"Invalid boundary condition number (num=%d)", num);
769 bcList[num - 1] = std :: move(bc);
771 OOFEM_ERROR(
"boundary condition entry already exist (num=%d)", num);
784 icList.resize(icRecs.size());
794 ic->initializeFrom(ir);
797 if ( ( num < 1 ) || ( num > (
int)icRecs.size() ) ) {
798 OOFEM_ERROR(
"Invalid initial condition number (num=%d)", num);
802 icList[num - 1] = std :: move(ic);
804 OOFEM_ERROR(
"initial condition entry already exist (num=%d)", num);
823 std :: unique_ptr< Function >func(
classFactory.createFunction(name.c_str(), num,
this) );
825 OOFEM_ERROR(
"Couldn't create time function: %s", name.c_str());
828 func->initializeFrom(ir);
831 if ( ( num < 1 ) || ( num > (
int)ltfRecs.size() ) ) {
832 OOFEM_ERROR(
"Invalid Function number (num=%d)", num);
838 OOFEM_ERROR(
"Function entry already exist (num=%d)", num);
856 std :: unique_ptr< Set > set = std::make_unique<Set>(num,
this);
858 OOFEM_ERROR(
"Couldn't create set: %s", name.c_str());
861 set->initializeFrom(ir);
864 if ( ( num < 1 ) || ( num > (
int)setRecs.
size() ) ) {
869 setList[num - 1] = std :: move(set);
871 OOFEM_ERROR(
"Set entry already exist (num=%d)", num);
890 OOFEM_ERROR(
"Couldn't create xfemmanager: %s", name.c_str());
902 if ( topologytype.length() > 0 ) {
905 OOFEM_ERROR(
"Couldn't create topology of type '%s'", topologytype.c_str());
908 return this->
topology->instanciateYourself(dr);
910 VERBOSE_PRINT0(
"Instantiated topologies ", topologytype.length());
916 fracManager = std::make_unique<FractureManager>(
this);
935 if (
dType == _1dTrussMode ) {
937 }
else if (
dType == _2dIncompressibleFlow ||
dType == _2dBeamMode ||
dType == _2dTrussMode ||
dType == _2dMindlinPlateMode ||
dType == _PlaneStrainMode ||
dType == _2dPlaneStressMode ||
dType == _2dPlaneStressRotMode ||
dType == _WarpingMode ) {
939 }
else if (
dType == _3dIncompressibleFlow ||
dType == _3dShellMode ||
dType == _3dMode ||
dType == _3dDirShellMode ) {
941 }
else if (
dType == _3dAxisymmMode ) {
955 dman->initializeFinish();
960 for (
auto &dman: this->dofManagerList ) {
961 dman->updateLocalNumbering(labelToLocNumFunctor);
965 element->updateLocalNumbering(labelToLocNumFunctor);
969 set->updateLocalNumbering(labelToLocNumFunctor);
987 if (this->
elementPPM.getPriority(ielem, indx) <= 1) {
999 if (!elemProps.empty()) {
1007 if (!dofmanProps.empty()) {
1018 el->initializeFinish();
1023Domain :: postInitialize()
1042 dman->postInitialize();
1047 el->postInitialize();
1052 cs->postInitialize();
1056 for (
auto &bc:
bcList ) {
1057 bc->postInitialize();
1067Domain :: errorInfo(
const char *func)
const
1069 return std::string(
"Domain::") + func +
", number: " + std::to_string(
number);
1074Domain :: giveDefaultNodeDofIDArry()
1082 if (
dType == _2dPlaneStressRotMode ) {
1084 }
else if (
dType == _2dPlaneStressMode ) {
1086 }
else if (
dType == _PlaneStrainMode ) {
1088 }
else if (
dType == _3dMode ) {
1090 }
else if (
dType == _3dAxisymmMode ) {
1092 }
else if (
dType == _2dMindlinPlateMode ) {
1094 }
else if (
dType == _3dShellMode ) {
1096 }
else if (
dType == _2dTrussMode ) {
1098 }
else if (
dType == _1dTrussMode ) {
1100 }
else if (
dType == _2dBeamMode ) {
1102 }
else if (
dType == _2dLatticeMode ) {
1104 }
else if (
dType == _HeatTransferMode ) {
1106 }
else if (
dType == _Mass1TransferMode ) {
1108 }
else if (
dType == _HeatMass1Mode ) {
1110 }
else if (
dType == _2dIncompressibleFlow ) {
1112 }
else if (
dType == _3dIncompressibleFlow ) {
1114 }
else if (
dType == _3dDirShellMode ) {
1116 }
else if (
dType == _2dLatticeMassTransportMode ) {
1118 }
else if (
dType == _3dLatticeMassTransportMode ) {
1120 }
else if (
dType == _3dLatticeMode ) {
1122 }
else if (
dType == _2dLatticeHeatTransferMode ) {
1124 }
else if (
dType == _3dLatticeHeatTransferMode ) {
1126 }
else if (
dType == _WarpingMode ) {
1137Domain :: giveNumberOfSpatialDimensions()
1144Domain :: isAxisymmetric()
1151Domain :: resolveDomainDofsDefaults(
const char *typeName)
1157 if ( !strncmp(typeName,
"2dplanestressrot", 16) ) {
1158 dType = _2dPlaneStressRotMode;
1159 }
else if ( !strncmp(typeName,
"2dplanestress", 12) ) {
1160 dType = _2dPlaneStressMode;
1161 }
else if ( !strncmp(typeName,
"planestrain", 11) ) {
1162 dType = _PlaneStrainMode;
1163 }
else if ( !strncmp(typeName,
"3daxisymm", 9) ) {
1164 dType = _3dAxisymmMode;
1165 }
else if ( !strncmp(typeName,
"2dmindlinplate", 14) ) {
1166 dType = _2dMindlinPlateMode;
1167 }
else if ( !strncmp(typeName,
"3dshell", 7) ) {
1168 dType = _3dShellMode;
1169 }
else if ( !strncmp(typeName,
"2dtruss", 7) ) {
1170 dType = _2dTrussMode;
1171 }
else if ( !strncmp(typeName,
"1dtruss", 7) ) {
1172 dType = _1dTrussMode;
1173 }
else if ( !strncmp(typeName,
"2dbeam", 6) ) {
1174 dType = _2dBeamMode;
1175 }
else if ( !strncmp(typeName,
"2dlattice", 9) ) {
1176 dType = _2dLatticeMode;
1177 }
else if ( !strncmp(typeName,
"heattransfer", 12) ) {
1178 dType = _HeatTransferMode;
1179 }
else if ( !strncmp(typeName,
"mass1transfer", 13) ) {
1180 dType = _Mass1TransferMode;
1181 }
else if ( !strncmp(typeName,
"hema1", 5) ) {
1182 dType = _HeatMass1Mode;
1183 }
else if ( !strncmp(typeName,
"2dincompflow", 12) ) {
1184 dType = _2dIncompressibleFlow;
1185 }
else if ( !strncmp(typeName,
"3dincompflow", 12) ) {
1186 dType = _3dIncompressibleFlow;
1187 }
else if ( !strncmp(typeName,
"3ddirshell", 10) ) {
1188 dType = _3dDirShellMode;
1189 }
else if ( !strncmp(typeName,
"2dmasslatticetransport", 22) ) {
1190 dType = _2dLatticeMassTransportMode;
1191 }
else if ( !strncmp(typeName,
"3dlattice", 9) ) {
1192 dType = _3dLatticeMode;
1193 }
else if ( !strncmp(typeName,
"3dmasslatticetransport", 22) ) {
1194 dType = _3dLatticeMassTransportMode;
1195 }
else if ( !strncmp(typeName,
"2dheatlattice", 13) ) {
1196 dType = _3dLatticeMassTransportMode;
1197 }
else if ( !strncmp(typeName,
"3dheatlattice", 13) ) {
1198 dType = _3dLatticeMassTransportMode;
1199 }
else if ( !strncmp(typeName,
"3d", 2) ) {
1201 }
else if ( !strncmp(typeName,
"warping", 7) ) {
1202 dType = _WarpingMode;
1211Domain :: giveSmoother()
1220 if ( !destroyOld ) {
1231 if ( !destroyOld ) {
1240Domain :: giveConnectivityTable()
1255Domain :: giveSpatialLocalizer()
1269void Domain :: setSpatialLocalizer(std::unique_ptr<SpatialLocalizer> sl){
1275Domain :: createDofs()
1284 for (
int j = 1; j <= element->giveNumberOfNodes(); ++j ) {
1285 element->giveDofManDofIDMask(j, dofids);
1286 for (
int k = 1; k <= dofids.
giveSize(); k++ ) {
1287 node_dofs [ element->giveNode(j)->giveNumber() - 1 ].insert( dofids.
at(k) );
1293 const IntArray *dofids = dman->giveForcedDofIDs();
1295 for (
int k = 1; k <= dofids->
giveSize(); ++k ) {
1296 node_dofs [ dman->giveNumber() - 1 ].insert( dofids->
at(k) );
1316 for (
int inode = 1; inode <= nodes.
giveSize(); ++inode ) {
1317 for (
int idof = 1; idof <= appliedDofs.
giveSize(); ++idof ) {
1318 dof_bc [ nodes.
at(inode) - 1 ] [ appliedDofs.
at(idof) ] = i;
1328 const std :: map< int, int > *dmanBcs = dman->
giveBcMap();
1330 dof_bc [ i - 1 ].insert( dmanBcs->begin(), dmanBcs->end() );
1344 for (
int indx = 1; indx <= internalelementnodes.
giveSize()/2; ++indx ) {
1345 int ielem = internalelementnodes.
at(indx*2-1);
1346 int idofman = internalelementnodes.
at(indx*2);
1347 for (
int idof = 1; idof <= appliedDofs.
giveSize(); ++idof ) {
1370 for (
int inode = 1; inode <= nodes.
giveSize(); ++inode ) {
1371 for (
int idof = 1; idof <= appliedDofs.
giveSize(); ++idof ) {
1372 dof_ic [ nodes.
at(inode) - 1 ] [ appliedDofs.
at(idof) ] = i;
1381 const std :: map< int, int > *dmanIcs = dman->
giveIcMap();
1383 dof_ic [ i - 1 ].insert( dmanIcs->begin(), dmanIcs->end() );
1396 for (
int id: node_dofs [ i - 1 ] ) {
1398 int bcid = dof_bc [ i - 1 ].find(
id) != dof_bc [ i - 1 ].end() ? dof_bc [ i - 1 ] [ id ] : 0;
1403 const std :: map< int, int > *dmanTypes = dman->
giveDofTypeMap();
1405 std :: map< int, int > :: const_iterator it = dmanTypes->find(
id);
1406 if ( it != dmanTypes->end() ) {
1407 dtype = (
dofType ) it->second;
1422 OOFEM_ERROR(
"Incompatible dof type (%d) in node %d", dtype, i);
1431 if ( dtype == DT_simpleSlave ) {
1438 for (
Dof *dof: *dman ) {
1441 int bcid = dof_bc [ i - 1 ].find(
id) != dof_bc [ i - 1 ].end() ? dof_bc [ i - 1 ] [ id ] : 0;
1442 int icid = dof_ic [ i - 1 ].find(
id) != dof_ic [ i - 1 ].end() ? dof_ic [ i - 1 ] [ id ] : 0;
1444 if (dof->isPrimaryDof()) {
1445 if (dof->giveBcId()==0) dof->setBcId(bcid);
1446 if (dof->giveIcId()==0) dof->setIcId(icid);
1460Domain :: checkConsistency()
1471 result &= dman->checkConsistency();
1475 result &= element->checkConsistency();
1479 result &= material->checkConsistency();
1490 area += element->computeArea();
1497Domain :: giveVolume()
1499 double volume = 0.0;
1501 volume += element->computeVolume();
1510 double volume = 0.0;
1512 volume += element->computeVolumeAreaOrLength();
1519Domain :: giveNextFreeDofID(
int increment)
1522 OOFEM_ERROR(
"Additional dof id's not implemented/tested for parallel problems");
1531Domain :: resetFreeDofID()
1537Domain :: giveErrorEstimator()
1544Domain :: giveOutputManager()
1551Domain :: giveTopology()
1557template<
typename T >
1560 if ( !stream.
write((
int)list.size()) ) {
1563 for (
const auto &
object: list ) {
1565 if ( stream.
write( std :: string( object->giveInputRecordName() ) ) == 0 ) {
1569 object->saveContext(stream, mode);
1574template<
typename T,
typename C >
1578 if ( !stream.
read(size) ) {
1585 for (
int i = 1; i <= size; i++ ) {
1588 if ( !stream.
read(name) ) {
1591 list[i-1] = creator(name, i);
1593 list[i-1]->restoreContext(stream, mode);
1601 if ( !stream.
write(this->giveSerialNumber()) ) {
1620 ee->saveContext(stream, mode);
1628 bool domainUpdated =
false;
1631 if ( !stream.
read(this->serialNumber) ) {
1644 [
this] (std::string &x,
int i) {
return std::make_unique<Set>(i,
this); });
1646 [
this] (std::string &x,
int i) {
return classFactory.createMaterial(x.c_str(), i,
this); });
1648 [
this] (std::string &x,
int i) {
return classFactory.createCrossSection(x.c_str(), i,
this); });
1650 [
this] (std::string &x,
int i) {
return classFactory.createInitialCondition(x.c_str(), i,
this); });
1652 [
this] (std::string &x,
int i) {
return classFactory.createFunction(x.c_str(), i,
this); });
1654 [
this] (std::string &x,
int i) {
return classFactory.createNonlocalBarrier(x.c_str(), i,
this); });
1656 domainUpdated =
true;
1668 domainUpdated =
true;
1673 [
this] (std::string &x,
int i) {
return classFactory.createDofManager(x.c_str(), i,
this); });
1675 [
this] (std::string &x,
int i) {
return classFactory.createElement(x.c_str(), i,
this); });
1677 [
this] (std::string &x,
int i) {
return classFactory.createBoundaryCondition(x.c_str(), i,
this); });
1681 if ( domainUpdated ) {
1682 ee->setDomain(
this);
1684 ee->restoreContext(stream, mode);
1687 if ( domainUpdated ) {
1694#ifdef __MPI_PARALLEL_MODE
1697Domain :: giveTransactionManager()
1719 int lnum =
dmanMap [ dmanTrans.first ]->giveNumber();
1721 dmanMap.erase(dmanTrans.first);
1725 if ( dmanTrans.second ) {
1732 int gen = elTrans.first;
1740 if ( elTrans.second ) {
1792 std :: vector< std :: unique_ptr< Element > > elementList_new;
1795 elementList_new.emplace_back(map.second);
1800 this->elementList = std :: move(elementList_new);
1803 std :: vector< std :: unique_ptr< DofManager > > dofManagerList_new;
1804 dofManagerList_new.reserve(
dmanMap.size());
1806 dofManagerList_new.emplace_back(map.second);
1811 this->dofManagerList = std :: move(dofManagerList_new);
1826Domain :: initGlobalDofManMap(
bool forceinit)
1839 int key = dman->giveGlobalNumber();
1847Domain :: initGlobalElementMap(
bool forceinit)
1853 int key = elem->giveGlobalNumber();
1870 map.second->updateLocalNumbering(domainGToLFunctor);
1873 map.second->updateLocalNumbering(domainLToLFunctor);
1888 map.second->updateLocalNumbering(domainGToLFunctor);
1891 map.second->updateLocalNumbering(domainLToLFunctor);
1898Domain :: renumberDofManagers()
1902 map.second->setNumber(_locnum++);
1908Domain :: renumberElements()
1912 map.second->setNumber(_locnum++);
1923 return dm->giveNumber();
1925 OOFEM_ERROR(
"dofman %d moved to remote partition, updated number not available", num);
1941 return dm->giveNumber();
1943 OOFEM_ERROR(
"dofman [%d] not available on local partition, updated number not available", num);
1955Domain :: dofmanGlobal2Local(
int _globnum)
1967Domain :: elementGlobal2Local(
int _globnum)
1979void Domain :: BuildElementPlaceInArrayMap()
1985 for (
int i = 1; i <= nelem; i++ ) {
1992 OOFEM_ERROR(
"Element with same global number already exist (label=%d)", globnum);
1997void Domain :: BuildDofManPlaceInArrayMap()
2003 for (
int i = 1; i <= ndman; i++ ) {
2010 OOFEM_ERROR(
"DofManagaer with same global number already exist (label=%d)", globnum);
2015void Domain :: BuildMaterialToElementMap()
2021 for (
int i = 1; i <= nelem; i++ ) {
virtual bool requiresActiveDofs()
Internal range-like class, return type for giveGroupRecords methods.
RAII guard for DataReader::enterRecord and DataReader::leaveRecord.
virtual bool peekNext(const std ::string &keyword)
virtual InputRecord & giveInputRecord(InputRecordType irType, int recordId)=0
GroupRecords giveGroupRecords(const std::shared_ptr< InputRecord > &ir, InputFieldType ift, const std::string &name, InputRecordType irType, bool optional)
static constexpr const char * InputRecordTags[]
virtual bool hasFlattenedStructure()
InputRecord * giveChildRecord(const std::shared_ptr< InputRecord > &ir, InputFieldType ift, const std::string &name, InputRecordType irType, bool optional)
Return pointer to subrecord of given type (must be exactly one); if not present, returns nullptr.
virtual int read(int *data, std::size_t count)=0
Reads count integer values into array pointed by data.
virtual int write(const int *data, std::size_t count)=0
Writes count integer values from array pointed by data.
std ::map< int, int > * giveBcMap()
int giveGlobalNumber() const
bool hasDofID(DofIDItem id) const
void setNumberOfDofs(int _ndofs)
std ::map< int, int > * giveIcMap()
virtual bool isDofTypeCompatible(dofType type) const
Returns true if dof of given type is allowed to be associated to receiver.
Dof * giveDofWithID(int dofID) const
std ::map< int, int > * giveMasterMap()
void initializeFrom(InputRecord &ir) override
std ::map< int, int > * giveDofTypeMap()
virtual void setBcId(int bcId)
Overwrites the boundary condition id (0-inactive BC), intended for specific purposes such as coupling...
std ::map< int, DofManager * > dofmanTransactions
std ::map< int, Element * > elementTransactions
std::unordered_map< int, IntArray > materialNum2ElMap
ErrorEstimator * giveErrorEstimator()
std ::vector< std ::unique_ptr< DofManager > > dofManagerList
Dof manager list.
SpatialLocalizer * giveSpatialLocalizer()
std ::unique_ptr< ConnectivityTable > connectivityTable
int instanciateYourself(DataReader &dr)
IntArray defaultNodeDofIDArry
Default dofs for a node (depends on the domain type).
int giveNumberOfBoundaryConditions() const
Returns number of boundary conditions in domain.
ConnectivityTable * giveConnectivityTable()
void BuildDofManPlaceInArrayMap()
InitialCondition * giveIc(int n)
void clear()
Clear receiver.
std::unordered_map< int, int > elementGlobal2LocalMap
std ::vector< std ::unique_ptr< Set > > setList
Set list.
std ::vector< std ::unique_ptr< InitialCondition > > icList
Initial condition list.
void BuildMaterialToElementMap()
int freeDofID
Keeps track of next free dof ID (for special Lagrange multipliers, XFEM and such).
void resolveDomainDofsDefaults(const char *)
std ::unique_ptr< OutputManager > outputManager
Output manager, allowing to filter the produced output.
int giveNumberOfInitialConditions() const
Returns number of initial conditions in domain.
bool dmanMapInitialized
dmanMap init flag.
std ::unique_ptr< SpatialLocalizer > spatialLocalizer
int giveNumber()
Returns domain number.
void initGlobalElementMap(bool forceinit=false)
std ::vector< std ::unique_ptr< NonlocalBarrier > > nonlocalBarrierList
Nonlocal barrier list.
void initGlobalDofManMap(bool forceinit=false)
std::unordered_map< int, int > dofmanGlobal2LocalMap
std::vector< std::unique_ptr< ContactSurface > > & giveContactSurface()
int giveNumberOfSets() const
Returns number of sets.
int giveNumberOfElements() const
Returns number of elements in domain.
void renumberDofManagers()
StateCounterType nonlocalUpdateStateCounter
std ::vector< std ::unique_ptr< GeneralBoundaryCondition > > bcList
Boundary condition list.
bool elementMapInitialized
dmanMap init flag.
int giveNumberOfDofManagers() const
Returns number of dof managers in domain.
std ::unique_ptr< NodalRecoveryModel > smoother
nodal recovery object associated to receiver.
std ::unique_ptr< TopologyDescription > topology
Topology description.
DofManager * giveDofManager(int n)
Element * giveElement(int n)
int nsd
Number of spatial dimensions.
void renumberDofManData(DomainTransactionManager *tm)
GeneralBoundaryCondition * giveBc(int n)
EngngModel * giveEngngModel()
void renumberElementData(DomainTransactionManager *tm)
std ::unique_ptr< FractureManager > fracManager
Fracture Manager.
std ::unique_ptr< DomainTransactionManager > transactionManager
XfemManager * giveXfemManager()
std::vector< std::unique_ptr< ContactSurface > > contactSurfaceList
Contact surface list.
std ::vector< std ::unique_ptr< Element > > elementList
Element list.
ParameterManager elementPPM
int giveSerialNumber()
Returns domain serial (version) number.
EngngModel * engineeringModel
std ::unique_ptr< XfemManager > xfemManager
XFEM Manager.
std ::vector< std ::unique_ptr< CrossSection > > crossSectionList
Cross section list.
std ::map< int, Element * > elementMap
Global element map (index is global of man number).
void BuildElementPlaceInArrayMap()
std ::map< int, DofManager * > dmanMap
Global dof manager map (index is global of man number).
int giveNumberOfCrossSectionModels() const
Returns number of cross section models in domain.
ParameterManager dofmanPPM
std ::vector< std ::unique_ptr< Material > > materialList
Material list.
std ::vector< std ::unique_ptr< Function > > functionList
Load time function list.
BCTracker bcTracker
BC tracker (keeps track of BCs applied wia sets to components).
CrossSection * giveCrossSection(int n)
BCTracker * giveBCTracker()
int giveGlobalNumber() const
static ParamKey IPK_Element_crosssect
virtual void setCrossSection(int csIndx)
void initializeFrom(InputRecord &ir, int priority) override
int giveMaterialNumber() const
bool giveSuppressOutput() const
virtual const IntArray & giveDofIDs() const
int giveSetNumber() const
const IntArray & giveDofIDs()
Renumbering functor based on provided maps.
std::string giveElementProperties() const
const IntArray & giveInternalElementDofManagerList()
const IntArray & giveElementList()
std::string giveDofManProperties() const
const IntArray & giveNodeList()
#define _IFT_Domain_topology
#define _IFT_Domain_axisymmetric
#define _IFT_Domain_ncontactsurf
#define _IFT_Domain_nfunct
#define _IFT_Domain_nfracman
#define _IFT_Domain_nxfemman
#define _IFT_Domain_numberOfSpatialDimensions
[in,optional] Specifies how many spatial dimensions the domain has.
#define _IFT_Domain_ncrosssect
#define _IFT_Domain_ndofman
#define _IFT_Domain_nbarrier
#define _IFT_Domain_nelem
#define _IFT_Domain_type
This is trouble, will not work with dynamic input record.
#define OOFEM_LOG_INFO(...)
#define OOFEM_LOG_ERROR(...)
void save_components(T &list, DataStream &stream, ContextMode mode)
dofType
Dof Type, determines the type of DOF created.
void restore_components(T &list, DataStream &stream, ContextMode mode, const C &creator)
const char * __domainTypeToString(domainType _value)
ClassFactory & classFactory
@ CIO_IOERR
General IO error.
#define VERBOSE_PRINT0(str, number)