Eric J. Van der Velden on Mon, 07 May 2018 23:16:22 +0200


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: How to find teichmuller representation of 2 (for example)


Fantastic! Thanks!

On Mon, May 7, 2018 at 10:38 PM, Karim Belabas <Karim.Belabas@math.u-bordeaux.fr> wrote:
* Eric J. Van der Velden [2018-05-07 22:18]:
> In Z5 I found the teichmuller representatives
> 0
> 1
> i=2121...
> -i=3323...
> -1
>
> By 2121... I mean 2+1*5+2*5^2+1*5^3+...
>
> I can write
> 2 = i(-1)(-i)0... = i - 5 - i*5^2 + 0*5^3 + ...
>
> How can I find in gp this representation of 2 ?

  f(x, n, p = 5) =
  { my (v,w);
    v = vector(p, i, teichmuller(i-1 + O(p^n)));
    w = vector(n);
    for (i = 1, n, w[i] = x % p; x = (x -  v[w[i]+1]) / p);
    w;
  }

  ? f(2, 20) \\ 20 "digits"
  %1 = [2, 4, 3, 0, 4, 2, 4, 4, 1, 2, 2, 4, 0, 3, 4, 3, 3, 1, 2, 4]

Cheers,

    K.B.
--
Karim Belabas, IMB (UMR 5251)  Tel: (+33) (0)5 40 00 26 17
Universite de Bordeaux         Fax: (+33) (0)5 40 00 21 23
351, cours de la Liberation    http://www.math.u-bordeaux.fr/~kbelabas/
F-33405
Talence (France)       http://pari.math.u-bordeaux.fr/  [PARI/GP]
`