ASKSAGE: Sage Q&A Forum - Latest question feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Sat, 08 Jul 2017 12:52:42 -0500How to compute a cyclic subgroup of a class group?https://ask.sagemath.org/question/38198/how-to-compute-a-cyclic-subgroup-of-a-class-group/ Hello, I am quite new to computing in Sage and I am stuck at this point. Please help me out. I am going to use algebraic number theory notation without explaining them in detail. All computations are in quadratic fields.
What I have :
- $\Delta_p=p^2\Delta_K$ where $p$ is a prime, $\Delta_K=-pq$ and $\Delta_K\equiv 1$ mod $4$
- I computed the class group, $C(\Delta_p)$ in Sage
What I want :
- Set $f=[(p^2,p)]$ in $C(\Delta_p)$ where $(p^2,p)$ is the standard representation of an ideal of norm $p^2$
- Set $F=\langle f \rangle$
My question is :
- How to get that cyclic subgroup $F$?
I have been looking at AbelianGroup and ClassGroup in Sage but I am not quite understanding how to use these to actually get what I want.
Any help in this matter would be greatly appreciated.jakkeonSat, 08 Jul 2017 12:52:42 -0500https://ask.sagemath.org/question/38198/Fundamental Discriminanthttps://ask.sagemath.org/question/32945/fundamental-discriminant/ How can I print a list of around 10000 fundamental discriminant of quadratic number field in sage?LernerFri, 01 Apr 2016 11:43:37 -0500https://ask.sagemath.org/question/32945/Does QuadraticField use any special algorithms for computing the class group of quadratic imaginary number fields?https://ask.sagemath.org/question/26922/does-quadraticfield-use-any-special-algorithms-for-computing-the-class-group-of-quadratic-imaginary-number-fields/ I need to compute the class group of a quadratic imaginary number field that has a fairly large discriminant (over 96 bits.) I was wondering what, if any, algorithms the QuadraticField class uses for computing the class group.
Dan ShumowFri, 22 May 2015 15:23:45 -0500https://ask.sagemath.org/question/26922/how to get rank of elliptic curve of QuadraticFieldhttps://ask.sagemath.org/question/24664/how-to-get-rank-of-elliptic-curve-of-quadraticfield/I try two examples,even elliptic curve of Q cannot run:
http://cjsh716.blog.163.com/blog/static/213847199201492365454875/
E = EllipticCurve([0,0,0,0,2332])
show(E)
K1.<a> = QuadraticField(-3)
E1 = EllipticCurve(K1,[0,0,0,0,2332]);show(E1);
E.rank()
E1.rank()
E = EllipticCurve([0,0,0,-15,22])
show(E)
K1.<a> = QuadraticField(3)
E1 = EllipticCurve(K1,[0,0,0,-15,22]);show(E1)
E.torsion_points()
E1.torsion_points()
E.rank()
E1.rank()
TypeError: Unable to start pari because the command 'gp --emacs --quiet
--stacksize 10000000' failed.cjshTue, 28 Oct 2014 05:21:49 -0500https://ask.sagemath.org/question/24664/convert expression to QuadraticFieldhttps://ask.sagemath.org/question/10126/convert-expression-to-quadraticfield/I tried (in the Sage shell)
K = QuadraticField(-3)
a = K(sqrt(-3))
But that fails with a TypeError exception. What is the problem?
I know that I can get the generator by `K.gen()` but I want to be able to convert expressions to `K`.Albert ZeyerThu, 16 May 2013 04:52:39 -0500https://ask.sagemath.org/question/10126/Using "j" for Imaginary Unit?https://ask.sagemath.org/question/10039/using-j-for-imaginary-unit/This is probably trivial, but it's a minor annoyance that I'd like to fix.
Is there a way to define "j" to be the imaginary unit so that it not only represents "i" (in all expressions,etc.) but also appears in output as "j"?
sage: var('j,w,t')
(j, w, t)
sage: j=i
sage: j
I
sage: exp(j*w*t)
e^(I*t*w)
sage:
I'd like "j" to have the value of "i" but still appear as "j" in all output (LaTeX too!).
rickhg12hsThu, 18 Apr 2013 19:17:35 -0500https://ask.sagemath.org/question/10039/Quadratic number fieldshttps://ask.sagemath.org/question/10015/quadratic-number-fields/Hello!
I try to implement an inclusion test, of which I thought it must be quite simple, but until now I cannot figure out how to do it properly.
Problem: Given any element x, test if x is included in some quadratic number field and return true/false.
I tried the following:
x = 2 + sqrt(5)
K = QuadraticField(5)
print(x in K)
Here, the answer is 'no' or 'false' which is obviously wrong, so I assume I'm doing something completely wrong. What do I have to change?pinwheelFri, 12 Apr 2013 05:32:51 -0500https://ask.sagemath.org/question/10015/