Skip to content
GitLab
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
3a569c9f
Commit
3a569c9f
authored
Mar 27, 2018
by
Andrew Heather
Browse files
ENH: streamLineBase - construct with curve distance
parent
801fb7bd
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/functionObjects/field/streamLine/streamLineBase.C
View file @
3a569c9f
...
...
@@ -3,7 +3,7 @@
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
\\/ M anipulation | Copyright (C) 2015-201
7
OpenCFD Ltd.
\\/ M anipulation | Copyright (C) 2015-201
8
OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
...
...
@@ -668,18 +668,28 @@ bool Foam::functionObjects::streamLineBase::writeToFile()
{
if
(
allTracks_
[
tracki
].
size
())
{
List
<
point
>&
points
=
allTracks_
[
tracki
];
scalarList
dist
(
points
.
size
());
dist
[
0
]
=
0
;
for
(
label
pointi
=
1
;
pointi
<
points
.
size
();
++
pointi
)
{
dist
[
pointi
]
=
dist
[
pointi
-
1
]
+
mag
(
points
[
pointi
]
-
points
[
pointi
-
1
]);
}
tracks
.
set
(
nTracks
,
new
coordSet
(
"track"
+
Foam
::
name
(
nTracks
),
sampledSetAxis
()
// "xyz"
sampledSetAxis
(),
// "xyz"
std
::
move
(
allTracks_
[
tracki
]),
std
::
move
(
dist
)
)
);
oldToNewTrack
[
tracki
]
=
nTracks
;
tracks
[
nTracks
].
transfer
(
allTracks_
[
tracki
]);
nTracks
++
;
++
nTracks
;
}
}
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment