On Tuesday, September 15, 2020 at 3:20:13 PM UTC-4 Emmanuel Charpentier
wrote:
> sage: L[1].n()
>
> fails because L1 is an equation, i. e a symbolic expression whose operator
> is the built-in “eq”, which has no n() method.
>
> However,
>
> sage: PP=-625/1000*t^4 + 2355/100*t^3 -
sage: L[1].n()
fails because L1 is an equation, i. e a symbolic expression whose operator
is the built-in “eq”, which has no n() method.
However,
sage: PP=-625/1000*t^4 + 2355/100*t^3 - 264051/1000*t^2 + 10269/10*t - 8538/10
sage: PP.parent()
Symbolic Ring
sage: L=solve(PP,t)
sage:
Thanks! I've already learned more.
What I first did was this:
sage: PP
-0.625*t^4 + 23.55000*t^3 - 264.0510*t^2 +
1026.900*t - 853.8000
sage: L=solve(PP==0,t)
sage: L[1]
t ==
-1/1250*sqrt((390625*(4/1953125*I*sqrt(37468876945450884598)*sqrt(5) -
> I still don't know my way around the Sage documentation... Sorry for the
> elementary question.
>
> Yeah, we are sorry that it never has gotten more organized (though it is
actually quite thorough!). You may want to try the French (now in
English) Sage book, or Greg Bard's AMS (but free
H = (Mod(20192834, 20876441)^-1 * 5260862).nth_root(17)
On Thursday, May 14, 2020 at 3:26:09 PM UTC+2, Madison Adams wrote:
>
> Solve this Equation for H: 5260862 = M*H^y % 20876441
>
> Does anyone happen to know the steps to solve for h:
> Equation: 5260862 = M*Hy % 20876441
>
> Where y = 17,
Have you had a look at
https://doc.sagemath.org/html/en/reference/numerical/sage/numerical/mip.html?
Seems to be what you want to do essentially.
julian
On Sunday, October 20, 2019 at 5:34:37 PM UTC+2, Santanu wrote:
>
> Hi,
> I have inequalities like these:
>
> 3 x1 + 5 x2 + 2 x3 + 5 x4 + 7
On Tue, 30 Jul 2019 at 05:56, Kwankyu wrote:
>
>
> On Thursday, July 25, 2019 at 12:08:20 AM UTC+9, chandra chowdhury wrote:
>>
>> I have matrices B and C of size (m,n) over integer with m>n.
>> I know there is matrix A of size (m,m) such that
>> AB=C. How to find A efficiently in Sage?
>>
>
Try
On Thursday, July 25, 2019 at 12:08:20 AM UTC+9, chandra chowdhury wrote:
>
> I have matrices B and C of size (m,n) over integer with m>n.
> I know there is matrix A of size (m,m) such that
> AB=C. How to find A efficiently in Sage?
>
I guess there is no special way in Sage to solve your kind
after solving an equation (or not) for x, I can check if the answer still
contains x by ans.has(x).
That should weed out any non-explicit solutions.
But still: am I guaranteed for any class of equations, e.g. polynomial
equations of degree <= 4,
that if solve produces an empty list there
On Tuesday, February 19, 2019 at 8:56:50 AM UTC-8, Michael Beeson wrote:
>
> When I try to reproduce Eric's post, I get an error message about an
> unexpected keyword argument
> (maybe my version of Sage is too old.) But look at this:
>
> sage:
When I try to reproduce Eric's post, I get an error message about an
unexpected keyword argument
(maybe my version of Sage is too old.) But look at this:
sage: solve(*2**(x+sqrt(*1*-x^*2*))-*7*,x,explicit_solutions=True)
[1/4*I*sqrt(41) + 7/4 == -1/2*sqrt(7/2*I*sqrt(41) + 2), 1/4*I*sqrt(41)
Eric's post shows me how to get that particular example solved. But my
real
concern is, when my code (inside some deep loop) calls solve, I want to
know
(a) if it returns an answer, that answer really is a solution, and (b) if
it
returns an empty list, there really is no solution.
Hi,
Le lundi 18 février 2019 21:56:56 UTC+1, Michael Beeson a écrit :
>
> sage: solve(*2**(x+sqrt(*1*-x^*2*))-*7*,x)
>
> [x == -sqrt(-x^2 + 1) + 7/2]
>
>
> sage: version()
>
> 'SageMath version 8.0, Release Date: 2017-07-21'
>
>
> That doesn't look like a solution to me because x still appears
yes exactly what I wanted. Sorry again for the bad explanation of my
problem, by the way I hadn't found the wiki you gave the link
Thanks
Henri
Le vendredi 5 octobre 2018 13:05:06 UTC+2, HG a écrit :
>
> I would like to solve these equations but I don't know how?
> >
> >
It seems you want to revert the Lorentz transformation:
https://en.wikipedia.org/wiki/Lorentz_factor#Occurrence
In this case you have a system of equations relating
the various quantities c, ga, t, tt, x, xx, v, where
- ga is the gamma factor, c is the speed of light,
- v is the relative speed
sorry for the bazar !
I don't know how to make latex in the mail
I will make it with sage
Le vendredi 5 octobre 2018 13:05:06 UTC+2, HG a écrit :
>
> I would like to solve these equations but I don't know how?
> >
> > t_0=t_p==gamma*(t-V*x/c^2);show(t_0)
> > x_0=x_p==gamma*(x-V*t);show(x_0)
> >
Sorry for not being clear :)
I wonder if I can calculate
x'′=γ(x−vt)
t′=γ(t−vxc2)
γ=11√−v2c2
Le vendredi 5 octobre 2018 13:05:06 UTC+2, HG a écrit :
>
> I would like to solve these equations but I don't know how?
> >
> > t'=gamma*(t-vx/c^2);show(t')
> > x'=gamma*(x-v*t);show(x')
> >
> >
On Wed 2018-10-03, 18:34:51 UTC+2, HG wrote:
> I would like to solve these equations but I don't know how?
>
> t_0=t_p==gamma*(t-V*x/c^2);show(t_0)
> x_0=x_p==gamma*(x-V*t);show(x_0)
>
> solve(t_0,gamma*(t-V*x/c^2))
> desolve(gamma*(t-V*x/c^2)==0,x)
>
> error desolve() takes at least 2 arguments
You are doing inexact computations, and imaginary errors creep in. Indeed,
let's first run without assume()'s:
sage: s=solve(f(x) == 0,x)
sage: [t.rhs().n() for t in s]
[0.464973569257452 - 1.11022302462516e-16*I,
0.0267727617252126 + 1.11022302462516e-16*I,
2.00825366901734]
so you see a
> >
> > Interesting. If you have ideas on how to improve it so that you might
> do
> > so, please start a thread on sage-devel about that.
>
> I don't. I have expressed my dislike of AskSage as soon as it was
> available. It is just that I don't like all these badges and awards and
> I
Sage has two sources of support, the mailing list sage-support and the
AskSage site. Users and helpful developers can use whichever they
choose, and I don't think that any of us should be telling anyone
which one they ought to use, either as an asker of questions or as a
helpful answerer. Of
Hi Karl-Dieter,
On 2016-11-09, kcrisman wrote:
>> > This is a very good question for Ask Sage, would you ask it there?
>>
>> Why should he? He did ask here. And I, for one, dislike the Ask Sage
>> pages to the extent that I wouldn't answer questions there.
>>
>
>
> > This is a very good question for Ask Sage, would you ask it there?
>
> Why should he? He did ask here. And I, for one, dislike the Ask Sage
> pages to the extent that I wouldn't answer questions there.
>
Interesting. If you have ideas on how to improve it so that you might do
so,
A bit of numerical analysis (see enclosed Jupyter notebook) proves that
this polynomial has at least two real roots, and quite probably four), one
of them being positive.
This triggers the question : does Sage have built-in facilities for
uncertainty computation ("calcul d'erreurs" in French,
On 2016-11-08, slelievre wrote:
> This is a very good question for Ask Sage, would you ask it there?
Why should he? He did ask here. And I, for one, dislike the Ask Sage
pages to the extent that I wouldn't answer questions there.
Cheers,
Simon
--
You received this
Sun 2016-11-06 16:00:30 UTC+1, Francis Banks:
> I am solving a polynomial which arises from plotting titration cures
> in chemistry. The rule of signs suggests it has one positive root.
> Find_root seems to find it. Solve with poly_solve=true does not.
> Instead it gives 4 complex roots, which
On Sunday, November 6, 2016 at 3:00:30 PM UTC, Francis Banks wrote:
>
> I am solving a polynomial which arises from plotting titration cures in
> chemistry. The rule of signs suggests it has one positive root. Find_root
> seems to find it. Solve with poly_solve=true does not. Instead it gives
thank you, Simon
many computational aspects, but still human insight is needed to break a
problem up into sub-problems of chewable size, or transform the original
problem into one that is more accessible to automatic solutions. And
even if a computer algebra system (no matter which one)
In fact, the solution is: w=t+t^2
Are you sure? Assuming some value for t, plotting the expression
doesn't seem to show a solution at w = t + t^2.
I am sorry. I made a mistake.
best
Robert Dodier
--
You received this message because you are subscribed to the Google Groups
Thanks to Emmanuel Charpentier for the solution.
But the trick is S1[0]^2 that needs human works.
Le samedi 18 octobre 2014 11:58:37 UTC+2, Emmanuel Charpentier a écrit :
Well, after a bit of sleep, the solution was (semi-)obvious :
sage: var(w,t)
(w, t)
sage:
Hi!
On 2015-03-09, platane guo...@gmail.com wrote:
Thanks to Emmanuel Charpentier for the solution.
But the trick is S1[0]^2 that needs human works.
Sure. But that's a very common situation. Computers are very good in
many computational aspects, but still human insight is needed to break a
Hello guy,
Your question looks like a modeling math problem, ...and is not related
to SAGE.
I wouln't try to solve quadratic problem using linear solvers : LP
means Linear Programming
for definition of LP, read
http://www.sagemath.org/doc/reference/numerical/sage/numerical/mip.html
more
On 2014-12-11, pegah Ali pegah.aliza...@gmail.com wrote:
--=_Part_141_146171712.1418307564716
Content-Type: multipart/alternative;
boundary==_Part_142_2134155063.1418307564716
--=_Part_142_2134155063.1418307564716
Content-Type: text/plain; charset=UTF-8
Hello everybody,
Hello Dima,
Thank you for your response. It gave me some ideas :)
On Thursday, December 11, 2014 3:19:24 PM UTC+1, pegah Ali wrote:
Hello everybody,
I am new to sage and try to solve the following LP with
MixedIntegerLinearProgram:
Maximization:
3.0 x_0 + 2.0 x_1 - 1.0
Well, after a bit of sleep, the solution was (semi-)obvious :
sage: var(w,t)
(w, t)
sage: E1=-(1/2*sqrt((4*w+1)+1))*t+w==0
sage: S1=E1.solve(w)
sage: S1
[w == 1/2*t*sqrt(4*w + 2)]
sage: S2=((S1[0])^2).solve(w)
sage: S2
[w == 1/2*t^2 - 1/2*sqrt(t^2 + 2)*t, w == 1/2*t^2 + 1/2*sqrt(t^2 + 2)*t]
A
Ahem !
On one machine :
sage: sage.version.version
'6.4.beta4'
sage: var(w,t)
(w, t)
sage: solve(-(1/2*sqrt((4*w+1)+1))*t+w==0,w)
[w == 1/2*t*sqrt(4*w + 2)]
sage: maxima.version()
'5.34.1'
Another one :
sage: sage.version.version
'6.4.beta1'
sage: var(w,t)
(w, t)
sage:
2014-10-17 10:09 UTC, Emmanuel Charpentier emanuel.charpent...@gmail.com:
Ahem !
On one machine :
sage: sage.version.version
'6.4.beta4'
sage: var(w,t)
(w, t)
sage: solve(-(1/2*sqrt((4*w+1)+1))*t+w==0,w)
[w == 1/2*t*sqrt(4*w + 2)]
This solution is implicit. This is the problem.
Vincent
Le vendredi 17 octobre 2014 16:37:55 UTC+2, vdelecroix a écrit :
2014-10-17 10:09 UTC, Emmanuel Charpentier emanuel.c...@gmail.com
javascript::
Ahem !
On one machine :
sage: sage.version.version
'6.4.beta4'
sage: var(w,t)
(w, t)
sage:
On 2014-10-15, platane guo...@gmail.com wrote:
solve does not solve ?
sage: solve(-(1/2*sqrt((4*w+1)+1))*t+w==0,w)
[w == 1/2*sqrt(4*w + 2)*t]
Well, if I'm not mistaken, Sage punts to Maxima's 'solve' function,
which, I'm sorry to report, is not very strong (it can solve a
relatively narrow
sage: solve(-(1/2*sqrt((4*w+1)+1))*t+w==0,w)
[w == 1/2*sqrt(4*w + 2)*t]
Well, if I'm not mistaken, Sage punts to Maxima's 'solve' function,
which, I'm sorry to report, is not very strong (it can solve a
relatively narrow range of problems). But I find that Maxima's
'to_poly_solve'
Have zeros of order 2 too, so the sign change doesn't help in general, but
may work for some zeros. Thank you!...
On Saturday, June 21, 2014 1:21:06 AM UTC-7, Dima Pasechnik wrote:
On 2014-06-21, David Ingerman davidd...@gmail.com javascript: wrote:
Thank you, that's helpful. Is there a
On 2014-06-22, David Ingerman daviddavif...@gmail.com wrote:
Thank you, that makes sense. My Python function is not continuous though,
has poles, so I'll probably have to plot it to find its zeros...
you might perhaps try finding a pole p by solving 1/f(x)=0, and
regularise f by multiplying
Thank you, that's helpful. Is there a way to get all roots of a Python
function on an interval?
On Friday, June 20, 2014 2:10:38 AM UTC-7, Dima Pasechnik wrote:
On 2014-06-20, David Ingerman davidd...@gmail.com javascript: wrote:
Thank you, so what to do for Python function? Matlab had
On 2014-06-21, David Ingerman daviddavif...@gmail.com wrote:
Thank you, that's helpful. Is there a way to get all roots of a Python
function on an interval?
I never heard of robust procedures for such a task, and doubt they are
even possible (think about roots of sin(1/x) on [0,1]).
Thank you, that makes sense. My Python function is not continuous though,
has poles, so I'll probably have to plot it to find its zeros...
On Saturday, June 21, 2014 1:21:06 AM UTC-7, Dima Pasechnik wrote:
On 2014-06-21, David Ingerman davidd...@gmail.com javascript: wrote:
Thank you,
On 2014-06-20, David Ingerman daviddavif...@gmail.com wrote:
Thank you, so what to do for Python function? Matlab had general purpose
'optim(f)' if my memory is right...
you can e.g. use find_root(); this is a numerical thing that accepts
Python functions. Here is an example:
sage: def
Thank you, so what to do for Python function? Matlab had general purpose
'optim(f)' if my memory is right...
On Wednesday, June 11, 2014 1:50:10 AM UTC-7, Dima Pasechnik wrote:
On 2014-06-10, David Ingerman davidd...@gmail.com javascript: wrote:
How to solve([f(x)==0],x) for a
On 2014-06-10, David Ingerman daviddavif...@gmail.com wrote:
How to solve([f(x)==0],x) for a function f(x) defined in a .sage file?
The error message: TypeError: Cannot evaluate symbolic expression to a
numeric value.
what is f(x) ?
solve() won't work for a Python function, it needs a
Sorry to keep on here, but I've
got three other related queries:
(1) solve? gives me solve(sin(x)==x,x,explicit_solutions=True)
as an example which returns an empty list of solutions.
But x=0 surely counts as an explicit solution? I guess my
interpretation of an empty list as
I've opened http://trac.sagemath.org/sage_trac/ticket/14738 for a lot of
this stuff. It's all related to keywords not being sufficiently happy.
There is a ticket for adding a lot of that to the main 'solve?' but Trac
seems to be down right now so I can't find it...
robin hankin wrote:
hello, sage 5.9
If solve() gives an unspecificed integer, how do I substitute a
particular value into the expression?
subs() does not work as expected/desired because the free variables
don't seem to be defined.
sage: a=solve(sin(x)==0,x,to_poly_solve='force');a
[x ==
leif wrote:
robin hankin wrote:
hello, sage 5.9
If solve() gives an unspecificed integer, how do I substitute a
particular value into the expression?
subs() does not work as expected/desired because the free variables
don't seem to be defined.
sage:
On Wednesday, June 12, 2013 8:09:02 PM UTC-4, leif wrote:
robin hankin wrote:
hello, sage 5.9
If solve() gives an unspecificed integer, how do I substitute a
particular value into the expression?
subs() does not work as expected/desired because the free variables
don't
kcrisman wrote:
On Wednesday, June 12, 2013 8:09:02 PM UTC-4, leif wrote:
robin hankin wrote:
hello, sage 5.9
If solve() gives an unspecificed integer, how do I substitute a
particular value into the expression?
subs() does not work as expected/desired
On Thu, Jun 13, 2013 at 12:45 PM, kcrisman kcris...@gmail.com wrote:
Smells like a bug...
Not exactly. The documentation for solve makes it clear (I hope!) in the
examples that these are generic variables generated by Maxima which we do
not make Sage variables. They just mean, any old
I take it you mean polynomial equations:
sage: AA.x,y = AffineSpace(GF(2),2)
sage: S = AA.subscheme(x^2+y^2)
sage: S.point_set().points()
[(0, 0), (1, 1)]
On Saturday, December 8, 2012 6:14:19 AM UTC, Santanu wrote:
I have a system of non linear equations over GF(2). How to solve
them in
Or compute a Gröbner basis:
sage: P.x,y = BooleanPolynomialRing()
sage: Ideal(x^2 + y^2).groebner_basis()
[x + y]
sage: Ideal(x^2 + y^2).variety()
[{y: 0, x: 0}, {y: 1, x: 1}]
On Saturday 08 Dec 2012, Volker Braun wrote:
I take it you mean polynomial equations:
sage: AA.x,y =
Thank you. But when I try to solve
f1=x1 + x2 + x4 + x10 + x31 + x43 + x56 ,
f2=x2 + x3 + x5 + x11 + x32 +x44 + x57,
it becomes very slow. Is there any faster approach like
F4 algorithm available in Sage?
On 8 December 2012 17:25, Martin Albrecht martinralbre...@googlemail.comwrote:
Or
On Saturday, December 8, 2012 11:07:31 AM UTC-6, Santanu wrote:
Thank you. But when I try to solve
f1=x1 + x2 + x4 + x10 + x31 + x43 + x56 ,
f2=x2 + x3 + x5 + x11 + x32 +x44 + x57,
it becomes very slow. Is there any faster approach like
F4 algorithm available in Sage?
F4 is not yet
We are talking about the Boolean polynomial ring here, right? So an F4 style
algorithm is used by default (subject to some heuristics). To emphasise you'd
have to construct your ring using the BooleanPolynomialRing constructor.
On Saturday 08 Dec 2012, john_perry_usm wrote:
On Saturday,
On Jul 21, 9:03 pm, Marshall Hampton hampto...@gmail.com wrote:
Ticket 8553 doesn't fix this, so while it is a related issue this will
need a ticket of its own. Looking at the source its not clear to me
why your last example doesn't return a list.
I
Try something like this:
from mpmath import *
mp.dps = 30; mp.pretty = True
f=[lambda s00, s01, s10, s11, k, p:0.55*k*s00 + 0.6*k*s01 + 0.6*k*s10
+ 0.6*p*s01 + 0.6*p*s10 +0.55*p*s11 + 33*s00 + 33*s01 + 33*s10 +
33*s11 - 33.0,
lambda s00, s01, s10, s11, k, p:0.55*k*s00 + 0.6*k*s01 + 0.6*k*s10 +
Ticket 8553 doesn't fix this, so while it is a related issue this will
need a ticket of its own. Looking at the source its not clear to me
why your last example doesn't return a list.
I created http://trac.sagemath.org/sage_trac/ticket/11618 to address
this. Hopefully someone from 8553 can fix
Thanks, this at least gives a reasonable answer and will work in the
short-term. I'm still confused about why solve() didn't work, though.
On Thu, Jul 21, 2011 at 11:44 PM, achrzesz achrz...@wp.pl wrote:
Try something like this:
from mpmath import *
mp.dps = 30; mp.pretty = True
On 06/29/11 16:28, Jason Grout wrote:
On 6/29/11 3:22 PM, Michael Orlitzky wrote:
This is probably just a case of don't do that, but I thought I'd check:
sage: c = [ var('c[0]') ]
sage: system = c[0]*x == 1
sage: solve(system, c[0])
boom
...
TypeError: unable to make
On 6/29/11 3:22 PM, Michael Orlitzky wrote:
This is probably just a case of don't do that, but I thought I'd check:
sage: c = [ var('c[0]') ]
sage: system = c[0]*x == 1
sage: solve(system, c[0])
boom
...
TypeError: unable to make sense of Maxima expression '[c[0]==1/x]' in
Thats
http://trac.sagemath.org/sage_trac/ticket/7496
and its scheduled for sage-4.7.2
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at
Normally solve(e == m, a_x, to_poly_solve='force') works, but interestingly,
not for your equation.
Joal Heagney
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options,
Btw. I use sage 4.6.2. I wasn't aware that 4.7 allready exists.
I will try out if the issue still exists in 4.7.
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit
This is already mentioned here:
http://www.mail-archive.com/sage-support@googlegroups.com/msg20832.html
(It seems from that thread that this may not be a problem with Sage
itself.)
It should be reported as a bug if it hasn't been already.
On May 17, 12:20 pm, tvn nguyenthanh...@gmail.com wrote:
On May 18, 2:21 am, zsharon zacherysha...@gmail.com wrote:
This is already mentioned
here:http://www.mail-archive.com/sage-support@googlegroups.com/msg20832.html
(It seems from that thread that this may not be a problem with Sage
itself.)
It should be reported as a bug if it hasn't been
so is there someway we can do so that this patch or temporary solution be
pushed into the next Sage release ?
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit
On May 18, 9:17 am, tvn nguyenthanh...@gmail.com wrote:
so is there someway we can do so that this patch or temporary solution be
pushed into the next Sage release ?
Well, *you* can do that yourself - see, for instance,
Speaking about solve(), is there a place to report equations it cannot
solve
(and I believe it should?).
I suppose putting it on the same Trac ticket is wrong practice? But
should
it be another ticket, or some yet other place?
Robert
Yup. solve() probably needs a general overhaul (and has for
On Oct 19, 5:23 am, Robert Samal robert.sa...@gmail.com wrote:
Speaking about solve(), is there a place to report equations it cannot
solve
(and I believe it should?).
I suppose putting it on the same Trac ticket is wrong practice? But
should
it be another ticket, or some yet other place?
On Oct 12, 6:37 pm, Robert Samal robert.sa...@gmail.com wrote:
I observed that solve behaves inconsistently in the following regards:
sage: solve([x==1,x==-1],x)
[]
(this is as expected)
However:
solve([x==1,x==-1],x, solution_dict=True)
produces an error message. Easy to live with,
On 13 okt, 03:39, kcrisman kcris...@gmail.com wrote:
On Oct 12, 6:37 pm, Robert Samal robert.sa...@gmail.com wrote:
I observed that solve behaves inconsistently in the following regards:
sage: solve([x==1,x==-1],x)
[]
(this is as expected)
However:
solve([x==1,x==-1],x,
Hello everyone
thanks for the help here.
In Mathematica, Reduce[] works like Solve, except that it returns a
Boolean list of possible solutions. I use it to check what
the necessary conditions for thereal solution to work:
MMA Reduce[a*x == b, {x}]
MMA (b == 0 a == 0) || (a != 0 x ==
Hi!
On 19 Aug., 22:41, robin hankin hankin.ro...@gmail.com wrote:
sagesolve([a*b==15*I-5,a*conjugate(b)==-13*I+9],[a,b])
[]
So, from the first two lines I know that a=2+I, b=1+7I should
be a solution to the system in the third, yet solve() returns empty.
Admittedly I am no expert for
Hello Simon
thanks for this. One problem
with the solution you mention is that I can't do the
general case. What I need is the sage equivalent
of mathematica's Reduce[] function.
Is there one?
rksh
On Thu, Aug 19, 2010 at 10:06 PM, Simon King simon.k...@nuigalway.ie wrote:
Hi!
On 19
On Aug 19, 5:39 pm, robin hankin hankin.ro...@gmail.com wrote:
Hello Simon
thanks for this. One problem
with the solution you mention is that I can't do the
general case. What I need is the sage equivalent
of mathematica's Reduce[] function.
I think that solve() is the closest that
Gak! I found it a work around: find_root() seems fine. Sorry for the
interruption!
On Apr 16, 10:47 am, Owen o...@backspaces.net wrote:
I'm solving recurrence relations for a k-SAT algorithm, and have run
up against an apparent limit in solve. I'm running:
solutions = solve([x^3 - x^2 - x -
On Fri, Apr 16, 2010 at 9:57 AM, Owen o...@backspaces.net wrote:
Is there another method approach I could take? I'd like to reach 6 at
least. My homework depends on it! :)
There's also the to_poly_solve argument to solve which cause non-exact
answers to be returned:
sage: solve([x^5 - x^4 -
You can also use find_root:
sage: h1 = var('h1')
sage: eq = (6000*(h1/2)/(((1/12)*0.1125*(h1^3)) -
((1/12)*(0.1125-0.012)*((h1-(2*0.012))^3 == 8928880.28799800
sage: eq.find_root(-1.2, -0.8)
-0.96594148395195312
sage: eq.find_root(-0.8, 0.2)
0.00033054212748907948
sage: eq.find_root(.2, 1)
The problem related to conversion of h1into maxima has been reported
at
http://trac.sagemath.org/sage_trac/ticket/8634
Robert
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more
Try to_poly_solve=True
sage: h1=var('h1')
sage: solve ([(6000*(h1/2)/(((1/12)*0.1125*(h1^3)) -
((1/12)*(0.1125-0.012)*((h1-(2*0.012))^3 == 8928880.28799800],
h1,to_poly_solve=True)
[x^k*binomial(n, k) == -0.965941485371, x^k*binomial(n, k) ==
0.000330542127524, x^k*binomial(n, k) ==
On Mar 1, 3:02 am, Alex Ghitza aghi...@gmail.com wrote:
On Sun, 28 Feb 2010 23:02:08 -0800 (PST), Sharpie ch...@sharpsteen.net
wrote:
However, tonight I have been trying to solve an open channel flow
problem which requires me to find the roots of:
y^3 - 1.39027132807289 * y^2 +
On Tue, 2 Mar 2010 05:27:45 -0800 (PST), Sharpie ch...@sharpsteen.net wrote:
Thanks for the reply Alex. I think I understand that by choosing a
variable of the appropriate type, in this case one that is restricted
to the real numbers, the roots can be determined in a straight-forward
manner.
On Mar 2, 2:34 pm, Alex Ghitza aghi...@gmail.com wrote:
The way I see it, it is not actually a question about the variable
representing a real number; it is more a question of using polynomials
and their specialised built-in roots() method rather than symbolic
functions and the general-purpose
On Mar 2, 8:10 pm, Sharpie ch...@sharpsteen.net wrote:
So I guess at this point my question is: is there another way to
convert from a symbolic polynomial equation to a Polynomial Ring? I
The methods I used feel very hacky and I don't trust them.
Ok, so I think I found something in the manual
Should we create a ticket for this ? I'd have done it if not for my
doubt on the section I should pick for this... :-)
Nathann
On Feb 10, 1:42 pm, Harald Schilly harald.schi...@gmail.com wrote:
On Feb 10, 11:16 am, Simon King simon.k...@nuigalway.ie wrote:
sage: f = y(n+2) - y(n+1) - y(n)
On Feb 10, 9:54 am, Nathann Cohen nathann.co...@gmail.com wrote:
I just learnt about the rsolve function from Maple, which seems to
give the formula of sequences defined by recurrence.. Is there a
similar function in Sage ?
sympy has rsolve
For example, how could I have Sage give me the
sage: f = y(n+2) - y(n+1) - y(n)
sage: rsolve(f, y(n), { y(0):1, y(1):1 })
(1/2 + 5**(1/2)/2)**n/2 + (1/2 - 5**(1/2)/2)**n/2 - 5**(1/2)*(1/2 -
5**(1/2)/2)**n/10 + 5**(1/2)*(1/2 + 5**(1/2)/2)**n/10
That's perfect !! Thank you very much !! :-)
Their interface is a bit clumsy though, I admit... It
On Feb 10, 9:55 am, Harald Schilly harald.schi...@gmail.com wrote:
For example, how could I have Sage give me the general formula of
fibonacci's sequence ? :-)
I wasn't able to do that one
Perhaps like that:
sage: from sympy import *
sage: y = Function('y')
sage: n =
Hi Nathann!
Your were faster than I ... :-)
On Feb 10, 10:13 am, Nathann Cohen nathann.co...@gmail.com wrote:
Their interface is a bit clumsy though, I admit... It could be good to
be able to do it directly in Sage :-)
But how would a better interface look like?
I mean, you define a
Well, for example :
- You need to import simpy to use it
- For this reason, it does not appear in Sage's documentation
- It could be good to be able to define functions and variables as
they usually are in Sage and not through Simpy types
- Only define one function... I'd have enjoyed the ability
Hi Nathann,
On Wed, Feb 10, 2010 at 9:25 PM, Nathann Cohen nathann.co...@gmail.com wrote:
Well, for example :
- You need to import simpy to use it
One either directly import the functionalities of a third-party
package, or have them imported automatically at Sage startup. But
consider for a
On Feb 10, 11:16 am, Simon King simon.k...@nuigalway.ie wrote:
sage: f = y(n+2) - y(n+1) - y(n)
ahh ... ok. now i get it ^^
When I look into sympy/solvers/recurr.py right the first thing rsolve
does is to compute lhs - rhs. So, f = y(n) == y(n-1) - y(n-2) *should*
work. But it doesn't, because
I mentionned having to import simpy.*, which included classes like
Symbol or Function, and having to use those types. I wouldn't
personally mind if I had to import rsolve from some Sage class... Why
should it necessarily imported by default (namespace kept clean)?
Nathann
--
To post to this
Regarding namespace pollution. Mathematica has thousands of function
names in it's global namespace but it never causes programmers a
problem because they have a convention. All mathematica functions
start with a capital: Integrate, Plot, ListPlot etc. So, stick to
lower case variables and you
1 - 100 of 137 matches
Mail list logo