Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members   Examples  

gcd.h File Reference

Euclidian algorithm. More...

Go to the source code of this file.

Functions

template<class item_class> item_class gcd (const item_class &a, const item_class &b)
template<class T> T gcd_bezout (const T &a, const T &b, T &u, T &v)
template<class item_class> item_class gcd (const vector< item_class > &v)


Detailed Description

Euclidian algorithm.

This module consists of two functions which implements Euclidian algorithm for greatest common divisor producing.

Definition in file gcd.h.


Function Documentation

template<class item_class>
item_class gcd const vector< item_class > & v
 

Euclidian algorithm that produces the greatest common divisor of entries in v.

Definition at line 81 of file gcd.h.

Referenced by rational::operator *(), and rational::operator/().

template<class item_class>
item_class gcd const item_class & a,
const item_class & b
 

Euclidian algorithm produces the greatest common divisor of two integer u and v.

Definition at line 24 of file gcd.h.

template<class T>
T gcd_bezout const T & a,
const T & b,
T & u,
T & v
 

Euclidian algorithm produces the greatest common divisor of two integer u and v.

Definition at line 45 of file gcd.h.


Generated at Tue Jan 22 20:37:04 2002 for Arageli by doxygen1.2.9.1 written by Dimitri van Heesch, © 1997-2001