8#include "../../defines.h"
9#include "../concepts.h"
11#include "../primitive/algebraicSphere.h"
12#include "../tools/mean.h"
14#define ORIENTED_SPHERE_FIT_REQUIREMENTS ProvidesAlgebraicSphere<T>&& ProvidesMeanPosition<T>&& ProvidesMeanNormal<T>
15#define ORIENTED_SPHERE_DER_REQUIREMENTS \
16 ProvidesBasketDiffUnitBase<T>&& ProvidesAlgebraicSphere<T>&& ProvidesMeanPositionDerivative<T>
30 template <
class DataPo
int,
class _NFilter,
typename T>
31 requires ORIENTED_SPHERE_FIT_REQUIREMENTS
34 PONCA_FITTING_DECLARE_DEFAULT_TYPES
45 PONCA_FITTING_DECLARE_INIT_ADD_FINALIZE
46 PONCA_FITTING_IS_SIGNED(
true)
51 template <
class DataPo
int,
class _NFilter,
typename T>
60 template <
class DataPo
int,
class _NFilter,
int DiffType,
typename T>
61 requires ORIENTED_SPHERE_DER_REQUIREMENTS
64 PONCA_FITTING_DECLARE_DEFAULT_TYPES
65 PONCA_FITTING_DECLARE_DEFAULT_DER_TYPES
88 PONCA_FITTING_DECLARE_INIT_ADDDER_FINALIZE
113 PONCA_MULTIARCH_STD_MATH(
sqrt);
120 PONCA_MULTIARCH_STD_MATH(
sqrt);
133 template <
class DataPo
int,
class _NFilter,
int DiffType,
typename T>
137#include "orientedSphereFit.hpp"
Aggregator class used to declare specialized structures using CRTP.
[OrientedSphereFit Definition]
ScalarArray m_dSumDotPP
Sum of the squared relative positions with weight derivatives.
OrientedSphereDerImpl< DataPoint, _NFilter, DiffType, T > & implicitPrimitiveDer()
Explicit conversion to OrientedSphereDerImpl , to access methods potentially hidden by heritage.
ScalarArray dPotential() const
Returns the derivatives of the scalar field at the evaluation point.
ScalarArray m_dUc
Derivatives of the hyper-sphere constant term
ScalarArray m_dSumDotPN
Sum of the dot product between relative positions and normals with weight derivatives.
VectorArray m_dSumN
Sum of the normal vectors with weight derivatives.
ScalarArray m_dNume
Derivatives of the numerator of the quadratic parameter
VectorArray m_dUl
Derivatives of the hyper-sphere linear term
Scalar dprattNorm2(unsigned int _d) const
compute the square of the Pratt norm derivative for dimension _d
ScalarArray m_dUq
Derivatives of the hyper-sphere quadratic term.
ScalarArray dprattNorm2() const
compute the square of the Pratt norm derivative
ScalarArray dprattNorm() const
compute the Pratt norm derivative
typename Base::ScalarArray ScalarArray
Alias to scalar derivatives array.
VectorArray dNormal() const
Returns the derivatives of the primitive normal.
typename DataPoint::Scalar Scalar
Alias to scalar type.
bool applyPrattNorm()
Normalize the scalar field by the Pratt norm.
OrientedSphereDerImpl< DataPoint, _NFilter, DiffType, T > & algebraicSphereDer()
Explicit conversion to OrientedSphereDerImpl , to access methods potentially hidden by heritage.
OrientedSphereDerImpl< DataPoint, _NFilter, DiffType, T > & orientedSphereDer()
Explicit conversion to OrientedSphereDerImpl , to access methods potentially hidden by heritage.
ScalarArray m_dDeno
Derivatives of the denominator of the quadratic parameter.
Scalar dprattNorm(unsigned int _d) const
compute the Pratt norm derivative for the dimension _d
typename Base::VectorArray VectorArray
Alias to vector derivatives array.
Algebraic Sphere fitting procedure on oriented point sets.
Scalar m_sumDotPP
Sum of the squared relative positions.
OrientedSphereFitImpl< DataPoint, _NFilter, T > & orientedSphereFit()
Explicit conversion to OrientedSphereFitImpl , to access methods potentially hidden by heritage.
typename DataPoint::Scalar Scalar
Alias to scalar type.
Scalar m_sumDotPN
Sum of the dot product between relative positions and normals.
Scalar m_nume
Numerator of the quadratic parameter (excluding the 0.5 coefficient)
Scalar m_deno
Denominator of the quadratic parameter (excluding the 0.5 coefficient)
This Source Code Form is subject to the terms of the Mozilla Public License, v.