A set of routines for cutting polyhedra have been added. These can cut polyhedral cells based on the adjacent point values and an iso-value which defines the surface. The method operates directly on the polyhedral cells; it does not decompose them into tetrahedra at any point. The routines can compute the cut topology as well as integrals of properties above and below the cut surface. An iso-surface algorithm has been added based on these polyhedral cutting routines. It is significantly more robust than the previous algorithm, and produces compact surfaces equivalent to the previous algorithm's maximum filtering level. It is also approximately 3 times faster than the previous algorithm, and 10 times faster when run repeatedly on the same set of cells (this is because some addressing is cached and reused). This algorithm is used by the 'isoSurface', 'distanceSurface' and 'cutPlane' sampled surfaces. The 'cutPlane' sampled surface is a renaming of 'cuttingPlane' to make it consistent with the corresponding packaged function. The name 'cuttingPlane' has been retained for backwards compatibility and can still be used to select a 'cutPlane' surface. The legacy 'plane' surface has been removed. The 'average' keyword has been removed from specification of these sampled surfaces as cell-centred values are no longer used in the generation of or interpolation to an iso-surface. The 'filtering' keyword has also been removed as it relates to options within the previous algorithm. Zone support has been reinstated into the 'isoSurface' sampled surface. Interpolation to all these sampled surfaces has been corrected to exactly match the user-selected interpolation scheme, and the interpolation procedure no longer unnecessarily re-generates data that is already available.
75 lines
1.4 KiB
C++
75 lines
1.4 KiB
C++
/*--------------------------------*- C++ -*----------------------------------*\
|
|
========= |
|
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
|
\\ / O peration | Website: https://openfoam.org
|
|
\\ / A nd | Version: dev
|
|
\\/ M anipulation |
|
|
\*---------------------------------------------------------------------------*/
|
|
FoamFile
|
|
{
|
|
format ascii;
|
|
class dictionary;
|
|
object controlDict;
|
|
}
|
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
|
|
application foamRun;
|
|
|
|
solver incompressibleFluid;
|
|
|
|
startFrom startTime;
|
|
|
|
startTime 0;
|
|
|
|
stopAt endTime;
|
|
|
|
endTime 0.7;
|
|
|
|
deltaT 1e-4;
|
|
|
|
writeControl timeStep;
|
|
|
|
writeInterval 1000;
|
|
|
|
purgeWrite 0;
|
|
|
|
writeFormat binary;
|
|
|
|
writePrecision 6;
|
|
|
|
writeCompression off;
|
|
|
|
timeFormat general;
|
|
|
|
timePrecision 6;
|
|
|
|
runTimeModifiable true;
|
|
|
|
cacheTemporaryObjects
|
|
(
|
|
SpalartAllmarasDDES:LESRegion
|
|
);
|
|
|
|
functions
|
|
{
|
|
writeCachedObjects
|
|
{
|
|
type writeObjects;
|
|
libs ("libutilityFunctionObjects.so");
|
|
|
|
writeControl writeTime;
|
|
writeOption anyWrite;
|
|
|
|
objects
|
|
(
|
|
SpalartAllmarasDDES:LESRegion
|
|
);
|
|
}
|
|
|
|
#include "cutPlane"
|
|
#include "streamlines"
|
|
#include "forceCoeffs"
|
|
}
|
|
|
|
// ************************************************************************* //
|