Thank you for all the help.
With your input, I managed to do what I wanted in Sage, and
can now finish my paper before the deadline:)

regards,
Geir Egeland
phone +47 906 40 507
email: [EMAIL PROTECTED]
PhD Candidate
University of Stavanger
and
Research Scientist
Telenor R&I




On 30 Aug 2008, at 02:44, William Stein wrote:

>
> On Fri, Aug 29, 2008 at 5:12 PM, Simon King <[EMAIL PROTECTED] 
> > wrote:
>>
>> Hi Geir,
>>
>> If you really want to use strings, it may work like that:
>> sage: var('x y')
>> (x, y)
>> sage: EqL=['y==x**%d-%d'%(i,i) for i in range(10)]
>> sage: for X in EqL:
>> ....:     print X
>> ....:     print solve(eval(X))
>
> Use sage_eval instead of eval, unless you want to
> confusing results:
>
> sage: eval('2/3')
> 0
> sage: eval('2^3')
> 1
>
>
>
>
>> ....:
>> y==x**0-0
>> [
>>                                    y == 1
>> ]
>> y==x**1-1
>> [
>>                                  x == y + 1
>> ]
>> y==x**2-2
>> [
>>                              x == - sqrt(y + 2),
>>                               x == sqrt(y + 2)
>> ]
>>
>> etc...
>>
>> Note that double-= yields an equation (not a boolean!) if symbolic
>> expressions such as x and y are involved. A single "=" is an
>> assignment.
>>
>> Cheers
>>   Simon
>>
>>>
>>
>
>
>
> -- 
> William Stein
> Associate Professor of Mathematics
> University of Washington
> http://wstein.org
>
> >


--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-support@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-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to