Return to standard_integer_norms.ads CVS log | Up to [local] / OpenXM_contrib / PHC / Ada / Math_Lib / Matrices |
File: [local] / OpenXM_contrib / PHC / Ada / Math_Lib / Matrices / standard_integer_norms.ads (download)
Revision 1.1.1.1 (vendor branch), Sun Oct 29 17:45:24 2000 UTC (23 years, 8 months ago) by maekawa
Import the second public release of PHCpack. OKed by Jan Verschelde. |
with Standard_Integer_Vectors; use Standard_Integer_Vectors; package Standard_Integer_Norms is -- DESCRIPTION : -- This package defines the norm of an integer vector as the gcd of -- all its entries. An integer vector is normalized if its elements -- are relative prime with respect to each other. function gcd ( v : Vector ) return integer; -- DESCRIPTION : -- Returns the positive gcd(v(v'first),..,v(v'last)). procedure Normalize ( v : in out Vector ); -- DESCRIPTION : -- All elements in the vector are divided by gcd(v). end Standard_Integer_Norms;