Go to the documentation of this file.
28 #include "triSurface.H"
35 namespace extrudeModels
50 project_(coeffDict_.lookupOrDefault(
"project", false))
80 <<
"offsetSurface " << offsetName
81 <<
" should have exactly the same topology as the baseSurface "
95 point offsetSurface::operator()
97 const point& surfacePoint,
98 const vector& surfaceNormal,
111 baseSearchPtr_().findNearest(
samples, nearestDistSqr, info);
113 label triI = info[0].index();
125 const point offsetPoint
127 bary[0]*offsetTri.
a()
128 +bary[1]*offsetTri.
b()
129 +bary[2]*offsetTri.
c()
132 point interpolatedPoint
134 surfacePoint + sumThickness(layer)*(offsetPoint-surfacePoint)
144 offsetSearchPtr_().findNearest
150 return info[0].hitPoint();
154 return interpolatedPoint;
vectorField pointField
pointField is a vectorField.
autoPtr< triSurfaceSearch > baseSearchPtr_
search engine
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
const Field< PointType > & points() const
Return reference to global points.
A class for handling file names.
defineTypeNameAndDebug(cyclicSector, 0)
Top level extrusion model class.
label nEdges() const
Return number of edges in patch.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
autoPtr< triSurface > baseSurfPtr_
surface
Helper class to search on triSurface.
scalar barycentric(const point &pt, List< scalar > &bary) const
Calculate the barycentric coordinates of the given.
A triangle primitive used to calculate face normals and swept volumes.
scalarField samples(nIntervals, 0)
const Point & c() const
Return third vertex.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m.K].
Pre-declare SubField and related Field type.
Triangulated surface description with patch information.
const Point & a() const
Return first vertex.
label nPoints() const
Return number of points supporting patch faces.
A list of keyword definitions, which are a keyword followed by any number of values (e....
addToRunTimeSelectionTable(extrudeModel, cyclicSector, dictionary)
const Point & b() const
Return second vertex.
Macros for easy insertion into run-time selection tables.
errorManipArg< error, int > exit(error &err, const int errNo=1)
virtual ~offsetSurface()
Destructor.
autoPtr< triSurfaceSearch > offsetSearchPtr_
search engine
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
string & expand(const bool allowEmpty=false)
Expand initial tildes and all occurences of environment variables.
autoPtr< triSurface > offsetSurfPtr_
offsets
offsetSurface(const dictionary &dict)
Construct from dictionary.
const dictionary & coeffDict_
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
void size(const label)
Override size to be inconsistent with allocated storage.