OCC Main Page | ModelingData | Toolkits | Packages | Class Hierarchy | Data Structures | File List | Data Fields | Globals

ModelingData
TKG2d
GProp


GProp_PGProps Class Reference

A framework for computing the global properties of a
set of points.
A point mass is attached to each point. The global
mass of the system is the sum of each individual
mass. By default, the point mass is equal to 1 and the
mass of a system composed of N points is equal to N.
Warning
A framework of this sort provides functions to handle
sets of points easily. But, like any GProp_GProps
object, by using the Add function, it can theoretically
bring together the computed global properties and
those of a system more complex than a set of points .
The mass of each point and the density of each
component of the composed system must be
coherent. Note that this coherence cannot be checked.
Nonetheless, you are advised to restrict your use of a
GProp_PGProps object to a set of points and to
create a GProp_GProps object in order to bring
together global properties of different systems.
.

#include <GProp_PGProps.hxx>

Inheritance diagram for GProp_PGProps:

Inheritance graph
[legend]

Public Member Functions

void * operator new (size_t, void *anAddress)
void * operator new (size_t size)
void operator delete (void *anAddress)
Standard_EXPORT GProp_PGProps ()
 Initializes a framework to compute global properties
on a set of points.
The point relative to which the inertia of the system is
computed will be the origin (0, 0, 0) of the
absolute Cartesian coordinate system.
At initialization, the framework is empty, i.e. it retains
no dimensional information such as mass and inertia.
It is, however, now able to keep global properties of a
set of points while new points are added using the
AddPoint function.
The set of points whose global properties are brought
together by this framework will then be referred to as
the current system. The current system is, however,
not kept by this framework, which only keeps that
system's global properties. Note that the current
system may be more complex than a set of points.
.
Standard_EXPORT void AddPoint (const gp_Pnt &P)
 Brings together the global properties already
retained by this framework with those induced by
the point Pnt. Pnt may be the first point of the current system.
A point mass is attached to the point Pnt, it is either
equal to 1. or to Density.
.
Standard_EXPORT void AddPoint (const gp_Pnt &P, const Standard_Real Density)
 Adds a new point P with its density in the system of points
Exceptions
Standard_DomainError if the mass value Density
is less than gp::Resolution().
.
Standard_EXPORT GProp_PGProps (const TColgp_Array1OfPnt &Pnts)
 computes the global properties of the system of points Pnts.
The density of the points are defaulted to all being 1

Standard_EXPORT GProp_PGProps (const TColgp_Array2OfPnt &Pnts)
 computes the global properties of the system of points Pnts.
The density of the points are defaulted to all being 1

Standard_EXPORT GProp_PGProps (const TColgp_Array1OfPnt &Pnts, const TColStd_Array1OfReal &Density)
 computes the global properties of the system of points Pnts.
A density is associated with each point.
raises if a density is lower or equal to Resolution from package
gp.
raises if the length of Pnts and the length of Density
is not the same.

Standard_EXPORT GProp_PGProps (const TColgp_Array2OfPnt &Pnts, const TColStd_Array2OfReal &Density)
 computes the global properties of the system of points Pnts.
A density is associated with each point.
Raised if a density is lower or equal to Resolution from package
gp.
Raised if the length of Pnts and the length of Density
is not the same.


Static Public Member Functions

static Standard_EXPORT gp_Pnt Barycentre (const TColgp_Array1OfPnt &Pnts)
 Computes the barycentre of a set of points. The density of the
points is defaulted to 1.
.
static Standard_EXPORT gp_Pnt Barycentre (const TColgp_Array2OfPnt &Pnts)
 Computes the barycentre of a set of points. The density of the
points is defaulted to 1.
.
static Standard_EXPORT void Barycentre (const TColgp_Array1OfPnt &Pnts, const TColStd_Array1OfReal &Density, Standard_Real &Mass, gp_Pnt &G)
 Computes the barycentre of a set of points. A density is associated
with each point.
raises if a density is lower or equal to Resolution from package
gp.
Raised if the length of Pnts and the length of Density
is not the same.
.
static Standard_EXPORT void Barycentre (const TColgp_Array2OfPnt &Pnts, const TColStd_Array2OfReal &Density, Standard_Real &Mass, gp_Pnt &G)
 Computes the barycentre of a set of points. A density is associated
with each point.
Raised if a density is lower or equal to Resolution from package
gp.
Raised if the length of Pnts and the length of Density
is not the same.
.

Constructor & Destructor Documentation

Standard_EXPORT GProp_PGProps::GProp_PGProps  ) 
 

Standard_EXPORT GProp_PGProps::GProp_PGProps const TColgp_Array1OfPnt &  Pnts  ) 
 

Standard_EXPORT GProp_PGProps::GProp_PGProps const TColgp_Array2OfPnt &  Pnts  ) 
 

Standard_EXPORT GProp_PGProps::GProp_PGProps const TColgp_Array1OfPnt &  Pnts,
const TColStd_Array1OfReal &  Density
 

Standard_EXPORT GProp_PGProps::GProp_PGProps const TColgp_Array2OfPnt &  Pnts,
const TColStd_Array2OfReal &  Density
 


Member Function Documentation

Standard_EXPORT void GProp_PGProps::AddPoint const gp_Pnt &  P,
const Standard_Real  Density
 

Standard_EXPORT void GProp_PGProps::AddPoint const gp_Pnt &  P  ) 
 

static Standard_EXPORT void GProp_PGProps::Barycentre const TColgp_Array2OfPnt &  Pnts,
const TColStd_Array2OfReal &  Density,
Standard_Real &  Mass,
gp_Pnt &  G
[static]
 

static Standard_EXPORT void GProp_PGProps::Barycentre const TColgp_Array1OfPnt &  Pnts,
const TColStd_Array1OfReal &  Density,
Standard_Real &  Mass,
gp_Pnt &  G
[static]
 

static Standard_EXPORT gp_Pnt GProp_PGProps::Barycentre const TColgp_Array2OfPnt &  Pnts  )  [static]
 

static Standard_EXPORT gp_Pnt GProp_PGProps::Barycentre const TColgp_Array1OfPnt &  Pnts  )  [static]
 

void GProp_PGProps::operator delete void *  anAddress  )  [inline]
 

Reimplemented from GProp_GProps.

void* GProp_PGProps::operator new size_t  size  )  [inline]
 

Reimplemented from GProp_GProps.

void* GProp_PGProps::operator new size_t  ,
void *  anAddress
[inline]
 

Reimplemented from GProp_GProps.


The documentation for this class was generated from the following file:
Generated on Mon Aug 25 13:23:02 2008 for OpenCASCADE by  doxygen 1.4.1