Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
polyLine Class Reference

A series of straight line segments, which can also be interpreted as a series of control points for splines, etc. More...

Inheritance diagram for polyLine:
Inheritance graph
[legend]
Collaboration diagram for polyLine:
Collaboration graph
[legend]

Public Member Functions

 polyLine (const pointField &points, const bool notImplementedClosed=false)
 
 polyLine (const point &start, const pointField &intermediate, const point &end, const bool notImplementedClosed=false)
 
const pointFieldpoints () const noexcept
 
label nSegments () const noexcept
 
point position (const scalar) const
 
point position (const label segment, const scalar) const
 
scalar length () const noexcept
 

Static Public Member Functions

static tmp< pointFieldconcat (const point &start, const pointField &intermediate, const point &end)
 

Protected Member Functions

void calcParam ()
 
label localParameter (scalar &lambda) const
 

Protected Attributes

pointField points_
 
scalar lineLength_
 
scalarList param_
 

Detailed Description

A series of straight line segments, which can also be interpreted as a series of control points for splines, etc.

A future implementation could also handle a closed polyLine.

Source files

Definition at line 51 of file polyLine.H.

Constructor & Destructor Documentation

◆ polyLine() [1/2]

polyLine ( const pointField points,
const bool  notImplementedClosed = false 
)
explicit
Parameters
pointsThe poly-line points

Definition at line 77 of file polyLine.C.

References polyLine::calcParam().

Here is the call graph for this function:

◆ polyLine() [2/2]

polyLine ( const point start,
const pointField intermediate,
const point end,
const bool  notImplementedClosed = false 
)
Parameters
startThe start point
intermediateThe intermediate points
endThe end point

Definition at line 88 of file polyLine.C.

Member Function Documentation

◆ calcParam()

void calcParam ( )
protected

Definition at line 50 of file polyLine.C.

References polyLine::lineLength_, Foam::mag(), polyLine::param_, polyLine::points_, and List::resize().

Referenced by polyLine::polyLine().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ localParameter()

Foam::label localParameter ( scalar &  lambda) const
protected

Definition at line 117 of file polyLine.C.

References lambda().

Referenced by BSpline::position().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ concat()

Foam::tmp< Foam::pointField > concat ( const point start,
const pointField intermediate,
const point end 
)
static
Parameters
startThe start point
intermediateThe intermediate points
endThe end point

Definition at line 28 of file polyLine.C.

References Foam::New(), and p0.

Referenced by blockEdge::appendEndPoints().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ points()

const Foam::pointField & points ( ) const
noexcept

Definition at line 105 of file polyLine.C.

Referenced by BSpline::position().

Here is the caller graph for this function:

◆ nSegments()

Foam::label nSegments ( ) const
noexcept

Definition at line 111 of file polyLine.C.

◆ position() [1/2]

Foam::point position ( const scalar  mu) const

Definition at line 151 of file polyLine.C.

References lambda(), and Foam::constant::physicoChemical::mu.

Referenced by polyLineEdge::position().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ position() [2/2]

Foam::point position ( const label  segment,
const scalar  mu 
) const

Definition at line 170 of file polyLine.C.

References Foam::constant::physicoChemical::mu, and p0.

◆ length()

Foam::scalar length ( ) const
noexcept

Definition at line 203 of file polyLine.C.

Member Data Documentation

◆ points_

pointField points_
protected

Definition at line 58 of file polyLine.H.

Referenced by polyLine::calcParam().

◆ lineLength_

scalar lineLength_
protected

Definition at line 61 of file polyLine.H.

Referenced by polyLine::calcParam(), and polyLineEdge::length().

◆ param_

scalarList param_
protected

Definition at line 64 of file polyLine.H.

Referenced by polyLine::calcParam().


The documentation for this class was generated from the following files: