View Issue Details

IDProjectCategoryView StatusLast Update
0004035OpenFOAMBugpublic2024-05-15 16:37
Reporterblocksgearing0d Assigned Tohenry  
PrioritynormalSeveritycrashReproducibilityalways
Status resolvedResolutionfixed 
PlatformGNU/LinuxOSUbuntuOS Version20.04
Product Version11 
Fixed in Versiondev 
Summary0004035: extrudeMesh uses defaultRegion mesh when using region option
DescriptionextrudeMesh uses defaultRegion mesh when using region option. The bug is both for v11 and dev.
Steps To ReproduceJust run the $FOAM_ETC/templates/axisymmetricJet case using the following:

runApplication blockMesh -dict system/blockMeshDict -region meshToMesh_1
runApplication extrudeMesh -dict system/extrudeMeshDict -region meshToMesh_1

, which will raise an fatal error since it will try to read the mesh from the constant/polyMesh/ instead of constant/polyMesh/meshToMesh_1.
Additional InformationApply the provided one-line patch. Commit comment and attribution could be:
extrudeMesh: prevent loading mesh from constant when using region option

Resolves bug-report https://bugs.openfoam.org/view.php?id=4035

Patch contributed by Stanislau Stasheuski, Aalto University.
TagsNo tags attached.

Activities

blocksgearing0d

2023-11-16 14:30

reporter  

patch.diff (1,260 bytes)   
diff --git a/applications/utilities/mesh/generation/extrudeMesh/extrudeMesh.C b/applications/utilities/mesh/generation/extrudeMesh/extrudeMesh.C
index fe21de0b74..ac32641ecd 100644
--- a/applications/utilities/mesh/generation/extrudeMesh/extrudeMesh.C
+++ b/applications/utilities/mesh/generation/extrudeMesh/extrudeMesh.C
@@ -217,22 +217,6 @@ int main(int argc, char *argv[])
     #include "setRootCase.H"
     #include "createTimeExtruded.H"
 
-    // Get optional regionName
-    word regionName;
-    word regionDir;
-    if (args.optionReadIfPresent("region", regionName))
-    {
-        regionDir = regionName;
-        Info<< "Create mesh " << regionName << " for time = "
-            << runTimeExtruded.name() << nl << endl;
-    }
-    else
-    {
-        regionName = fvMesh::defaultRegion;
-        Info<< "Create mesh for time = "
-            << runTimeExtruded.name() << nl << endl;
-    }
-
     const dictionary dict(systemDict("extrudeMeshDict", args, runTimeExtruded));
 
     // Point generator
@@ -318,7 +302,7 @@ int main(int argc, char *argv[])
             sourceCaseDir
         );
 
-        #include "createMeshNoChangers.H"
+        #include "createNamedMesh.H"
 
         const polyBoundaryMesh& patches = mesh.boundaryMesh();
 
patch.diff (1,260 bytes)   

henry

2023-11-16 16:21

manager   ~0013155

Resolved by commit 9966350d7ebe0a2b2b66947e068c52bffbea7758

Issue History

Date Modified Username Field Change
2023-11-16 14:30 blocksgearing0d New Issue
2023-11-16 14:30 blocksgearing0d File Added: patch.diff
2023-11-16 16:21 henry Assigned To => henry
2023-11-16 16:21 henry Status new => resolved
2023-11-16 16:21 henry Resolution open => fixed
2023-11-16 16:21 henry Fixed in Version => dev
2023-11-16 16:21 henry Note Added: 0013155