Page 5-18
numbers (function ICHINREM). The input consists of two vectors [expression_1,
modulo_1] and [expression_2, modulo_2]. The output is a vector containing
[expression_3, modulo_3], where modulo_3 is related to the product
(modulo_1)
⋅
(modulo_2). Example: CHINREM([X+1, X^2-1],[X+1,X^2]) =
[X+1,-(X^4-X^2)]
Statement of the Chinese Remainder Theorem for integers
If m
1
, m
2
,…,m
r
are natural numbers every pair of which are relatively prime,
and a
1
, a
2
, …, a
r
are any integers, then there is an integer x that
simultaneously satisfies the congruences: x
≡
a
1
(mod m
1
), x
≡
a
2
(mod m
2
),
…, x
≡
a
r
(mod m
r
). Additionally, if x = a is any solution then all other solutions
are congruent to a modulo equal to the product m
1
⋅
m
2
⋅
… m
r
.
The EGCD function
EGCD stands for Extended Greatest Common Divisor. Given two polynomials,
A(X) and B(X), function EGCD produces the polynomials C(X), U(X), and V(X),
so that C(X) = U(X)*A(X) + V(X)*B(X). For example, for A(X) = X^2+1, B(X) =
X^2-1, EGCD(A(X),B(X)) = {2, 1, -1}. i.e., 2 = 1*( X^2+1’)-1*( X^2-1). Also,
EGCD(‘X^3-2*X+5’,’X’) = { 5,1,-(X^2-2)}, i.e., 5 = – (X^2-2)*X + 1*(X^3-
2*X+5).
The GCD function
The function GCD (Greatest Common Denominator) can be used to obtain the
greatest common denominator of two polynomials or of two lists of polynomials
of the same length. The two polynomials or lists of polynomials will be placed
in stack levels 2 and 1 before using GCD. The results will be a polynomial or a
list representing the greatest common denominator of the two polynomials or of
each list of polynomials. Examples, in RPN mode, follow (calculator set to Exact
mode):
‘X^3-1’`’X^2-1’`GCD Results in: ‘X-1’
{‘X^2+2*X+1’,’X^3+X^2’} `{'X^3+1','X^2+1'}ʳʳ`GCD results in {'X+1'
1}
The HERMITE function
The function HERMITE [HERMI] uses as argument an integer number, k, and
returns the Hermite polynomial of k-th degree. A Hermite polynomial, He
k
(x) is
defined as
,...2,1),()1()(,1
2/2/
0
22
=−==
−
ne
dx
d
exHeHe
x
n
n
xn
n