Cantor Expansion Addition algorithm?

raross
Messages
12
Reaction score
0
Could someone help me and write an algorithm to add 2 Cantor expansions. The algorithm to get a decimal number to cantor expansion is:

procedure decimal-to-cantor(x: positive integer)
n := 1
y := x fy is a temporary variable used so that
this procedure won't destroy the original value of x.g
while y 6= 0
begin
an := y mod (n+1)
y := (y-an )/(n+1)
n := n + 1
end
f The expansion for x will be an n! + an−1 (n-1)! + : : : + a22! + a1 . g

Now i just need to figure out how to add 2 cantor expansion numbers together to get one. Someone help please!
 
Physics news on Phys.org
How come no one can help me ? =/
 
Well, I can't because I've never heard of a Cantor expansion before (at least not by that name).
 
Prove $$\int\limits_0^{\sqrt2/4}\frac{1}{\sqrt{x-x^2}}\arcsin\sqrt{\frac{(x-1)\left(x-1+x\sqrt{9-16x}\right)}{1-2x}} \, \mathrm dx = \frac{\pi^2}{8}.$$ Let $$I = \int\limits_0^{\sqrt 2 / 4}\frac{1}{\sqrt{x-x^2}}\arcsin\sqrt{\frac{(x-1)\left(x-1+x\sqrt{9-16x}\right)}{1-2x}} \, \mathrm dx. \tag{1}$$ The representation integral of ##\arcsin## is $$\arcsin u = \int\limits_{0}^{1} \frac{\mathrm dt}{\sqrt{1-t^2}}, \qquad 0 \leqslant u \leqslant 1.$$ Plugging identity above into ##(1)## with ##u...
Back
Top