mirror of https://github.com/CGAL/cgal
better names, refined concepts for AK
This commit is contained in:
parent
3879478407
commit
0e5d766ca3
|
|
@ -1,19 +1,26 @@
|
||||||
\begin{ccRefConcept}{AlgebraicCurveKernel_2}
|
\begin{ccRefConcept}{AlgebraicKernelBase_2}
|
||||||
|
|
||||||
\ccDefinition
|
\ccDefinition
|
||||||
|
The \ccc{AlgebraicKernelBase_2} concept is meant to provide the curved
|
||||||
|
kernel with very fundamental algebraic functionalities on uni- and bivariate
|
||||||
The \ccc{AlgebraicCurveKernel_2} concept is meant to provide the curved
|
polynomials.
|
||||||
kernel with all the algebraic functionalities on bivariate polynomials
|
|
||||||
required for the manipulation of arcs of algebraic curves of general degree
|
|
||||||
$\R^2$ using an $y$-per-$x$-view on the curves.
|
|
||||||
|
|
||||||
\ccTypes
|
\ccTypes
|
||||||
|
|
||||||
A model of \ccc{AlgebraicCurveKernel_2} is supposed to provide
|
A model of \ccc{AlgebraicKernelBase_2} is supposed to provide
|
||||||
|
|
||||||
\ccNestedType{Coefficient}{A model of \ccc{IntegralDomain}. }
|
\ccNestedType{Coefficient}{A model of \ccc{IntegralDomain}. }
|
||||||
|
|
||||||
|
\ccNestedType{Polynomial_1}{A model of \ccc{Polynomial_1}, for
|
||||||
|
univariate polynomials when the \ccc{Coefficient} type is an
|
||||||
|
\ccc{IntegralDomain}. It must also be possible to perform \ccc{Canonicalize,
|
||||||
|
GcdUpToConstantFactor,
|
||||||
|
IntegralDivUpToConstantFactor,
|
||||||
|
MakeSquareFreeUpToConstantFactor, and
|
||||||
|
SquareFreeFactorizationUpToConstantFactor.
|
||||||
|
Also needed some PolynomialConstruction concept.}
|
||||||
|
}
|
||||||
|
|
||||||
\ccNestedType{Polynomial_2}{A model of \ccc{Polynomial_2}, for
|
\ccNestedType{Polynomial_2}{A model of \ccc{Polynomial_2}, for
|
||||||
bivariate polynomials on an \ccc{IntegralDomain} coefficient type.
|
bivariate polynomials on an \ccc{IntegralDomain} coefficient type.
|
||||||
it must also be possible to perform \ccc{Canonicalize,
|
it must also be possible to perform \ccc{Canonicalize,
|
||||||
|
|
@ -21,24 +28,17 @@ A model of \ccc{AlgebraicCurveKernel_2} is supposed to provide
|
||||||
IntegralDivUpToConstantFactor,
|
IntegralDivUpToConstantFactor,
|
||||||
MakeSquareFreeUpToConstantFactor, and
|
MakeSquareFreeUpToConstantFactor, and
|
||||||
SquareFreeFactorizationUpToConstantFactor} on this type - maybe using a
|
SquareFreeFactorizationUpToConstantFactor} on this type - maybe using a
|
||||||
traits class. Also needed some PolynomialConstruction concept
|
traits class. Also needed some PolynomialConstruction concept.
|
||||||
}
|
}
|
||||||
|
|
||||||
% TODO: Boundary: RealEmbeddable that is 'dense R'
|
\ccNestedType{Solution_1}{A model of
|
||||||
|
\ccc{AlgebraicKernelBase_2::Solution_1}, for real roots of univariate
|
||||||
|
polynomials of type \ccc{Polynomial_1}.}
|
||||||
|
|
||||||
\ccNestedType{Solution_2}{A model of
|
\ccNestedType{Solution_2}{A model of
|
||||||
\ccc{AlgebraicCurveKernel_2::Solution_2}, for solutions of systems
|
\ccc{AlgebraicKernelBase_2::Solution_2}, for solutions of systems
|
||||||
of two bivariate polynomials of type \ccc{Polynomial_2}.}
|
of two bivariate polynomials of type \ccc{Polynomial_2}.}
|
||||||
|
|
||||||
\ccNestedType{CurvePairAnalysis_2}{A model of
|
|
||||||
\ccc{AlgebraicCurveKernel_2::CurvePairAnalysis_2},
|
|
||||||
for analysing a pair of curves
|
|
||||||
defined as two analyses of type \ccc{CurveAnalysis_2}.}
|
|
||||||
|
|
||||||
\ccNestedType{CurveAnalysis_2}{A model of
|
|
||||||
\ccc{CurvePairAnalyis_2::CurveAnalysis_2}, for analysing single
|
|
||||||
curves defined as bivariate polynomials of type \ccc{Polynomial_2}.}
|
|
||||||
|
|
||||||
\ccNestedType{Compare_x_2}{A model of the concept
|
\ccNestedType{Compare_x_2}{A model of the concept
|
||||||
\ccc{AlgebraicKernel_d_2::CompareX_2}.}
|
\ccc{AlgebraicKernel_d_2::CompareX_2}.}
|
||||||
\ccGlue
|
\ccGlue
|
||||||
|
|
@ -49,4 +49,78 @@ curves defined as bivariate polynomials of type \ccc{Polynomial_2}.}
|
||||||
\ccc{AlgebraicKernel_d_2::CompareXY_2}.}
|
\ccc{AlgebraicKernel_d_2::CompareXY_2}.}
|
||||||
|
|
||||||
|
|
||||||
|
\end{ccRefConcept}
|
||||||
|
|
||||||
|
\begin{ccRefConcept}{AlgebraicKernelBasic_2}
|
||||||
|
\footnote{Adapted the concepts \ccc{AlgebraicKernel_d_1} and
|
||||||
|
\ccc{AlgebraicKernel_d_2} and re-assigned types/functors
|
||||||
|
to Base and Basic part.}
|
||||||
|
|
||||||
|
\ccDefinition
|
||||||
|
|
||||||
|
The \ccc{AlgebraicKernelBasic_2} concept is meant to provide the curved
|
||||||
|
kernel with all the algebraic functionalities on uni- and bivariate polynomials
|
||||||
|
required for the manipulation of arcs of algebraic curves of general degree
|
||||||
|
$d$ in $\R^2$.
|
||||||
|
|
||||||
|
\ccNestedType{Solve_1}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_1::Solve_1}.}
|
||||||
|
|
||||||
|
\ccNestedType{Sign_at_1}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_1::SignAt_1}.}
|
||||||
|
|
||||||
|
\ccNestedType{Derivative_1}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_1::Derivative}.}
|
||||||
|
|
||||||
|
\ccNestedType{Compare_1}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_1::Compare_1}.}
|
||||||
|
|
||||||
|
\textbf{Question: what is the righ interface with AK
|
||||||
|
for \ccc{compare_y_at_x_right}?}
|
||||||
|
|
||||||
|
\ccNestedType{Solve_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::Solve_2}.}
|
||||||
|
|
||||||
|
\ccNestedType{Sign_at_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::SignAt_2}.}
|
||||||
|
|
||||||
|
\ccNestedType{Derivative_x_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::DerivativeX_2}.}
|
||||||
|
|
||||||
|
\ccNestedType{Derivative_y_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::DerivativeY_2}.}
|
||||||
|
|
||||||
|
\ccNestedType{X_critical_points_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::XCriticalPoints_2}.}
|
||||||
|
\ccGlue
|
||||||
|
\ccNestedType{Y_critical_points_2}{A model of the concept
|
||||||
|
\ccc{AlgebraicKernelBasic_2::YCriticalPoints_2}.}
|
||||||
|
|
||||||
|
\end{ccRefConcept}
|
||||||
|
|
||||||
|
\begin{ccRefConcept}{AlgebraicKernelCCPA_2}
|
||||||
|
|
||||||
|
\ccDefinition
|
||||||
|
|
||||||
|
The \ccc{AlgebraicKernelCCPA_2} concept refines the \ccc{AlgebraicKernelBase_2}
|
||||||
|
concept with functionality on bivariate polynomials
|
||||||
|
required for the manipulation of arcs of algebraic curves of general degree
|
||||||
|
$\R^2$ using an $y$-per-$x$-view on the curves.
|
||||||
|
|
||||||
|
\ccRefines
|
||||||
|
\ccc{AlgebraicKernelBase_2}
|
||||||
|
|
||||||
|
\ccTypes
|
||||||
|
|
||||||
|
\ccNestedType{CurvePairAnalysis_2}{A model of
|
||||||
|
\ccc{AlgebraicKernelCCPA_2::CurvePairAnalysis_2},
|
||||||
|
for analysing a pair of curves
|
||||||
|
defined as two analyses of type \ccc{CurveAnalysis_2}.}
|
||||||
|
|
||||||
|
\ccNestedType{CurveAnalysis_2}{A model of
|
||||||
|
\ccc{CurvePairAnalyis_2::CurveAnalysis_2}, for analysing single
|
||||||
|
curves defined as bivariate polynomials of type \ccc{Polynomial_2}.}
|
||||||
|
|
||||||
|
{\small TODO: Boundary: RealEmbeddable that is 'dense R'??}
|
||||||
|
|
||||||
\end{ccRefConcept}
|
\end{ccRefConcept}
|
||||||
|
|
|
||||||
|
|
@ -6,11 +6,22 @@ The concept \ccc{Solution_1} is meant to store a coordinate ($x$, or $y$) of
|
||||||
a point on curve.
|
a point on curve.
|
||||||
|
|
||||||
\ccRefines
|
\ccRefines
|
||||||
\ccc{RealEmbeddable}
|
\ccc{DefaultConstructible, Assignable, LessThanComparable, CompactifiedNumber}
|
||||||
|
|
||||||
Remark: Michael Hemmer proposed to extend the concept \ccc{RealEmbeddable}
|
The concept \ccc{CompactifiedNumber} has not been introduced so far. Michael
|
||||||
with the notion of compactification (adding/dealing with $\pm\infty$). A
|
Hemmer will introduce it as basic tool as soon as possible. For
|
||||||
valid model has to implement handling of infinity.
|
now we assume that a number of this type is either finite, and if not,
|
||||||
|
we can ask, wether it represents $\pm\infty$.
|
||||||
|
|
||||||
|
There are reasons why we introduce \ccc{Solution_1} over
|
||||||
|
\ccc{AlgebraicReal_1}\footnote{Not yet introduced so far}:
|
||||||
|
\begin{itemize}
|
||||||
|
\item It may suffices to use a simpler number type ($Q[\sqrt{2}]$).
|
||||||
|
\item Keep concept minimal, \ccc{AlgebraicReal_1} will quite certainly
|
||||||
|
contain more than needed here.
|
||||||
|
\item \ccc{AlgebraicReal_1} won't be a refinement of \ccc{CompaticiedNumber}.
|
||||||
|
\ccc{double} is.
|
||||||
|
\end{itemize}
|
||||||
|
|
||||||
\begin{ccAdvanced}
|
\begin{ccAdvanced}
|
||||||
|
|
||||||
|
|
@ -38,7 +49,7 @@ following methods:
|
||||||
\ccPrecond{sol1 != s}
|
\ccPrecond{sol1 != s}
|
||||||
}
|
}
|
||||||
|
|
||||||
\ccMethod{std::pair<Boundary,Boundary> s1.approximate(int prec);}{
|
\ccMethod{std::pair<Boundary,Boundary> approximate(int prec);}{
|
||||||
Refines the representation to the given precision (binary digits
|
Refines the representation to the given precision (binary digits
|
||||||
after point). Internally the precision can already be higher.
|
after point). Internally the precision can already be higher.
|
||||||
}
|
}
|
||||||
|
|
@ -48,4 +59,11 @@ Maybe, we can have it orthogonal to the normal concept.
|
||||||
|
|
||||||
\end{ccAdvanced}
|
\end{ccAdvanced}
|
||||||
|
|
||||||
|
Remark: Note that this concept only deals with the interface to upper
|
||||||
|
layers. There might be additional requirements for number types to
|
||||||
|
implement a model of this concept.
|
||||||
|
|
||||||
|
\ccHasModels
|
||||||
|
\ccc{double, NiX::Compactified< NiX::Algebraic_real >}
|
||||||
|
|
||||||
\end{ccRefConcept}
|
\end{ccRefConcept}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,18 @@
|
||||||
The concept \ccc{Solution_2} is meant to store both coordinates of a point
|
The concept \ccc{Solution_2} is meant to store both coordinates of a point
|
||||||
on a curve.
|
on a curve.
|
||||||
|
|
||||||
|
There are reasons why we introduce \ccc{Solution_2} over
|
||||||
|
\ccc{AlgebraicReal_2}:
|
||||||
|
\begin{itemize}
|
||||||
|
\item \ccc{AlgebraicReal_2} seems to be pair of \ccc{AlgebraicReal_1}, while
|
||||||
|
\ccc{Solution_2} has members to access \ccc{Solution_1} for $x$ and $y$.
|
||||||
|
With the name we state better to be more generic.
|
||||||
|
\item Keep concept minimal, in contrast to \ccc{AlgebraicReal_2} that
|
||||||
|
seems to be quite powerful.
|
||||||
|
\item \ccc{Solution_2} is ``compactified'' (with the help of
|
||||||
|
\ccc{Solution_1}) in contrast to \ccc{AlgebraicReal_2}.
|
||||||
|
\end{itemize}
|
||||||
|
|
||||||
\ccCreationVariable{sol2}
|
\ccCreationVariable{sol2}
|
||||||
|
|
||||||
\ccAccessFunctions
|
\ccAccessFunctions
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue