stallation/conda.html
but it fails with the error message below (another path problem?). The
config
log file is attached.
Any suggestions would be appreciated.
--David Kohel
Checking whether SageMath should install SPKG gmp...
checking gmp.h usability... yes
checking gmp.h presence... no
configur
Hi,
To extend beyond a pre-computed database, I suggest linking the cm library
of Andreas Enge:
http://www.multiprecision.org/index.php?prog=cm
Pari has implementation of the weber function, but I think this (cm) should
be
the reference implementation, in the framework of standard mpc/mpfr
lib
Hi All,
I think it would be a good idea to have a subcategory of associative
algebras
(and inheritance of classes from an associative class). Morphisms need to
know to check associativity.
On the other hand, I was convinced years ago (by an argument of Bergman
at Berkeley) that algebras shou
On Friday, April 4, 2014 12:36:02 PM UTC+2, Volker Braun wrote:
>
> On Friday, April 4, 2014 11:19:11 AM UTC+1, Martin Albrecht wrote:
>>
>> existing one. However, in my case it would seem natural to improve the
>> basis
>> during the lifetime of an object.
>
>
> IMHO that is always going to ca
Hi Martin,
> I asked about it because it seems no one seems to have touched those data
> structures in years and because I failed to interact with it the way I
> wanted.
> In my world I think of a lattice as given by a basis and my bases are over
> the
> integers. I failed to construct tha
Dear all,
First of all, in the context of modules there should be no confusion about
the terminology "lattice" (as opposed to a lattice poset in combinatorics).
There is little doubt that modules with bilinear pairings are ubiquitous in
mathematics, but precisely that poses problems with differin
Hi,
I also strongly support both left and right actions, with the syntax
Left action:
s1(s2(x)) == (s1*s2)(x)
Right action:
(x^s1)^s2 == x^(s1*s2)
Currently the left (functional) notation is implemented in Sage with
the right order of application: s1(s2(x)) == (s2*s1)(x) is True.
This need
In a ring of characteristic 0, it seems that 0^0 (= 1) is well-defined.
In my view this is correct. It makes it much simpler to define the
matrix (e.g. FF a finite field):
G = matrix([ [ a^i for a in FF ] for i in range(k) ])
However, in finite fields or any of the the following rings, 0^0
giv
This would be interesting also to have an iterator for [all] elements of
unbounded height,
in number rings and fields.
See my post regarding the broken iterator on ZZ^n (and the independently
broken iterator
on isomorphic free abelian groups).
--David
--
To post to this group, send an email
1. For free abelian groups, the iterator doesn't enumerate any elements.
sage: A = AbelianGroup(3)
sage: A
Multiplicative Abelian Group isomorphic to Z x Z x Z
sage: for a in A:
: print a
:
The bug is in A.__iter__:
invs = self.invariants()
for t in mrange(invs):
Hi,
Let me just comment on two related issues:
1. Rational maps are indeed interesting in geometry and the question
of whether
a given rational map is (i.e. extends to) a morphism is a hard
question. In some
situations one might want to consider two categories. For instance,
do you assert
that
[X ] Make it standard at some point in the "near" future.
Argument: Sage includes many interfaces to standard software.
This includes software that the majority users will never use in
their lifetimes, e.g. the big M's (unless at a mathematics
department or institute where there exists a license)
Hi,
Here's one:
sage: K. = NumberField(x-2/3)
sage: K.is_prime_field()
False
The code is just a bit too naive:
Source:
def is_prime_field(self):
r"""
Return True if this ring is one of the prime fields `\QQ` or `
\GF{p}`.
...
"""
return False
i.e. i
Hi Alex,
This is a historical legacy of a heavy-handed attempt by William and
me
to implement schemes "from the book" (aka Hartshorne):
sage: A = AffineSpace(2, ZZ)
sage: p = A(0, 0)
sage: p.parent().category().element_class
sage: type(p)
It is mathematically correct to say that a point is a s
Hi,
1. (On Sage syntax):
For the record, there are some reasons why ZZ in Fields doesn't
(and perhaps shouldn't) make sense: Fields is a function not the
category it returns:
sage: Fields
sage: Fields()
Category of fields
I think a student learning Sage should have a first session in which
the
> On Tue, May 10, 2011 at 10:37 PM, Mike Hansen wrote:
> > On Tue, May 10, 2011 at 6:52 PM, Rob Beezer wrote:
> >> OK, thanks for the explanation, Tom. p.exponents() was the missing
> >> piece I did not have.
>
> > It would probably make sense to have p.monomials() method to be
> > consistent wi
Hi,
> > 1. It seems to me that kohel.py is broken and has not been used in the
> > past 5 years or so.
>
> Then I suppose we should remove it, unless David Kohel has objections.
Go ahead and remove it.
Cheers,
David
--
To post to this group, send an email to sage-devel@g
Hi,
Backwards compatibility or not, I consider this either a bad design
or a bug:
sage: M = Matrix([[1,-1],[1,0]])
sage: f = M.minimal_polynomial()
sage: f.roots()
[]
sage: M.eigenvalues()
[0.5? - 0.866025403784439?*I, 0.5? +
0.866025403784439?*I]
First of all, wh
Hi,
I solved this problem by changing the Magma script to not search
in the DYLD_LIBRARY_PATH (in $ROOT/magma):
#DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$ROOT # original line
DYLD_LIBRARY_PATH=$ROOT # hard code to use libgmp.3.dylib in $ROOT
Similarly, if you want to use another libgmp3 (ve
Hi Nicolas,
The list sage-nt was set up to have a lower volume and lower noise
forum
for sage-devel issues with mathematical (number theoretic) interest.
I also don't track sage-combinat for similar reasons as John, and
miss
most of what passes on sage-devel due to the high volume. Maybe
there
Rather I would say that "sparse" should be the default:
P. = InfinitePolynomialRing(QQ, implementation="sparse")
Moreover, this syntax (and for gens, etc.) is inconsistent
with PolynomialRing. The syntax:
PolynomialRing(ring, integer, sparse=True)
would be a more coherent, where integer=Set(ZZ
Hi,
I just verified that my home Mac desktop is 10.6.1 (and current for
all Mac updates). I need to kill all of my jobs to update my office
machine, so I deferred this step at work. However this is not the
source of the problem.
Instead it seems that the problem is due to running MacOSX in
64
I've verified that I can build sage-4.2 on my laptop running 10.6,
but
that singular fails (with similar errors reported in the above
logfile) on
two recent Mac desktop machines with the latest XCode.
A pending software update to 10.6.1 (requires a reboot) could explain
the difference, but the sp
Hi,
What is the current status of MacOS 10.6 compatibility?
I just downloaded sage-4.2.tar to my desktop machine
and compilation fails in the singular package (see below).
I don't seem to have succeeded in compiling sage-4.1.2
on any MacOS 10.6 desktop although it seems to have
compiled on my 10.
Hi,
Glad to hear that Javier took up the last category files.
I don't have a strong opinion whether OrderedSets
(or Monoids) should have total or partial ordering.
However, since there is a possible ambiguity, my
preference is to not use OrderedX as an alias for
either PartiallyOrderedX or Total
Hi Nicolas,
If I understand what existed and what is proposed, then
I vote for the category Groupoids() and no arguments.
A standard definition of a groupoid in category theory is
a category in which every morphism is an isomorphism.
Thus it is possible that this was intended as a constructor
fo
What about the category of categories (with functors as morphisms)?
--David
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to
sage-devel-unsubscr...@googlegroups.com
For more
Hi Jenny,
Since the base ring of E is QQ, what do you expect to get for an
input polynomial over Qt? A "feature" of Sage over, say, Magma,
is that the the tracebacks are long (allowing debugging).
Perhaps your entirely valid criticism is that the error in "+" is too
late: some checking that th
I would prefer to generate a html or pdf file that I could view with
standard tools or just read as plain text. Or maybe break the
task into steps: extract the doc strings to a ReST file, and browse
the ReST file with some "standard tools" (say rst2html file |
lynx).
The first step is important
Hi William,
Thanks (to John Palmieri et al), such a feature was requested at Sage
Days 16.
Is there an interface in the command-line version or a command-line
call on a file
that doesn't request require starting up Sage?
Cheers,
David
--~--~-~--~~~---~--~~
To p
Hi Florent,
I think the polynomial ring model should translate well
to the non-commutative free algebras. In addition to
access, specifying a (non-commutative) monomial
ordering would be desirable. Generalizing these
orderings is the only challenge in the generalization
from free commutative al
William,
Thanks for pointing out that I was wrong about the lifting problem
and original of this slow behavior.
Rather than just putting in place the solution by lifting to ZZ,
which
you show to be much faster for reasonable size, I hope someone
can profile arithmetic or linear algebra for ZZ/nZ
Hi,
One can always work around a problem, but it would be
better to discuss the best approach and put this in place.
A related problem I had recently was in finding a random
element of GL_n(ZZ/26ZZ) where n was 20-30. It was
failing to terminate in the determinant computation. My
guess is that
Hi,
The algorithm used doesn't need to be specific to the p-adics,
but shouldn't apply an algorithm for fields or integral domains.
Rather than the matrix code, it looks like this is the source of
the problem:
sage: M.parent().base_ring()
101-adic Ring with capped relative precision 2
sage: R.i
Hi,
We can move this over the sage-nt, but let me reply here.
One improvement should be to, in fact, follow what John [Cremona)]
did for elliptic curves -- replace points-as-morphisms with points as
simple coordinates. In analogy with matrices and homomorphisms,
for reasons of efficiency (and
Hi,
I am finding problems, holes, or missing features in power series
rings
and Laurent series rings.
sage: K. = LaurentSeriesRing(QQ)
sage: R. = PowerSeriesRing(QQ)
1. exp(t) is defined but exp(u) is not.
2. log(1 - t) and log(1-u) -- I started filling in this gap (below)
for
Laurent seri
Hi Nicolas,
I would suggest that the choice of basis (or generators) should
be an intrinsic part of the algebra's representation and interface.
Different representations imply different (but possibly equal, even
canonically equal) algebras.
Compare free modules and polynomial rings:
sage: V = F
Hi,
First, I think (at least last time I tried) there is a lot of room to
speed
up arithmetic in function fields, which would be my first priority.
Second, as a mathematical construction, I think that the
localizations
A_S where A is a ring (e.g. UFD or PID) and S = {p_1,...,p_n} is a
set
of pri
Can I suggest moving this discussion to sage-nt?
Cheers,
David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to
sage-devel-unsubscr...@googlegroups.com
For more options, visit thi
Hi,
The GPL3 decision will undoubtably be (continually) revisited, but
the GPL3 license itself does not (yet) have the concensus of the
open source community.
Currently Microsoft Research is friendly to us, which I distinguish
from Microsoft. Clearly MR is bound by Microsoft, whereas Sage
is no
Compilation got past clisp once I installed XCode 3.1.2.
The lines before the above this reported that readline was
too old, but I don't know if this was the source of the compile
failure.
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-de
Build falled in clisp on MacOSX Leopard:
cp -p cfgunix.lisp
config.lisp
chmod +w
config.lisp
echo '(setq *clhs-root-default* "http://www.lisp.org/HyperSpec/";)' >>
config.lisp
To continue building CLISP, the following commands are
recommended
(cf. unix/INSTALL step 4
ff):
cd
src
emacs
Hi William,
> Is all the code you have above GPL-licensed now?
Yes, see:
http://echidna.maths.usyd.edu.au/kohel/alg/index.html
I need to update the code, but I propose that this could be an
optional
Sage package, for Magma users. This would ensure more users, and
enforce testing against rot,
Hi,
In Python (hence Sage) there exist simple aggregate or
enumerative
structures: dictionaries, lists (and tuples), and sets.
Beyond
these types, there are Sage Sequences and Sets, and (name
under
discussion) EnumeratedSets coming from the combinatorial
community.
For comparison, in Magma one h
Hi Florent,
> > I would also like to see a class which is generally useful
> > throughout Sage, as the default return type for many different
> > finite or enumerable structures.
>
> I'm sorry but I don't understand what you mean by this sentence. Can you give
> an example, please ?
Jason Bandlo
Hi,
1. Here is a bug in evaluation of Magma code
sage: m = Magma()
sage: s = "for i in [1..7] do print i^2+i+1; end for;"
sage: m(s)
...
TypeError: Error evaluating Magma code.
IN:_sage_[5]:=for i in [1..7] do print i^2+i+1; end for;
OUT:
>> _sage_[5]:=for i in [1..7] do print i^2+i+1; end for;
Hi,
> I know nothing of combinatorics, but shouldn't accessing a set's n-th
> element be more understandable using S[n] ?
I agree.
I would think S.index(x) would be more intuitive to a non-
combinatorist
like me. Do I understand correctly that these are sets enumerated by
an indexing set (e.g.
Implementing Florian Hess' article in Sage would be vey
welcome, and I'm sure that Florian (or I for that matter)
would be happy to given input.
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this
Hi,
As I have been creditted by William with the free modules
as row vectors and default left kernel for matrices (under
the influence of Magma), let me propose a coherent way
to relax this design decision.
It should be easy to add an argument to free modules to
create them as column spaces and
Hi,
Despite the length, I prefer cardinality() since card() is vague and
obscure
(and len(), size(), and count() ambiguous).
I would argue that cardinality(), as distinct from len(), should
consistently
return a Sage Integer (or some concept of cardinal number) rather than
a
Python int.
sage:
Hi Paul,
> Thanks for explaining that, I see how that causes problems when S is not a
> set of numbers. Even so, would it make sense for the random variable ps to
> be the identity function X(x) = x on the probability space ps? Currently the
> random variable ps is the function X(x) = P(x). Is th
Hi,
I should point out that the class hierarchy should not be confused
with the categories.
The latter are intended to model the mathematics. In particular a
homomorphism in
the category of rings should satisfy f(x*y) = f(x)*f(y). Each class
is assigned a default
category, but the idea is that
Hi John,
To give a bit more weight to the counterargument against the
alphabetti
solution:
> I agree, and I did not really mean my alphabetti suggestion to be
> taken too seriously.
In some version, there was an invasive declaration of single character
symbols
to be symbolic elements. This ca
P.S. I get the same behavior for 3.1.2.
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-
Hi,
I'm just trying to update my sage for SAGE Days 10, but find that the
compilation hangs here:
checking for paperconf... false
checking for java... /usr/bin/java
checking for javac... /usr/bin/javac
checking for javah... /usr/bin/javah
checking for jar... /usr/bin/jar
checking whether Java co
Hi,
Cc: Paul for comment on local information.
This (http://www.hotel-eclipse.fr) looks inexpensive but (unless
I'm mistaken), not accessible to LORIA or the center except by car.
The center is reasonably accessible by tram; those working late
at LORIA (if this is compatible with building securi
Hi Minh, David, et al.,
Feel free to link or copy these notes. My "old" address in Sydney
should remain valid
for at least the next 2 years, as I have an official honorary position
there, but the notes
may change, so a link would probably be preferable. Eventually I will
to mirror my web
page (a
Hi Harald,
Note that all of the mirrors, mine included in Sydney, rynchronize
sage.math.washington.edu, so this site needs to be current. At
present
the line:
Sage Devel Days 1 (aka Sage Days 8.5) will be in Seattle June 13-20,
2008
is out of date (and it lagged behind sagemath.org in announci
Note that the intent of these SAGE constructors is not (just) to
replicate
the design (and errors) of Magma or other languages. There are
natural
product and coproduct constructions in various mathematical
categories
(e.g. a coproduct in Sets _is_ the union). The constructor
CartesianProduct
sho
Hi David, Nick, et al.,
I will also be arriving for SAGE Devel Days, on the 12th (with
jetlag).
I am interested on focusing on p-adic arithmetic and related
constructions.
A GaloisRing class is essentially an finite quotient of an unramified
p-adic
local ring; if a separate class is created, it
Hi,
> > Given algebras A and B, I would return C and the two maps m1: A -> C
> > and m2: B -> C:
>
> > (C, m1, m2) = A.tensor_product(B,ring=R)
>
> I might prefer to have something like
>
> C = A.tensor_product(B, ring=R)
>
> and then one can do
>
> C.coerce_map_from(A)
> C.coerce_
Hi,
Tensor products (of commutative rings) are "necessary" for
representing the
coordinate rings of a product of [affine] schemes.
For commutative rings, a new tensor product class imay not be needed
or
desirable, rather what is missing currently is the homomorphisms.
Given algebras A and B, I
I support John's view that real-valued lattice need also to be taken
into account. Minkowski lattices of number fields and Mordell-Weil
groups are prime examples.
Some people also like to embed lattices in R^n equipped with the
standard Euclidean inner product. As such the coordinates are
non-r
Hi,
On the subject of notebook features:
One feature that would be really nice is to have distinct text cells,
in html or
even better latex mode. A text cell could created by a hot key (say
)
in edit mode which displays the source latex or html, then toggled out
of edit
mode to display the form
I learned of WIMS (http://wims.unice.fr/) by virtue of the
announcement of a new lecturer
position here in Luminy, who is supposed to be responsible for
computer-based teaching
with WIMS (http://wims.unice.fr/). It overlaps many of the teaching-
related goals of
sage. I just downloaded it and ha
Hi Martin et al.,
Magma doesn't support rank zero polynomial rings and this is a real
pain when
we were trying to implement schemes. I could give you examples which
break
the schemes code, but I made no progress in convincing Allan Steel to
support
this boundary case. On the other hand if the
Hi John,
> I'm not sure I understand the end of your message. Nowhere does the
> code I have in mind assume that anything is cyclic, let alone of prime
> order: the bsgs and dlog functions will terminate if there is no
> solution, with a ValueError.
Since baby-step, giant-step is deterministic
Hi,
I find this discussion interesting since this was a project I
proposed
for magma, implemented by Paulette Lieby. The idea was to take any
finite abelian group G, create a wrapper A = GenericAbelianGroup(G),
passing in various parameters:
magma> GenericAbelianGroup;
Intrinsic 'GenericAbelian
Hi Mike,
Thanks for the explanation.
Indeed a Permutation could be represented by an element of a symmetric
group, but we would want to make sure that until a group-theoretic
question
is asked, no call to GAP should interfere with the calculations.
Your:
sage: G = Permutations(3)
would be ana
> OK, as a conscious decision it is certainly justified. Of course,
> mathematically you are right that an object and a particular basis of
> that object are two different things. Only i was surprised, because i
> grew up with Singular and not with Magma...
FYI, magma has both commands GroebnerBa
Hi All,
Just a few comments: there are three possible concepts for
generator[s]:
1) As a field over its prime field or base field (function gen(),
category Field or Algebra);
2) As a vector space over its base field (function
additive_generators(), category Module)
3) As a group, restricted to t
Hi,
It is probably a bias of the choice of (additive) generators for
finite field
extensions which results in the primitive field element also being a
generator for the multiplicative group (confusingly called a
"primitive
element of the finite field").
It is not possible to set GF(q).gen() to a
> I will try to take all the above on board as I am implementing it, and
> look forward to having you people make constructive criticisms
> But David K's suggestion about the set of all iso/automorphisms might
> wait until the next round.
I (or someone else) can implement the structures of Is
Hi,
Agreed that Magma
> I'll just come out and say it -- It's a _terrible_ design in Magma.
+1.
> Yet another example of the Magma semantics being a pain.
> They don't even use a notion of None. Argh.
+1 ; Although there is a syntax to denote no argument (return x, _;)
The problem is that in
Here is another open source CAS, which is being advertised here.
Someone might want to evaluate it to see how much is being reinvented
and what is new.
Note that it uses a particular French open source licence designed in
response to the GPL and which supposedly addressed legal problems with
the
There was a thread on multiple return values coming from Magma,
since renamed to "Integer points on conics"
William pointed out that one can access the multiple return values
using nvals:
x = magma.XGCD(15, 10)
x,y,z = magma.XGCD(15, 10, nvals = 3)
The first returns an integer, while the seco
Dear John (et
al.),
I think the inner product should be the same irrespective of the
field.
The inner product as dot product is relevant to the study of
quadratic
forms, conics, and orthogonal groups. For instance finding a
rational
point on the conic x^2 + y^2 + z^2 = 0 over CC is equivalent t
Hi,
I didn't implement subs for these types, but it seems to be inheriting
from
some generic code. The description of output says that self is
returned if
the substitution fails, which is the behavior you observe.
This could be fixed by defining subs for a FreeAlgebraElement, but the
logic
of t
Hi John,
> > Group --> WierstrassIsomorphismGroup
> > GroupElement --> WeierstrassIsomorphism
>
> OK I'll try that.
On this subject, I had the idea that an Iso(X,Y) subset of Hom(X,Y)
should
be defined for every category. Note that the subset Aut(X) of an
End(X) is
a group, but in general the W
Hi John,
I would strongly suggest that this construction be compatible
with isogenies (also yet to be implemented). Thus one should
be able to compose isomorphisms and isogenies with one
another. Moreover, one should be able to access the defining
polynomials -- this is useful to verify the def
Since LLL and LLLGram in Magma V2.13 are written by Damien Stehle,
using his asymptotically better algorithm. The previous version was
not
even mathematically correct (adhoc "improvements" or post-processing
could destroy the LLL reduction condition).
Damien provides C code under GPL and can be
Hi,
Just to add my 2 bits, I think we should aim for something like the
following:
sage: x = var('x')
sage: X = x.domain()
sage: X
Affine line over the Real Field
sage: X.identity()
x
sage: f = sin(x)
sage: X == f.domain()
True
sage: f = sin(domain=X,codomain=X)
sage: y = var('y')
sage: g = sin(
I think the problem needs to be profiled. The problem is likely NOT
in elliptic curves, but some
horrendous chain of calls to module operations before getting to the
(same) actual algorithms.
Note that P*2 is slightly faster since it calls directly the member
function of P rather than a
function
OK, William's response clarifies things, and I would just modify my
comment to
suggest that predefining any single character variable is
questionable. I see that
ALL upper and lower case alphabetic characters are so defined.
I was thrown off by the definition of R (a ring to me), and am glad to
I suggest that this automatic construction is too permissive:
sage: x
x
sage: type(x)
whereas this gives a perfectly reasonable compromise:
sage: x = var('x')
sage: x
x
sage: type(x)
I realize that one wants to strike a balance between ease of use and
the benefits of explicit
typing in defin
Hi Everyone,
The main crypto functionality that I implemented concerns classical
cryptography,
for the purposes of teaching:
http://echidna.maths.usyd.edu.au/~kohel/tch/Crypto/
Hence most of the systems are breakable (using suitable classical
cryptanalytic
attacks). The cryptosystem class can
> To David Kohel: index calculus for discrete logs uses linear algebra mod p-1
> (not 2).
Yes, I overstated the similarities between factorization and dlogs.
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.
(Partial) factorization (by trial division) of p-1 is in other to make
use
of CRT of discrete logarithms mod m where m | p-1.
The index calculus algorithm requires a relations collection phase,
and
a linear algebra phase. The linear algebra phase just requires
sparse
linear algebra over F_2 to d
Group algebras would be natural and interesting. I would suggest
that they derive from FreeAlgebra, and improve those if the
performance was inadequate. This gives a sparse representation,
and as I remember, for finite dimensional (quotient) algebras, I
use the explicit matrix representation on
Hi,
Another feature that I find extremely useful are the quotient rings
(currently not implemented).
This allows one to work in a well-defined ring, and control precision
precisely.
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@go
Hi William,
In agreement with Nils, f.valuation() should agree with -f.degree().
This should be a
valid sage session:
sage: f = x^3 + x^5 # = t^-3 + t^-5 = t^-5 (t^2 + 1) where t = 1/x
sage: f.valuation() # should be the valuation at infinity with
uniformizing parameter t
-5
sage: f.factor()
(x^
Hi,
The mploc might require further development to be stable in odd
characteristics, but
at least aims to be a standard p-adic C library. I am very interested
in seeing p-adics
developed, so please CC me:
David R. Kohel <[EMAIL PROTECTED]>
and my student:
Hamish Law <[EMAIL PROTECTED]>
with
Hi Nils,
Things that come to mind are:
1. LLL (wrapping existing code, not implementing it) and more canonical
lattice reduction
for small dimensions, with attention to what has been done in the
context of quadratic forms?
2. Collaboration on robust p-adic arithmetic -- wrapping and/or testing
> I'm really glad I'm not writing everything in SAGE from scratch!
Definitely.
I can put this in this weekend, but if someone doesn't get to it
sooner.
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe
Any ideas how to get a random number from 1 to n in SAGE?
Here's a bad way to do it:
sage: n = 10^2
sage: G = SymmetricGroup(n)
sage: G.random()(1)
which will blow up as n goes to infinity.
Here's a slightly better one:
sage: x = random()
sage: int(n*x)
At least it gives a float's worth of
For x, m != 0 in a Euclidean domain, one should have:
x == m*(x.div(m)) + x.mod(m)
Although one can get the result of x.div(m) as x.quo_rem(m)[0],
but I would suggest having this as a separate function.
I know that it is more efficient, if one wants both, to use quo_rem,
and
essentially no
sage: I = [3, 13, 16, 7, 15, 23, 6, 9, 10, 18, 5, 19, 24, 14, 25, 2,
11, 21, 4, 1, 12, 17, 8, 20, 22, 26]
sage: G = SymmetricGroup(26)
sage: G(I)
I can't trace where the PermList string is getting lost on the way to
or from the GAP interpreter,
but here's a problem:
sage: gap.eval('PermList(' +
It would be great if the latex preparsing with sage -t
could also parse files included by \input{subfilename}
--David
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PRO
Hi William,
Oops, I forgot to post my reply to my own message. This is the
solution I found,
using the same GAP manual entry for PermList.
def gap_format_cycles(x):
"""
Put a permutation in Gap format, as a string.
"""
x = str(x).replace(' ','')
return x.replace('),(',')(').repl
Hi David J et al.,
There are two "natural" representations for permutations, cycles, and
enumerated
lists of images (or indices). In addition to this constructor:
sage: G = SymmetricGroup(14)
sage: G = SymmetricGroup(4)
sage: g = G("(1,2,3,4)")
sage: g(1)
2
sage: [ g(i+1) for i in range(4) ]
[
1 - 100 of 102 matches
Mail list logo