40 #ifndef GEOGRAM_POINTS_PRINCIPAL_AXES
41 #define GEOGRAM_POINTS_PRINCIPAL_AXES
46 #include <geogram/basic/logger.h>
92 return vec3(center_[0], center_[1], center_[2]);
112 return eigen_value_[i];
127 double eigen_value_[3] ;
131 double sum_weights_ ;
double eigen_value(index_t i) const
Gets one of the eigenvalues.
void begin()
Begins a principal axes estimation.
vec3 normal() const
Gets the estimated normal to the point cloud.
PrincipalAxes3d()
PrincipalAxes3d constructor.
void end()
Ends a principal axes estimation.
vec3 center() const
Gets the center.
const vec3 & axis(index_t i) const
Gets one of the axes.
void add_point(const vec3 &p, double weight=1.0)
Adds a point to the current principal axes estimation.
Common include file, providing basic definitions. Should be included before anything else by all head...
Geometric functions in 2d and 3d.
Some utilities for matrix manipulation.
Global Vorpaline namespace.
vecng< 3, Numeric::float64 > vec3
Represents points and vectors in 3d.
geo_index_t index_t
The type for storing and manipulating indices.
Types and functions for numbers manipulation.