Thanks, but this does not help in this case:
----------------------------------------------------------------------
| Sage Version 4.0.2, Release Date: 2009-06-18                       |
| Type notebook() for the GUI, and license() for information.        |
----------------------------------------------------------------------
sage: var('x y n')
(x, y, n)
sage: assume(n,'real')
sage: solve(y == x^n,x)
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
...
TypeError: Computation failed since Maxima requested additional 
constraints (try the command 'assume(>0)' before integral or limit 
evaluation, for example):
Is n an integer?

This even happens in maxima. No matter what I assume for n, it is still 
possible that it is an integer, so maxima keeps asking. Only if I assume 
that it is indeed an integer, it will evaluate, but this assumption is 
wrong as n does not need to be an integer. So the assume() method allows 
passing the answer 'yes', but not the answer 'no' in this case.

Stan

Kjetil Halvorsen wrote:
> On Fri, Jun 26, 2009 at 07:11, Stan Schymanski<[email protected]> wrote:
>   
>> Update:
>> In maxima, I simply have to answer 'no' to the question whether n is an
>> integer and I obtain the solution. How can I pass the 'no' to maxima
>> through sage??
>>
>>     
>
> Try to use assume() befotre the call to maxima?
>
>   
>> Stan
>>
>> Stan Schymanski wrote:
>>     
>>> Dear all,
>>>
>>> How can I get sage to solve a simple equation such as the one below?
>>>
>>> ----------------------------------------------------------------------
>>> | Sage Version 4.0.2, Release Date: 2009-06-18                       |
>>> | Type notebook() for the GUI, and license() for information.        |
>>> ----------------------------------------------------------------------
>>> sage: var('x y n')
>>> (x, y, n)
>>> sage: solve(y == x^n,x)
>>> ---------------------------------------------------------------------------
>>> TypeError                                 Traceback (most recent call
>>> last)
>>> [...]
>>> TypeError: Computation failed since Maxima requested additional
>>> constraints (try the command 'assume(>0)' before integral or limit
>>> evaluation, for example):
>>> Is n an integer?
>>>
>>> MMA solves similar equation using inverse functions and spits out a
>>> warning, no matter whether n is an integer or not. I thought that
>>> Maxima would do the same as stated in the docu.
>>>
>>> Here is an excerpt from the Maxima 5_15 docu:
>>>
>>> "Let E be the expression and X be the variable. If E is linear in X
>>> then it is trivially solved for X. Otherwise if E is of the form A*X^N
>>> + B then the result is (-B/A)^1/N) times the N'th roots of unity."
>>>
>>> Is this a problem with the sage->maxima interface? I also wanted to
>>> try Sympy as suggested in another post, but Sympy does not seem to be
>>> included in the new version of sage any more. Am I misunderstanding
>>> something?
>>>
>>> Thanks for your help!
>>>
>>> Stan
>>>
>>>       
>> --
>> ________________________________________
>>
>> Stan Schymanski
>> Scientist
>> Max Planck Institute for Biogeochemistry
>> Postfach 10 01 64
>> D-07701 Jena
>>
>> Phone: +49.3641.576264
>> Fax: +49.3641.577274
>> WWW: http://www.bgc-jena.mpg.de/~sschym
>>
>> Biospheric Theory and Modelling Group
>> http://www.bgc-jena.mpg.de/bgc-theory/
>> _________________________________________
>>
>>
>>     
>
>
>
>   

-- 
________________________________________

Stan Schymanski
Scientist
Max Planck Institute for Biogeochemistry
Postfach 10 01 64
D-07701 Jena

Phone: +49.3641.576264
Fax: +49.3641.577274
WWW: http://www.bgc-jena.mpg.de/~sschym

Biospheric Theory and Modelling Group
http://www.bgc-jena.mpg.de/bgc-theory/
_________________________________________


--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to