43 const IOobject& fieldIoObject
47 PtrList<GeometricField<Type, faPatchField, areaMesh>> procFields
57 new GeometricField<Type, faPatchField, areaMesh>
62 procMeshes_[procI].time().timeName(),
73 Field<Type> internalField(mesh_.
nFaces());
76 PtrList<faPatchField<Type>> patchFields(mesh_.
boundary().size());
88 for(label i=1; i<mesh_.
boundary().size(); i++)
90 gStarts[i] = gStarts[i-1] + mesh_.
boundary()[i-1].labelList::size();
95 const GeometricField<Type, faPatchField, areaMesh>& procField =
101 procField.internalField(),
102 faceProcAddressing_[procI]
111 if(procMeshes_[procI].
boundary().size() > 0)
113 starts[0] = procMeshes_[procI].nInternalEdges();
116 for(label i=1; i<procMeshes_[procI].boundary().size(); i++)
120 + procMeshes_[procI].boundary()[i-1].labelList::size();
123 forAll(boundaryProcAddressing_[procI], patchI)
126 const label curBPatch = boundaryProcAddressing_[procI][patchI];
139 edgeProcAddressing_[procI],
140 procMeshes_[procI].
boundary()[patchI].size(),
149 if (!patchFields(curBPatch))
156 procField.boundaryField()[patchI],
159 faPatchFieldReconstructor
162 procField.boundaryField()[patchI].size()
168 const label curPatchStart = gStarts[curBPatch];
178 reverseAddressing[edgeI] =
cp[edgeI] - curPatchStart;
181 patchFields[curBPatch].rmap
183 procField.boundaryField()[patchI],
189 const Field<Type>& curProcPatch =
190 procField.boundaryField()[patchI];
199 label curE =
cp[edgeI];
205 label curBPatch = -1;
215 + mesh_.
boundary()[pI].labelList::size()
223 if (!patchFields(curBPatch))
242 label curPatchEdge = curE - gStarts[curBPatch];
244 patchFields[curBPatch][curPatchEdge] =
257 isA<emptyFaPatch>(mesh_.
boundary()[patchI])
258 && !patchFields(patchI)
266 emptyFaPatchField<Type>::typeName,
277 return tmp<GeometricField<Type, faPatchField, areaMesh>>
::New
281 fieldIoObject.name(),
288 procFields[0].dimensions(),
299 const IOobject& fieldIoObject
303 PtrList<GeometricField<Type, faePatchField, edgeMesh>> procFields
308 forAll(procMeshes_, procI)
313 new GeometricField<Type, faePatchField, edgeMesh>
317 fieldIoObject.name(),
318 procMeshes_[procI].time().timeName(),
319 procMeshes_[procI](),
330 Field<Type> internalField(mesh_.nInternalEdges());
333 PtrList<faePatchField<Type>> patchFields(mesh_.boundary().size());
336 labelList gStarts(mesh_.boundary().size(), -1);
338 if(mesh_.boundary().size() > 0)
340 gStarts[0] = mesh_.nInternalEdges();
343 for(label i=1; i<mesh_.boundary().size(); i++)
345 gStarts[i] = gStarts[i-1] + mesh_.boundary()[i-1].labelList::size();
349 forAll(procMeshes_, procI)
351 const GeometricField<Type, faePatchField, edgeMesh>& procField =
360 labelList curAddr(edgeProcAddressing_[procI]);
369 procField.internalField(),
378 if(procMeshes_[procI].
boundary().size() > 0)
380 starts[0] = procMeshes_[procI].nInternalEdges();
383 for(label i=1; i<procMeshes_[procI].boundary().size(); i++)
387 + procMeshes_[procI].boundary()[i-1].labelList::size();
390 forAll(boundaryProcAddressing_[procI], patchI)
393 const label curBPatch = boundaryProcAddressing_[procI][patchI];
406 edgeProcAddressing_[procI],
407 procMeshes_[procI].
boundary()[patchI].size(),
416 if (!patchFields(curBPatch))
423 procField.boundaryField()[patchI],
424 mesh_.boundary()[curBPatch],
426 faPatchFieldReconstructor
428 mesh_.boundary()[curBPatch].size(),
429 procField.boundaryField()[patchI].size()
435 const label curPatchStart = gStarts[curBPatch];
445 reverseAddressing[edgeI] =
cp[edgeI] - curPatchStart;
448 patchFields[curBPatch].rmap
450 procField.boundaryField()[patchI],
456 const Field<Type>& curProcPatch =
457 procField.boundaryField()[patchI];
464 label curE =
cp[edgeI];
470 if (curE >= mesh_.nInternalEdges())
475 label curBPatch = -1;
477 forAll(mesh_.boundary(), pI)
485 + mesh_.boundary()[pI].labelList::size()
493 if (!patchFields(curBPatch))
500 mesh_.boundary()[curBPatch].type(),
501 mesh_.boundary()[curBPatch],
513 label curPatchEdge = curE - gStarts[curBPatch];
515 patchFields[curBPatch][curPatchEdge] =
521 internalField[curE] = curProcPatch[edgeI];
529 forAll(mesh_.boundary(), patchI)
534 isA<emptyFaPatch>(mesh_.boundary()[patchI])
535 && !patchFields(patchI)
543 emptyFaePatchField<Type>::typeName,
544 mesh_.boundary()[patchI],
554 return tmp<GeometricField<Type, faePatchField, edgeMesh>>
::New
558 fieldIoObject.name(),
559 mesh_.time().timeName(),
565 procFields[0].dimensions(),
576 const IOobjectList& objects
579 const word& clsName =
580 GeometricField<Type, faPatchField, areaMesh>::typeName;
582 const wordList fieldNames = objects.sortedNames(clsName);
584 if (fieldNames.size())
586 Info<<
" Reconstructing " << clsName <<
"s\n" <<
endl;
589 for (
const word& fieldName : fieldNames)
592 reconstructFaAreaField<Type>(*(objects[fieldName]))().
write();
603 const IOobjectList& objects
606 const word& clsName =
607 GeometricField<Type, faePatchField, edgeMesh>::typeName;
609 const wordList fieldNames = objects.sortedNames(clsName);
611 if (fieldNames.size())
613 Info<<
" Reconstructing " << clsName <<
"s\n" <<
endl;
616 for (
const word& fieldName : fieldNames)
620 reconstructFaEdgeField<Type>(*(objects[fieldName]))().
write();