\( \newcommand{\E}{\mathrm{E}} \) \( \newcommand{\A}{\mathrm{A}} \) \( \newcommand{\R}{\mathrm{R}} \) \( \newcommand{\N}{\mathrm{N}} \) \( \newcommand{\Q}{\mathrm{Q}} \) \( \newcommand{\Z}{\mathrm{Z}} \) \( \def\ccSum #1#2#3{ \sum_{#1}^{#2}{#3} } \def\ccProd #1#2#3{ \sum_{#1}^{#2}{#3} }\)
CGAL 5.0 - Algebraic Foundations
AlgebraicStructureTraits_::Divides Concept Reference

Definition

AdaptableBinaryFunction, returns true if the first argument divides the second argument.

Integral division (a.k.a. exact division or division without remainder) maps ring elements \( (n,d)\) to ring element \( c\) such that \( n = dc\) if such a \( c\) exists. In this case it is said that \( d\) divides \( n\).

This functor is required to provide two operators. The first operator takes two arguments and returns true if the first argument divides the second argument. The second operator returns \( c\) via the additional third argument.

Refines:
AdaptableBinaryFunction
See also
AlgebraicStructureTraits
AlgebraicStructureTraits_::IntegralDivision

Types

typedef unspecified_type result_type
 Is AlgebraicStructureTraits::Boolean.
 
typedef unspecified_type first_argument
 Is AlgebraicStructureTraits::Type.
 
typedef unspecified_type second_argument
 Is AlgebraicStructureTraits::Type.
 

Operations

result_type operator() (first_argument_type d, second_argument_type n)
 Computes whether \( d\) divides \( n\).
 
result_type operator() (first_argument_type d, second_argument_type n, AlgebraicStructureTraits::Type &c)
 Computes whether \( d\) divides \( n\). More...
 

Member Function Documentation

◆ operator()()

result_type AlgebraicStructureTraits_::Divides::operator() ( first_argument_type  d,
second_argument_type  n,
AlgebraicStructureTraits::Type c 
)

Computes whether \( d\) divides \( n\).

Moreover it computes \( c\) if \( d\) divides \( n\), otherwise the value of \( c\) is undefined.