import("libm3")

template("gcd")
template("integerpower")
template("combinatoric")


Generic_module("IntegerPower")
IntegerPower("Integer32",            "Integer32Basic")
IntegerPower("Cardinal32",           "Cardinal32Basic")
IntegerPower("BigInteger",           "BigInteger")
IntegerPower("BigIntegerComplex",    "BigIntegerComplex")
IntegerPower("BigIntegerPolynomial", "BigIntegerPolynomial")
IntegerPower("BigIntegerMatrix",     "BigIntegerMatrix")
IntegerPower("LongReal",             "LongRealBasic")
IntegerPower("LongRealComplex",      "LongRealComplex")
IntegerPower("LongRealPolynomial",   "LongRealPolynomial")
IntegerPower("LongRealMatrix",       "LongRealMatrix")

Generic_module("GCD")
GCD("Cardinal32",                   "Cardinal32Basic")
GCD("Integer32",                    "Integer32Basic")
GCD("Integer32Complex",             "Integer32Complex")
GCD("BigInteger",                   "BigInteger")
GCD("BigIntegerComplex",            "BigIntegerComplex")
GCD("BigIntegerFractionPolynomial", "BigIntegerFractionPolynomial")
% GCD will not work with floating point numbers,
% because values that should be zero, aren't zero most often
%  GCD("LongRealPolynomial",           "LongRealPolynomial")

Generic_module("Combinatoric")
Combinatoric("Cardinal32",          "Cardinal32Basic")
Combinatoric("BigInteger",          "BigInteger")


Module("NumberTheory")
implementation("PrimeNumber")
