Open CASCADE Technology Reference Manual 8.0.0
Loading...
Searching...
No Matches
Public Member Functions
ExtremaPC_Parabola Class Reference

Point-Parabola extrema computation. More...

#include <ExtremaPC_Parabola.hxx>

Public Member Functions

 ExtremaPC_Parabola (const gp_Parab &theParabola)
 Constructor with parabola geometry (infinite).
 
 ExtremaPC_Parabola (const gp_Parab &theParabola, const ExtremaPC::Domain1D &theDomain)
 Constructor with parabola geometry and parameter domain.
 
 ExtremaPC_Parabola (const ExtremaPC_Parabola &)=delete
 Copy constructor is deleted.
 
ExtremaPC_Parabolaoperator= (const ExtremaPC_Parabola &)=delete
 Copy assignment operator is deleted.
 
 ExtremaPC_Parabola (ExtremaPC_Parabola &&)=default
 Move constructor.
 
ExtremaPC_Parabolaoperator= (ExtremaPC_Parabola &&)=default
 Move assignment operator.
 
gp_Pnt Value (double theU) const
 Evaluates point on parabola at parameter using cached geometry.
 
bool IsBounded () const
 Returns true if domain is bounded.
 
const ExtremaPC::Domain1DDomain () const
 Returns the domain (only valid if IsBounded() is true).
 
const ExtremaPC::ResultPerform (const gp_Pnt &theP, double theTol, ExtremaPC::SearchMode theMode=ExtremaPC::SearchMode::MinMax) const
 Compute extrema between point P and the parabola. Uses domain specified at construction time.
 
const ExtremaPC::ResultPerformWithEndpoints (const gp_Pnt &theP, double theTol, ExtremaPC::SearchMode theMode=ExtremaPC::SearchMode::MinMax) const
 Compute extrema between point P and the parabola arc including endpoints. Uses domain specified at construction time.
 
const gp_ParabParabola () const
 Returns the parabola geometry.
 

Detailed Description

Point-Parabola extrema computation.

Computes the extrema between a 3D point and a parabola. Uses cubic polynomial solving via MathPoly::Cubic.

The algorithm:

  1. Projects point P onto the parabola plane -> Pp
  2. For parabola C(u) = ((u^2)/(4F), u) with focal length F, solves: (1/(4F)) * u^3 + (2F - X) * u - 2F*Y = 0 where (X, Y) are coordinates of Pp in parabola local frame.
Note
A parabola can have up to 3 extrema.

The domain is fixed at construction time for optimal performance. For infinite parabola, construct without domain or with nullopt.

Constructor & Destructor Documentation

◆ ExtremaPC_Parabola() [1/4]

ExtremaPC_Parabola::ExtremaPC_Parabola ( const gp_Parab & theParabola)
inlineexplicit

Constructor with parabola geometry (infinite).

Parameters
[in]theParabolathe parabola to compute extrema for

◆ ExtremaPC_Parabola() [2/4]

ExtremaPC_Parabola::ExtremaPC_Parabola ( const gp_Parab & theParabola,
const ExtremaPC::Domain1D & theDomain )
inline

Constructor with parabola geometry and parameter domain.

Parameters
[in]theParabolathe parabola to compute extrema for
[in]theDomainparameter domain (fixed for all queries)

◆ ExtremaPC_Parabola() [3/4]

ExtremaPC_Parabola::ExtremaPC_Parabola ( const ExtremaPC_Parabola & )
delete

Copy constructor is deleted.

◆ ExtremaPC_Parabola() [4/4]

ExtremaPC_Parabola::ExtremaPC_Parabola ( ExtremaPC_Parabola && )
default

Move constructor.

Member Function Documentation

◆ Domain()

const ExtremaPC::Domain1D & ExtremaPC_Parabola::Domain ( ) const
inline

Returns the domain (only valid if IsBounded() is true).

◆ IsBounded()

bool ExtremaPC_Parabola::IsBounded ( ) const
inline

Returns true if domain is bounded.

◆ operator=() [1/2]

ExtremaPC_Parabola & ExtremaPC_Parabola::operator= ( const ExtremaPC_Parabola & )
delete

Copy assignment operator is deleted.

◆ operator=() [2/2]

ExtremaPC_Parabola & ExtremaPC_Parabola::operator= ( ExtremaPC_Parabola && )
default

Move assignment operator.

◆ Parabola()

const gp_Parab & ExtremaPC_Parabola::Parabola ( ) const
inline

Returns the parabola geometry.

◆ Perform()

const ExtremaPC::Result & ExtremaPC_Parabola::Perform ( const gp_Pnt & theP,
double theTol,
ExtremaPC::SearchMode theMode = ExtremaPC::SearchMode::MinMax ) const
inline

Compute extrema between point P and the parabola. Uses domain specified at construction time.

Parameters
thePquery point
theToltolerance for duplicate detection
theModesearch mode (MinMax, Min, or Max)
Returns
const reference to result containing extrema

◆ PerformWithEndpoints()

const ExtremaPC::Result & ExtremaPC_Parabola::PerformWithEndpoints ( const gp_Pnt & theP,
double theTol,
ExtremaPC::SearchMode theMode = ExtremaPC::SearchMode::MinMax ) const
inline

Compute extrema between point P and the parabola arc including endpoints. Uses domain specified at construction time.

Parameters
thePquery point
theToltolerance for duplicate detection
theModesearch mode (MinMax, Min, or Max)
Returns
const reference to result containing interior + endpoint extrema

◆ Value()

gp_Pnt ExtremaPC_Parabola::Value ( double theU) const
inline

Evaluates point on parabola at parameter using cached geometry.

Parameters
theUparameter
Returns
point on parabola

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