40 const IOobject& fieldIoObject
44 PtrList<GeometricField<Type, fvPatchField, volMesh> > procFields
49 forAll (procMeshes_, procI)
54 new GeometricField<Type, fvPatchField, volMesh>
59 procMeshes_[procI].time().timeName(),
71 Field<Type> internalField(mesh_.
nCells());
74 PtrList<fvPatchField<Type> > patchFields(mesh_.
boundary().
size());
77 forAll (procMeshes_, procI)
79 const GeometricField<Type, fvPatchField, volMesh>& procField =
85 procField.internalField(),
86 cellProcAddressing_[procI]
90 forAll(boundaryProcAddressing_[procI], patchI)
93 const label curBPatch = boundaryProcAddressing_[procI][patchI];
97 procMeshes_[procI].boundary()[patchI].patchSlice
99 faceProcAddressing_[procI]
107 if (!patchFields(curBPatch))
112 fvPatchField<Type>::New
114 procField.boundaryField()[patchI],
117 fvPatchFieldReconstructor
125 const label curPatchStart =
134 reverseAddressing[faceI] = cp[faceI] - 1 - curPatchStart;
137 patchFields[curBPatch].rmap
139 procField.boundaryField()[patchI],
145 const Field<Type>& curProcPatch =
146 procField.boundaryField()[patchI];
154 label curF = cp[faceI] - 1;
161 if (!patchFields(curBPatch))
166 fvPatchField<Type>::New
178 [curBPatch].whichFace(curF);
180 patchFields[curBPatch][curPatchFace] =
193 isType<emptyFvPatch>(mesh_.
boundary()[patchI])
194 && !patchFields(patchI)
200 fvPatchField<Type>::New
202 emptyFvPatchField<Type>::typeName,
213 return tmp<GeometricField<Type, fvPatchField, volMesh> >
215 new GeometricField<Type, fvPatchField, volMesh>
219 fieldIoObject.name(),
226 procFields[0].dimensions(),
238 const IOobject& fieldIoObject
242 PtrList<GeometricField<Type, fvsPatchField, surfaceMesh> > procFields
247 forAll (procMeshes_, procI)
252 new GeometricField<Type, fvsPatchField, surfaceMesh>
256 fieldIoObject.name(),
257 procMeshes_[procI].time().timeName(),
269 Field<Type> internalField(mesh_.nInternalFaces());
272 PtrList<fvsPatchField<Type> > patchFields(mesh_.boundary().size());
275 forAll (procMeshes_, procI)
277 const GeometricField<Type, fvsPatchField, surfaceMesh>& procField =
286 labelList curAddr(faceProcAddressing_[procI]);
295 procField.internalField(),
301 forAll(boundaryProcAddressing_[procI], patchI)
304 const label curBPatch = boundaryProcAddressing_[procI][patchI];
308 procMeshes_[procI].boundary()[patchI].patchSlice
310 faceProcAddressing_[procI]
318 if (!patchFields(curBPatch))
323 fvsPatchField<Type>::New
325 procField.boundaryField()[patchI],
326 mesh_.boundary()[curBPatch],
328 fvPatchFieldReconstructor
330 mesh_.boundary()[curBPatch].size()
336 const label curPatchStart =
337 mesh_.boundaryMesh()[curBPatch].start();
345 reverseAddressing[faceI] = cp[faceI] - 1 - curPatchStart;
348 patchFields[curBPatch].rmap
350 procField.boundaryField()[patchI],
356 const Field<Type>& curProcPatch =
357 procField.boundaryField()[patchI];
363 label curF = cp[faceI] - 1;
369 if (curF >= mesh_.nInternalFaces())
372 mesh_.boundaryMesh().whichPatch(curF);
374 if (!patchFields(curBPatch))
379 fvsPatchField<Type>::New
381 mesh_.boundary()[curBPatch].type(),
382 mesh_.boundary()[curBPatch],
392 [curBPatch].whichFace(curF);
394 patchFields[curBPatch][curPatchFace] =
400 internalField[curF] = curProcPatch[faceI];
408 forAll(mesh_.boundary(), patchI)
413 isType<emptyFvPatch>(mesh_.boundary()[patchI])
414 && !patchFields(patchI)
420 fvsPatchField<Type>::New
422 emptyFvsPatchField<Type>::typeName,
423 mesh_.boundary()[patchI],
433 return tmp<GeometricField<Type, fvsPatchField, surfaceMesh> >
435 new GeometricField<Type, fvsPatchField, surfaceMesh>
439 fieldIoObject.name(),
440 mesh_.time().timeName(),
446 procFields[0].dimensions(),
458 const IOobjectList& objects,
459 const HashSet<word>& selectedFields
462 const word& fieldClassName =
465 IOobjectList
fields = objects.lookupClass(fieldClassName);
469 Info<<
" Reconstructing " << fieldClassName <<
"s\n" <<
endl;
475 !selectedFields.size()
476 || selectedFields.found(fieldIter()->
name())
479 Info<<
" " << fieldIter()->name() <<
endl;
481 reconstructFvVolumeField<Type>(*fieldIter())().
write();
492 const IOobjectList& objects,
493 const HashSet<word>& selectedFields
496 const word& fieldClassName =
499 IOobjectList fields = objects.lookupClass(fieldClassName);
503 Info<<
" Reconstructing " << fieldClassName <<
"s\n" <<
endl;
509 !selectedFields.size()
510 || selectedFields.found(fieldIter()->
name())
513 Info<<
" " << fieldIter()->name() <<
endl;
515 reconstructFvSurfaceField<Type>(*fieldIter())().
write();