Hi, 

I've also noticed two days ago that https://sagecell.sagemath.org/ is very 
slow (actually does not terminate) even on elementary operations. 
Maybe there is a problem with the server at the moment...

Eric. 

Le mardi 28 novembre 2023 à 16:36:30 UTC+1, Fernando Q. Gouvea a écrit :

> Yesterday I was demonstrating to my calculus class Sage's ability to 
> implement the method of Lagrange multipliers. I used a standard example, 
> putting the following code into SageMath Cell:
>
> var('x,y,l')
> f(x,y)=10*x^(1/3)*y^(2/3)
> g(x,y)=5*x-6*y
> fx=diff(f,x)
> fy=diff(f,y)
> gx=diff(g,x)
> gy=diff(g,y)
> solve((fx(x,y)==l*gx(x,y),fy(x,y)==l*gy(x,y),g(x,y)==120),(x,y,l))
>
> That works beautifully. Then I decided to show off Sage's powers by 
> making a little change:
>
> var('x,y,l')
> f(x,y)=10*x^(1/3)*y^(2/3)
> g(x,y)=5*x^2+6*y
> fx=diff(f,x)
> fy=diff(f,y)
> gx=diff(g,x)
> gy=diff(g,y)
> solve((fx(x,y)==l*gx(x,y),fy(x,y)==l*gy(x,y),g(x,y)==120),(x,y,l))
>
> SageCell now gives me a spinning symbol ("I'm working") for a while, 
> then seems to exit without any result. On my local installation (Sage 
> 9.2 on Windows) it returns an empty list, [].
>
> What is curious is that the constraint equation 5x^2 + 6y=120 is easily 
> solved for y...
>
> Questions:
>
> 1) Shouldn't SageCell output an empty list here?
>
> 2) Is this a known limitation of "solve"?
>
> Fernando
>
> PS: It seems that if I add "algorithm='sympy'" then solutions are found.
>
> -- 
> ==================================================================
> Fernando Q. Gouvea
> Carter Professor of Mathematics
> Colby College
> Mayflower Hill 5836
> Waterville, ME 04901 
> fqgo...@colby.edu http://www.colby.edu/~fqgouvea
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/8f554c04-42d9-4765-bd3a-a82bd2758bddn%40googlegroups.com.

Reply via email to