ln3 Method - Divide

Description
Divide one large number by another, returning both the quotient and the remainder.
Signature
void Divide( const ln &D, ln *Q, ln *R ) const
void Divide( long d, ln *Q, long *r ) const
void Divide( unsigned long d, ln *Q, unsigned long *r ) const
Parameters
Name Type Description
D ln Large number divisor.
d (unsigned) long Scalar divisor.
Q ln * Pointer to the large number variable that will contain the quotient.
R ln * Pointer to the large number variable that will contain the remainder.
r (unsigned) long * Pointer to the long integer variable that will contain the remainder.
Returns
( none )
Example
This example shows the large number case.  The scalar cases are similar.
ln Num = "98723498723948798279834";
ln Den = "23492039842098094823";
ln Q, R;
Num.Divide( Den, &Q, &R );
Algorithm
The algorithm is essentially the algorithm from [Knuth2].  The paper by [Hansen] help immensely in its implementation.
References
[Knuth2]
[Hansen]