Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
openfoam
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Development
openfoam
Commits
dfa2c676
Commit
dfa2c676
authored
15 years ago
by
mattijs
Browse files
Options
Downloads
Patches
Plain Diff
ENH: Allow specification of defaultFaces boundary type
parent
300ac484
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/OpenFOAM/meshes/polyMesh/polyMeshFromShapeMesh.C
+48
-13
48 additions, 13 deletions
src/OpenFOAM/meshes/polyMesh/polyMeshFromShapeMesh.C
with
48 additions
and
13 deletions
src/OpenFOAM/meshes/polyMesh/polyMeshFromShapeMesh.C
+
48
−
13
View file @
dfa2c676
...
...
@@ -577,21 +577,56 @@ Foam::polyMesh::polyMesh
<<
"Found "
<<
nFaces
-
defaultPatchStart
<<
" undefined faces in mesh; adding to default patch."
<<
endl
;
boundary_
.
set
(
nAllPatches
,
polyPatch
::
New
// Check if there already exists a defaultFaces patch as last patch
// and reuse it.
label
patchI
=
findIndex
(
boundaryPatchNames
,
defaultBoundaryPatchName
);
if
(
patchI
!=
-
1
)
{
if
(
patchI
!=
boundaryFaces
.
size
()
-
1
||
boundary_
[
patchI
].
size
())
{
FatalErrorIn
(
"polyMesh::polyMesh(... construct from shapes...)"
)
<<
"Default patch "
<<
boundary_
[
patchI
].
name
()
<<
" already has faces in it or is not"
<<
" last in list of patches."
<<
exit
(
FatalError
);
}
WarningIn
(
"polyMesh::polyMesh(... construct from shapes...)"
)
<<
"Reusing existing patch "
<<
patchI
<<
" for undefined faces."
<<
endl
;
boundary_
.
set
(
defaultBoundaryPatchType
,
defaultBoundaryPatchName
,
nFaces
-
defaultPatchStart
,
defaultPatchStart
,
boundary_
.
size
()
-
1
,
boundary_
)
);
patchI
,
polyPatch
::
New
(
boundaryPatchTypes
[
patchI
],
boundaryPatchNames
[
patchI
],
nFaces
-
defaultPatchStart
,
defaultPatchStart
,
patchI
,
boundary_
)
);
}
else
{
boundary_
.
set
(
nAllPatches
,
polyPatch
::
New
(
defaultBoundaryPatchType
,
defaultBoundaryPatchName
,
nFaces
-
defaultPatchStart
,
defaultPatchStart
,
boundary_
.
size
()
-
1
,
boundary_
)
);
nAllPatches
++
;
nAllPatches
++
;
}
}
// Reset the size of the boundary
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment