Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
3c1982e2
Commit
3c1982e2
authored
Jun 02, 2017
by
Chris Greenshields
Committed by
Andrew Heather
Jun 02, 2017
Browse files
surfaceFind: output region/zone number of found face
parent
0bc9a459
Changes
1
Hide whitespace changes
Inline
Side-by-side
applications/utilities/surface/surfaceFind/surfaceFind.C
View file @
3c1982e2
...
...
@@ -84,10 +84,10 @@ int main(int argc, char *argv[])
}
Info
<<
"Nearest vertex:"
<<
nl
<<
" index :"
<<
minIndex
<<
" (in localPoints)"
<<
nl
<<
" index :"
<<
surf1
.
meshPoints
()[
minIndex
]
<<
" index :
"
<<
minIndex
<<
" (in localPoints)"
<<
nl
<<
" index :
"
<<
surf1
.
meshPoints
()[
minIndex
]
<<
" (in points)"
<<
nl
<<
" coordinates:"
<<
localPoints
[
minIndex
]
<<
nl
<<
" coordinates:
"
<<
localPoints
[
minIndex
]
<<
nl
<<
endl
;
//
...
...
@@ -114,14 +114,26 @@ int main(int argc, char *argv[])
const
face
&
f
=
surf1
[
minIndex
];
Info
<<
"Face with nearest centre:"
<<
nl
<<
" index :"
<<
minIndex
<<
nl
<<
" centre :"
<<
f
.
centre
(
points
)
<<
nl
<<
" face :"
<<
f
<<
nl
<<
" vertex coords:
\n
"
;
<<
" index : "
<<
minIndex
<<
nl
<<
" centre : "
<<
f
.
centre
(
points
)
<<
nl
<<
" face : "
<<
f
<<
nl
<<
" vertex coords:"
<<
endl
;
forAll
(
f
,
fp
)
{
Info
<<
" "
<<
points
[
f
[
fp
]]
<<
"
\n
"
;
Info
<<
" "
<<
points
[
f
[
fp
]]
<<
nl
;
}
const
List
<
surfZone
>&
surfZones
=
surf1
.
surfZones
();
label
surfZone
=
-
1
;
forAll
(
surfZones
,
zonei
)
{
if
(
minIndex
>=
surfZones
[
zonei
].
start
())
{
surfZone
=
zonei
;
}
}
Info
<<
" zone/region : "
<<
surfZone
<<
endl
;
Info
<<
nl
<<
"End
\n
"
<<
endl
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment