Solves the Diophantine equation $mx+by=1$ for $x$
and $y$. The function is named for equation 57 in Hardy and Wright.
Usage
congruence(a, l = 1)
Arguments
a
Two element vector with a=c(m,n)
l
Right hand side with default 1
Value
In the usual case of $(m,n)=1$, returns a square matrix
whose rows are a and c(x,y). This matrix is a unimodular
transformation that takes a pair of basic periods to another pair of
basic periods.
If $(m,n)\neq 1$ then more than one solution is
available (for example congruence(c(4,6),2)). In this case, extra rows
are added and the matrix is no longer square.