Function

CGAL::make_root_of_2<RT>

Definition

The function make_root_of_2<RT> constructs an algebraic number of degree 2 over a ring number type.

#include <CGAL/Root_of_traits.h>

template <typename RT>
Root_of_traits<RT>::Root_of_2 make_root_of_2 ( RT a, RT b, RT c, bool s)
Returns the smallest real root of the polynomial aX2+bX+c if s is true, and the largest root is s is false.
Precondition: RT is an IntegralDomainWithoutDivision.
Precondition: The polynomial has at least one real root.

template <typename RT>
Root_of_traits<RT>::Root_of_2 make_root_of_2 ( RT alpha, RT beta, RT gamma)
Constructs the number α+ β√γ.
Precondition: RT is an IntegralDomainWithoutDivision.
Precondition: γ 0

See Also

RootOf_2
CGAL::Root_of_traits<RT>
CGAL::make_sqrt<RT>
CGAL::compute_roots_of_2<RT,OutputIterator>
CGAL::Sqrt_extension<NT,ROOT>