yes, that is exactly was i had been hoping for. thank you!
(yesterday evening, when i mailed here, the ask.sagemath.org site was down.)
On Tue, Apr 2, 2019 at 12:02 AM Eric Gourgoulhon
wrote:
> I've edited my answer at
> https://ask.sagemath.org/question/45959/grad-at-glacial-speed/
> to
I've edited my answer at
https://ask.sagemath.org/question/45959/grad-at-glacial-speed/
to indicate how to change the simplification algorithm.
Best wishes,
Eric.
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from this
For rational functions you'd rather want to work with polynomials, not
(symbolic) functions.
sage: R.=QQ[]
sage: q=(x^2+4*x+4)/(x+2)^2
sage: q
1
sage: q=(x^2+4*x+4)/(x+2)^3
sage: q
1/(x + 2)
sage: q.parent()
Fraction Field of Univariate Polynomial Ring in x over Rational Field
On Thursday,
Thank you!
On Friday, February 27, 2015 at 5:41:07 PM UTC+2, vdelecroix wrote:
Here is one way... not sure it is the best
sage: eq1 = sqrt(cos(4*x)+1)
sage: eq2 = eq1.simplify_trig()
sage: eq2
sqrt(8*cos(x)^4 - 8*cos(x)^2 + 2)
The next step consists in factoring what is inside the
Hi Paul,
On 2015-02-27, Paul Royik distantjob...@gmail.com wrote:
What is the way to consistently simplify square roots of squares?
Examples:
sqrt((x+1)^2) - x+1
sqrt(cos(4*x)+1) - sqrt(2)cos(2x)
Simplification must not change the value of the expression. sqrt(x^2) is
certainly not equal
But...
sage: eq = sqrt((pi-5)^2)
sage: eq.canonicalize_radical()
pi - 5
And as you can read from the documentation
Choose a canonical branch of the given expression. The square root,
cube root, natural log, etc. functions are multi-valued. The
canonicalize_radical() method will choose
OK. Let x is real.
How to rewrite sqrt(cos(4x)+1) into sqrt(2)abs(cos(2x))?
On Friday, February 27, 2015 at 3:36:59 PM UTC+2, Simon King wrote:
Hi Paul,
On 2015-02-27, Paul Royik distan...@gmail.com javascript: wrote:
What is the way to consistently simplify square roots of squares?
Here is one way... not sure it is the best
sage: eq1 = sqrt(cos(4*x)+1)
sage: eq2 = eq1.simplify_trig()
sage: eq2
sqrt(8*cos(x)^4 - 8*cos(x)^2 + 2)
The next step consists in factoring what is inside the sqrt:
sage: o = eq2.operands()[0]
sage: of = o.factor()
sage: o
8*cos(x)^4 - 8*cos(x)^2 + 2
Hi!
On 2014-05-29, SiL588 . ch4r...@hotmail.com wrote:
Hi, i tried to simplify a number doing this:
m1.simplify()
but the output is
AttributeError: 'sage.rings.real_mpfr.RealNumber' object has no
attribute 'simplify'
What does it mean?
What did I do wrong? I declared m1 like this:
m1
What exactly do you mean by simplify a real number?
On Thu, May 29, 2014 at 8:32 AM, SiL588 . ch4r...@hotmail.com wrote:
Unfortunately I don't know the rules of Phyton language, i just started
using Sage notebook to do linear algebra computation.
I think I did what you said, I assinged m a
The output i have is this:
12.0
and I didn't want all those zeroes after the point.
Il giorno giovedì 29 maggio 2014 17:46:51 UTC+2, Robert Bradshaw ha scritto:
What exactly do you mean by simplify a real number?
On Thu, May 29, 2014 at 8:32 AM, SiL588 .
On Thu, May 29, 2014 at 8:59 AM, SiL588 . ch4r...@hotmail.com wrote:
The output i have is this:
12.0
and I didn't want all those zeroes after the point.
Try doing
int(m)
or floor(m)
William
Il giorno giovedì 29 maggio 2014 17:46:51 UTC+2, Robert Bradshaw ha scritto:
Hi,
On 2014-05-29, SiL588 . ch4r...@hotmail.com wrote:
Unfortunately I don't know the rules of Phyton language,
Sage's main language for programming is Python, and also the language for
user interaction is close to Python. We believe it is a big plus of Sage
that it uses a mainstream language!
Il giorno giovedì 29 maggio 2014 18:06:19 UTC+2, Simon King ha scritto:
Hence, at least for those variables that you override in the second
cell, the first cell is of no use.
Oh ok, I didn't understand that's the way it works
I don't know what you mean by simplify a real number.
We get in trouble with your question, because you used simplify
verb...which should have been refering to other SAGE simplifying functions
(floor, simplify symbolic expression and so on) when you wanted to
display only few significant digits of that real number.
Function for you is :
If you just want to safely print numbers with the trailing zeros
removed, used strip:
a = 12.00
b = 0.8
str(a).rstrip('0')
str(b).rstrip('0')
On Thu, May 29, 2014 at 9:53 AM, Dominique Laurain
dominique.laurai...@orange.fr wrote:
We get in trouble with your question, because you
I'm sorry I wasn't clear, as I said I just started using Sage and I thought
that was what the simplify method was for.
Thank you very much for your explanation, now I got it :)
Il giorno giovedì 29 maggio 2014 18:53:23 UTC+2, Dominique Laurain ha
scritto:
We get in trouble with your question,
Okay, thank you very much! :)
Il giorno giovedì 29 maggio 2014 18:57:45 UTC+2, William ha scritto:
If you just want to safely print numbers with the trailing zeros
removed, used strip:
a = 12.00
b = 0.8
str(a).rstrip('0')
str(b).rstrip('0')
--
You received this
Hi,
excellent! Thank you very much!
Joa
Den onsdagen den 21:e maj 2014 kl. 17:12:51 UTC+2 skrev Dima Pasechnik:
On 2014-05-21, st...@joa.me.uk javascript: st...@joa.me.ukjavascript:
wrote:
Hi,
it is a system of resitors and capacitors. I can in principle do a bit
of
math and
On 2014-05-21, st...@joa.me.uk st...@joa.me.uk wrote:
Hi all,
I use sage to solve a system of equations describing and electronical
filter. I then use sympy and codegen to generate c code that I use in my
main code written in c. This works almost like a charm, expept that it
produces
Hi, I haven't looked into that file, but maybe you should try to solve and
simplify the equations directly in sympy?
There is also a group for sympy, maybe they can help you streamlining this,
too.
https://groups.google.com/forum/#!forum/sympy
Harald
--
You received this message because you
Den onsdagen den 21:e maj 2014 kl. 13:28:54 UTC+2 skrev Dima Pasechnik:
On 2014-05-21, st...@joa.me.uk javascript: st...@joa.me.ukjavascript:
wrote:
Hi all,
I use sage to solve a system of equations describing and electronical
filter. I then use sympy and codegen to generate c
On 2014-05-21, st...@joa.me.uk st...@joa.me.uk wrote:
Den onsdagen den 21:e maj 2014 kl. 13:28:54 UTC+2 skrev Dima Pasechnik:
On 2014-05-21, st...@joa.me.uk javascript: st...@joa.me.ukjavascript:
wrote:
Hi all,
I use sage to solve a system of equations describing and electronical
Hi,
it is a system of resitors and capacitors. I can in principle do a bit of
math and calculate Ztotal of my circuit. And calculate Itotal. From this I
can get the current I want by repeated current splitting in parallel
impedances. I have tried this as well. The results are the same. The
On 2014-05-21, st...@joa.me.uk st...@joa.me.uk wrote:
Hi,
it is a system of resitors and capacitors. I can in principle do a bit of
math and calculate Ztotal of my circuit. And calculate Itotal. From this I
can get the current I want by repeated current splitting in parallel
impedances. I
Hi,
I do not see any simple way to do this in Sage at the moment. Following
this
posthttps://doxdrum.wordpress.com/2011/01/23/sage-tip-rewriting-expressions/,
a workaround is to use the extension rewrite() written by François Maltey
(see here http://wiki.sagemath.org/symbolics/rewrite for
John Cremona describes an use of the algebraic QQbar domain :
Then I test
a=sqrt(2)-sqrt(3)
b=sqrt(3)-sqrt(2)
QQbar(a).minpoly() ; QQbar(b).minpoly() # seems right. The same even
polynom.
But the test and the numerical values are True. I get +0.31 in both cases.
QQbar(a)==QQbar(b)
This
With d=c-a, not even d.simplify_radical() gives 0.
Simplifying nested radicals is a notoriously hard problem in
symbolic computer algebra. As this example shows (unless there are
other tricks to try which I do not know about), Sage's symbolic system
is not up to examples like this.
As an
Hello John
thank you for this. I tried the same thing on mathematica,
which managed to simplify 'c' back to 'a'.
I don't quite understand the culture of sage-support yet.
Is commenting on mathematica's ability to do a particular
task a useful thing to say? Or does it just annoy everyone?
best
On Jan 26, 8:42 am, Loïc xl...@free.fr wrote:
Hello list,
Version: sage 4.6.1
I'm quite a newbie with Sage but I'm really impressed this powerful
software.
Since an hour, I'm on a stupid problem:
sage: sqrt(2)*sqrt(3)
sqrt(2)*sqrt(3)
sage: sqrt(2)*sqrt(3)-sqrt(6)
sqrt(2)*sqrt(3)-sqrt(6)
2011-01-26 09:14, Minh Nguyen skrev:
On Wed, Jan 26, 2011 at 6:41 PM,xl...@free.fr wrote:
sage: sqrt(2)*sqrt(3)-sqrt(6)
sqrt(2)*sqrt(3)-sqrt(6)
I would expect results sqrt(6) and 0...
I try with the command simplify() but it doesn't do anything.
In the above Sage session, you declared two
On Jan 22, 3:48 pm, Michael Beeson profbee...@gmail.com wrote:
after declaring variables make these definitions
sage: a = Z - Z^-1
sage: b = L - L^-1
sage: c = Z^2L-Z^-2L^-1
sage: f = (p*a + q*b + r *c) *a + (n*a + m *b + l*c) * a*b
Now I can tell it assume(Z^3 * L^2 == -1) but I
lastras ha scritto:
Sage is unable to simplify the following expression to zero:
log( (a-1)/a ) - log(a-1) + log(a)
I have tried assuming a1 but that does not work.
Help will be appreciated.
Tanks!
(log( (a-1)/a ) - log(a-1) + log(a)).full_simplify()
works for me.
By the way, I
On Sep 11, 2009, at 6:21 PM, Laurent wrote:
By the way, I have a question which is far away from Sage : in the
sentence
Help will be appreciated.
Is appreciated a false-friend for the French expression
appréciée ?
Can one use appreciated in English in that context ?
Appreciated
On Sep 11, 3:21 pm, Laurent moky.m...@gmail.com wrote:
lastras ha scritto:
Help will be appreciated.
Tanks!
By the way, I have a question which is far away from Sage : in the sentence
Help will be appreciated.
Is appreciated a false-friend for the French expression appréciée ?
I'm
Is appreciated a false-friend for the French expression appréciée ?
I'm not sure what false-friend means here. Appreciated is an
German has this expression too for the concept. I think that false
cognate is the usual English term.
- kcrisman
Hi Roland,
On 21 Jul., 06:33, Rolandb rola...@planet.nl wrote:
Hi,
How to simplify an expression if you have some known relations
(equalities)? Example:
relation: 0 = a*x1^2 + b*x2^2
expression = (a*x1^2 + b*x2^2)*y1+b*y2^3
Are all your relations polynomial? Then the standard solution is
Hi Roland,
Would this help?
sage: var ('a b x1 x2 y1 y2')
(a, b, x1, x2, y1, y2)
sage: expression = (a*x1^2 + b*x2^2)*y1 + b*y2^2
sage: expression.subs_expr((a*x1^2 + b*x2^2) == 0)
b*y2^2
Stan
Rolandb wrote:
Hi,
How to simplify an expression if you have some known relations
(equalities)?
Simon, thanks!
But in general there is no (Sage) algoritm to simplify expressions
given some equalities?
Rolandb
On 21 jul, 08:05, Simon King simon.k...@uni-jena.de wrote:
Hi Roland,
On 21 Jul., 06:33, Rolandb rola...@planet.nl wrote:
Hi,
How to simplify an expression if you have
sage: a = (-2*sqrt(2)*I - 2)/2
sage: a.simpl
a.simplify a.simplify_full a.simplify_radical a.simplify_trig
a.simplify_exp a.simplify_log a.simplify_rational
sage: a.simplify_full()
-sqrt(2)*I - 1
On Thu, Dec 25, 2008 at 6:35 AM, H.S.Rai hardeep@gmail.com wrote:
40 matches
Mail list logo