Jeroen Demeyer on Thu, 08 Aug 2013 10:23:48 +0200

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

Re: Computing generator of ideal I^n

On 08/07/2013 09:27 PM, Karim Belabas wrote:
Sure! Unfortunately, it's awkward to do this in GP : the (libpari)
function isprincipalfact() is used internally for this, see Libpari's
manual, section "Computing in the class group"

   (21:19) gp > ??"Computing in the class group"@

    GEN isprincipalfact(GEN bnf,  GEN C,  GEN L,  GEN f, long flag) is about the
same  as  bnfisprincipal0  applied  to  C prod L[i]^{f[i]},  where the L[i] are
ideals, the f[i] integers and C is either an ideal or NULL (omitted). Make sure
to include nf_GENMAT in flag!

   ? install(isprincipalfact, GDGGGL)
   ? K = bnfinit(y^2+23);
   ? isprincipalfact(K,, K.gen, K.cyc,  4/*nf_GENMAT*/)
   %2 = [[0]~, [[1, 1/2]~, 1; 2, 1]]

The result is [e, t] as in bnfisprincipal(), with the important difference that
't' is given in *factored* form (which is undocumented in GP, but supported by
most libpari number field functions).

It suffices to do this for the ideals generating the class group,
but that's already slow enough for the field that I'm using.

In fact, this is often already part of the bnfinit structure (dynamically
added as soon as a function requires it). It can be forced:

   ? install(check_and_build_cycgen, G)
   ? check_and_build_cycgen(K)
   %3 = [Mat([[2, 1]~, 1])]

(this is now part of K, all further calls will be instantaneous)

This is a vector of generators for the g_i^d_i, where the g_i are the class
group generators, and the d_i are their orders.

Thanks for this very interesting post!