Function

CGAL::is_square

Definition

An ring element x is said to be a square iff there exists a ring element y such that x= y*y. In case the ring is a UniqueFactorizationDomain, y is uniquely defined up to multiplication by units.

The function is_square is available if Algebraic_structure_traits::Is_square is not the CGAL::Null_functor.

#include <CGAL/number_utils.h>

template <class NT>
result_type is_square ( NT x) The result_type is convertible to bool.

template <class NT>
result_type is_square ( NT x, NT& y) The result_type is convertible to bool.

See Also

UniqueFactorizationDomain
AlgebraicStructureTraits::IsSquare