[sage-support] Re: Warnings from JsMath

2008-01-24 Thread bill purvis

On Friday 25 January 2008, William Stein wrote:
> On Jan 24, 2008 8:52 PM, Timothy Clemans <[EMAIL PROTECTED]> wrote:
> > In the first versions of the Sage Notebook that message was actually
> > hidden.
>
> (1) If one wants to disable the font message, comment out (with /* */) line
> 253 of SAGE_ROOT/devel/sage/sage/server/notebook/js.py and do "sage -br":
>
> /* jsMath = {Font: {Message: function () {}}} */
>
> I do not think this should be the default in Sage.  However, a nicer error
> message would be good, which provides a link to a _local_ download page
> for the jsmath fonts, which is much easier to understand and follow than
> the official jsmath page.
>
> (2) Any typesetting in the notebook basically looks like crap without the
> jsmath fonts, so it would be bad to encourage people to completely remove
> the warning message.
>
> (3) The fonts are tiny (120KB) and fairly easy to install:
>
> http://www.math.union.edu/~dpvc/jsmath/download/jsMath-fonts.html
>
>  -- William
>
The fonts I downloaded are 80Mb!

And where should they be installed? I can't work out where the
notebook server expects to find them.

I thought they were included as part of the Sage distribution, anyway?

Bill
-- 
+---+
| Bill Purvis, Amateur Mathematician|
|  email: [EMAIL PROTECTED]  |
|  http://bil.members.beeb.net  |
+---+

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Warnings from JsMath

2008-01-24 Thread William Stein

On Jan 24, 2008 8:52 PM, Timothy Clemans <[EMAIL PROTECTED]> wrote:
>
> In the first versions of the Sage Notebook that message was actually
> hidden.

(1) If one wants to disable the font message, comment out (with /* */) line 253
of SAGE_ROOT/devel/sage/sage/server/notebook/js.py and do "sage -br":

/* jsMath = {Font: {Message: function () {}}} */

I do not think this should be the default in Sage.  However, a nicer error
message would be good, which provides a link to a _local_ download page
for the jsmath fonts, which is much easier to understand and follow than
the official jsmath page.

(2) Any typesetting in the notebook basically looks like crap without the jsmath
fonts, so it would be bad to encourage people to completely remove the warning
message.

(3) The fonts are tiny (120KB) and fairly easy to install:

http://www.math.union.edu/~dpvc/jsmath/download/jsMath-fonts.html

 -- William

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Warnings from JsMath

2008-01-24 Thread Timothy Clemans

In the first versions of the Sage Notebook that message was actually
hidden.

On Jan 24, 4:50 pm, BFJ <[EMAIL PROTECTED]> wrote:
> The control panel is the little tab at the bottom of the browser
> output which reads "jsMath". Just click there and follow the links.
>
> I agree about the warning. It might be better as a browser alert, or
> maybe an embedded popup. On the other hand, this may be part of jsMath
> and not something which can be addressed in Sage without modifying
> jsMath, I don't know.
>
> -BFJ
>
> On Jan 24, 4:56 pm, "bill.p" <[EMAIL PROTECTED]> wrote:
>
> > I find the warning messages that appear at the top of the notebook
> > saying
> > that JsMath isn't available annoying. There's an awful lot of disk
> > space full
> > of the JsMath stuff so it's definitely there. I find it especially
> > annoying when I
> > try to print something - I get a big red box at the top of my output
> > saying:
>
> > To print higher resolution math symbols, click the
> > Hi_Res Fonts for Printing button on the jsMath control panel.
>
> > What control panel?
> > If you have to issue a warning, it should be on the 'print' window,
> > before you
> > commit to paper. Having seen the message, if you go ahead, it should
> > not
> > appear on the paper!
>
> > Bill
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: old SAGE link at MSRI

2008-01-24 Thread Mike Hansen

I will ask people in the computing department tomorrow.

--Mike

On Jan 24, 2008 5:15 PM, David Joyner <[EMAIL PROTECTED]> wrote:
>
> Hi:
> Just curious if there a way to update the SAGE link at
> http://www.msri.org/about/computing/mathdocs
> - David Joyner
>
> >
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] old SAGE link at MSRI

2008-01-24 Thread David Joyner

Hi:
Just curious if there a way to update the SAGE link at
http://www.msri.org/about/computing/mathdocs
- David Joyner

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Warnings from JsMath

2008-01-24 Thread BFJ

The control panel is the little tab at the bottom of the browser
output which reads "jsMath". Just click there and follow the links.

I agree about the warning. It might be better as a browser alert, or
maybe an embedded popup. On the other hand, this may be part of jsMath
and not something which can be addressed in Sage without modifying
jsMath, I don't know.

-BFJ

On Jan 24, 4:56 pm, "bill.p" <[EMAIL PROTECTED]> wrote:
> I find the warning messages that appear at the top of the notebook
> saying
> that JsMath isn't available annoying. There's an awful lot of disk
> space full
> of the JsMath stuff so it's definitely there. I find it especially
> annoying when I
> try to print something - I get a big red box at the top of my output
> saying:
>
> To print higher resolution math symbols, click the
> Hi_Res Fonts for Printing button on the jsMath control panel.
>
> What control panel?
> If you have to issue a warning, it should be on the 'print' window,
> before you
> commit to paper. Having seen the message, if you go ahead, it should
> not
> appear on the paper!
>
> Bill
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Warnings from JsMath

2008-01-24 Thread bill.p

I find the warning messages that appear at the top of the notebook
saying
that JsMath isn't available annoying. There's an awful lot of disk
space full
of the JsMath stuff so it's definitely there. I find it especially
annoying when I
try to print something - I get a big red box at the top of my output
saying:

To print higher resolution math symbols, click the
Hi_Res Fonts for Printing button on the jsMath control panel.

What control panel?
If you have to issue a warning, it should be on the 'print' window,
before you
commit to paper. Having seen the message, if you go ahead, it should
not
appear on the paper!

Bill
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: printing long lines from notebook

2008-01-24 Thread bill purvis

On Thursday 24 January 2008, William Stein wrote:
> On Jan 24, 2008 9:33 AM, bill.p <[EMAIL PROTECTED]> wrote:
> > I have some longish expressions in my notebook.
> > When I try to print them out they get truncated.
>
> Truncated or word wrapped?   If word wrapped, if you click to the left of
> the output, it will toggle between "show", "word wrap off", "hide".  The
> state for individual cells should be remembered.   There is currently no
> global feature to turn off word wrap altogether in the notebook, but there
> should be, since I wanted just that feature myself this morning when doing
> some calculations.   I'll put it in trac:
>
> http://trac.sagemath.org/sage_trac/ticket/1916
>
> > Is there a convention for splitting lines so that they will be treated
> > as
> > a single logical line so that I can make them fit into the paper
> > width?
It's not very clear. There's no visible indication that word wrap is on or
off - at least it took me a while to figure it out. It's not obvious 
looking at a printout what is going on. If the wrapped bits were indented
a little or there was some mark in the margin it would be clearer.
I hadn't seen the option to click in the left of the output area,
except when an error occurs and it explicitly suggests that to get
a trace-back.

Thanks for the info.

Bill


-- 
+---+
| Bill Purvis, Amateur Mathematician|
|  email: [EMAIL PROTECTED]  |
|  http://bil.members.beeb.net  |
+---+

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: printing long lines from notebook

2008-01-24 Thread William Stein

On Jan 24, 2008 9:33 AM, bill.p <[EMAIL PROTECTED]> wrote:
>
> I have some longish expressions in my notebook.
> When I try to print them out they get truncated.

Truncated or word wrapped?   If word wrapped, if you click to the left of the
output, it will toggle between "show", "word wrap off", "hide".  The state
for individual cells should be remembered.   There is currently no global
feature to turn off word wrap altogether in the notebook, but there should
be, since I wanted just that feature myself this morning when doing some
calculations.   I'll put it in trac:

http://trac.sagemath.org/sage_trac/ticket/1916

> Is there a convention for splitting lines so that they will be treated
> as
> a single logical line so that I can make them fit into the paper
> width?
>
> >
>



-- 
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
-~--~~~~--~~--~--~---



[sage-support] Re: Sage 2.10 released!

2008-01-24 Thread Kate

William,

This works.  Thanks!

Kate

On Jan 24, 2:46 pm, "William Stein" <[EMAIL PROTECTED]> wrote:
> On Jan 24, 2008 11:31 AM, Kate <[EMAIL PROTECTED]> wrote:
>
>
>
> > Michael,
>
> > Unfortunately your patch for #1898 does not work.
> > (Note that this was tried on 2.10, not 2.10.1.alpha*)
>
> I've posted a part 2 to that patch (against 2.10).  Please give it a try:
>http://trac.sagemath.org/sage_trac/ticket/1898
>
>
>
>
>
> > sage -t  devel/sage-main/sage/rings/polynomial/polynomial_element.pyx
> > **
> > File "polynomial_element.pyx", line 2669:
> > sage: p.roots(ring=CIF)
> > Expected:
> > [([-1.4142135623730952 .. -1.4142135623730949], 1),
> > ([1.4142135623730949 .. 1.4142135623730952], 1),
> > ([-1.214638932244182... ..  -1.2146389322441821] -
> > [0.1414250525823937... .. 0.1414250525823939...]*I, 2),
> > ([-0.141425052582393... .. -0.1414250525823937...] +
> > [1.2146389322441821 ..  1.214638932244182...]*I, 2),
> > ([0.141425052582393... .. 0.141425052582393...] -
> > [1.2146389322441821 .. 1.2146389322441827]*I, 2),
> > ([1.2146389322441821 ..  1.2146389322441827] + [0.14142505258239376 ..
> > 0.14142505258239399]*I, 2)]
> > Got:
> > [([-1.4142135623730952 .. -1.4142135623730949], 1),
> > ([1.4142135623730949 .. 1.4142135623730952], 1),
> > ([-1.2146389322441827 .. -1.2146389322441821] -
> > [0.14142505258239371 .. 0.14142505258239397]*I, 2),
> > ([-0.14142505258239397 .. -0.14142505258239376] +
> > [1.2146389322441821 .. 1.2146389322441829]*I, 2),
> > ([0.14142505258239373 .. 0.14142505258239394] - [1.2146389322441821 ..
> > 1.2146389322441829]*I, 2), ([1.2146389322441821 .. 1.2146389322441827]
> > + [0.14142505258239376 .. 0.14142505258239399]*I, 2)]
> > **
>
> > Kate
>
> > On Jan 23, 7:26 pm, mabshoff <[EMAIL PROTECTED]
>
> > dortmund.de> wrote:
> > > On Jan 23, 10:15 pm, mabshoff <[EMAIL PROTECTED]
>
> > > dortmund.de> wrote:
> > > > On Jan 23, 10:04 pm, Kate <[EMAIL PROTECTED]> wrote:
>
> > > 
>
> > > > Hi Kate,
>
> > > > this is now #1898. You can expect a patch for this in the next hour or
> > > > two.
>
> > > > Cheers,
>
> > > > Michael
>
> > > Hi Kate,
>
> > > there is now a patch up at #1898. Could you please test and report if
> > > it works for you?
>
> > > Cheers,
>
> > > Michael
>
> --
> William Stein
> Associate Professor of Mathematics
> University of Washingtonhttp://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
-~--~~~~--~~--~--~---



[sage-support] Re: Sage 2.10 released!

2008-01-24 Thread William Stein

On Jan 24, 2008 11:31 AM, Kate <[EMAIL PROTECTED]> wrote:
>
> Michael,
>
> Unfortunately your patch for #1898 does not work.
> (Note that this was tried on 2.10, not 2.10.1.alpha*)

I've posted a part 2 to that patch (against 2.10).  Please give it a try:
http://trac.sagemath.org/sage_trac/ticket/1898

>
> sage -t  devel/sage-main/sage/rings/polynomial/polynomial_element.pyx
> **
> File "polynomial_element.pyx", line 2669:
> sage: p.roots(ring=CIF)
> Expected:
> [([-1.4142135623730952 .. -1.4142135623730949], 1),
> ([1.4142135623730949 .. 1.4142135623730952], 1),
> ([-1.214638932244182... ..  -1.2146389322441821] -
> [0.1414250525823937... .. 0.1414250525823939...]*I, 2),
> ([-0.141425052582393... .. -0.1414250525823937...] +
> [1.2146389322441821 ..  1.214638932244182...]*I, 2),
> ([0.141425052582393... .. 0.141425052582393...] -
> [1.2146389322441821 .. 1.2146389322441827]*I, 2),
> ([1.2146389322441821 ..  1.2146389322441827] + [0.14142505258239376 ..
> 0.14142505258239399]*I, 2)]
> Got:
> [([-1.4142135623730952 .. -1.4142135623730949], 1),
> ([1.4142135623730949 .. 1.4142135623730952], 1),
> ([-1.2146389322441827 .. -1.2146389322441821] -
> [0.14142505258239371 .. 0.14142505258239397]*I, 2),
> ([-0.14142505258239397 .. -0.14142505258239376] +
> [1.2146389322441821 .. 1.2146389322441829]*I, 2),
> ([0.14142505258239373 .. 0.14142505258239394] - [1.2146389322441821 ..
> 1.2146389322441829]*I, 2), ([1.2146389322441821 .. 1.2146389322441827]
> + [0.14142505258239376 .. 0.14142505258239399]*I, 2)]
> **
>
> Kate
>
> On Jan 23, 7:26 pm, mabshoff <[EMAIL PROTECTED]
>
> dortmund.de> wrote:
> > On Jan 23, 10:15 pm, mabshoff <[EMAIL PROTECTED]
> >
> > dortmund.de> wrote:
> > > On Jan 23, 10:04 pm, Kate <[EMAIL PROTECTED]> wrote:
> >
> > 
> >
> > > Hi Kate,
> >
> > > this is now #1898. You can expect a patch for this in the next hour or
> > > two.
> >
> > > Cheers,
> >
> > > Michael
> >
> > Hi Kate,
> >
> > there is now a patch up at #1898. Could you please test and report if
> > it works for you?
> >
> > Cheers,
> >
> > Michael
> >
>



-- 
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
-~--~~~~--~~--~--~---



[sage-support] Re: Sage 2.10 released!

2008-01-24 Thread Kate

Michael,

Unfortunately your patch for #1898 does not work.
(Note that this was tried on 2.10, not 2.10.1.alpha*)

sage -t  devel/sage-main/sage/rings/polynomial/polynomial_element.pyx
**
File "polynomial_element.pyx", line 2669:
sage: p.roots(ring=CIF)
Expected:
[([-1.4142135623730952 .. -1.4142135623730949], 1),
([1.4142135623730949 .. 1.4142135623730952], 1),
([-1.214638932244182... ..  -1.2146389322441821] -
[0.1414250525823937... .. 0.1414250525823939...]*I, 2),
([-0.141425052582393... .. -0.1414250525823937...] +
[1.2146389322441821 ..  1.214638932244182...]*I, 2),
([0.141425052582393... .. 0.141425052582393...] -
[1.2146389322441821 .. 1.2146389322441827]*I, 2),
([1.2146389322441821 ..  1.2146389322441827] + [0.14142505258239376 ..
0.14142505258239399]*I, 2)]
Got:
[([-1.4142135623730952 .. -1.4142135623730949], 1),
([1.4142135623730949 .. 1.4142135623730952], 1),
([-1.2146389322441827 .. -1.2146389322441821] -
[0.14142505258239371 .. 0.14142505258239397]*I, 2),
([-0.14142505258239397 .. -0.14142505258239376] +
[1.2146389322441821 .. 1.2146389322441829]*I, 2),
([0.14142505258239373 .. 0.14142505258239394] - [1.2146389322441821 ..
1.2146389322441829]*I, 2), ([1.2146389322441821 .. 1.2146389322441827]
+ [0.14142505258239376 .. 0.14142505258239399]*I, 2)]
**

Kate

On Jan 23, 7:26 pm, mabshoff <[EMAIL PROTECTED]
dortmund.de> wrote:
> On Jan 23, 10:15 pm, mabshoff <[EMAIL PROTECTED]
>
> dortmund.de> wrote:
> > On Jan 23, 10:04 pm, Kate <[EMAIL PROTECTED]> wrote:
>
> 
>
> > Hi Kate,
>
> > this is now #1898. You can expect a patch for this in the next hour or
> > two.
>
> > Cheers,
>
> > Michael
>
> Hi Kate,
>
> there is now a patch up at #1898. Could you please test and report if
> it works for you?
>
> Cheers,
>
> Michael
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: sage on disk

2008-01-24 Thread William Stein

On Jan 24, 2008 10:05 AM, Ted Kosan <[EMAIL PROTECTED]> wrote:
>
> William wrote:
>
> > > I finally figured out how to get 7zip to unzip
> > > sage-vmware and that produced a folder with jillions files.The 
> > > instructions
> > > in the readme file (included below) say to click on sage.vmx.  This file 
> > > is
> > > NOT in the folder.  So I clicked on every folder until I finally found the
> > > one that works.   It is called simply sage (Vmware configuration file) in 
> > > my
> > > machine.  There is no ,vmx extension on the file name.  I recall that this
> > > fooled William when he was installing sage on my office pc.  You might 
> > > want
> > > to change the instructions in the readme file.
> >
> > Is Windows hiding filename extensions? The fact that it said (Vmware
> > configuration file) seems to indicate that the extension was there,
> > but Windows wasn't showing it to you...
>
> My thought here is to rename sage.vmx to sage_vmx.vmx. Windows hides
> file extensions by default and so 95% of Windows users are going to
> have difficulties locating the vmx file.
>

Wow, that's an extremely good idea.  I'm testing it right now, and will do it if
it works.  Thanks!
[...] Yep it works fine.

William

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Putting parentheses around -1.

2008-01-24 Thread William Stein

On Jan 24, 2008 10:03 AM, Carl Witty <[EMAIL PROTECTED]> wrote:
>
> On Jan 23, 11:41 pm, Paul Zimmermann <[EMAIL PROTECTED]> wrote:
> > Thus you have constructed a nice expression for 1:
> >
> > sage: sol[2].subs(a=1).right()
> > (2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) + 10/27)^(1/3)) + 1/3
> >
> > Quiz: how to simplify that expression to 1 within SAGE? I've tried simplify,
> > and radical_simplify, but neither succeeds...
>
> The Sage rings AA and QQbar can decide equalities between radical
> expressions (over the reals and complex numbers respectively):
>
> sage: a = AA((2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) +
> 10/27)^(1/3)) + 1/3)
> sage: a
> [0.99988 .. 1.0003]
> sage: a == 1
> True
>
> By the way, when I implemented AA/QQbar, I decided on the following
> behavior for exponentiation:
>
> sage: AA(-1)^(1/3)
> -1
> sage: QQbar(-1)^(1/3)
> [0.49994 .. 0.50012] + [0.86602540378443859 ..
> 0.86602540378443871]*I
>
> So when taking roots, for AA we prefer real roots if they exist, but
> for QQbar we take the principal root.

Wow!  That's all very impressive actually.   It would be great if you
could add the above examples to the tutorials for AA and QQbar (i.e.,
the tops of the relevant code files).   Nice.

 -- William

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: sage on disk

2008-01-24 Thread Ted Kosan

William wrote:

> > I finally figured out how to get 7zip to unzip
> > sage-vmware and that produced a folder with jillions files.The instructions
> > in the readme file (included below) say to click on sage.vmx.  This file is
> > NOT in the folder.  So I clicked on every folder until I finally found the
> > one that works.   It is called simply sage (Vmware configuration file) in my
> > machine.  There is no ,vmx extension on the file name.  I recall that this
> > fooled William when he was installing sage on my office pc.  You might want
> > to change the instructions in the readme file.
>
> Is Windows hiding filename extensions? The fact that it said (Vmware
> configuration file) seems to indicate that the extension was there,
> but Windows wasn't showing it to you...

My thought here is to rename sage.vmx to sage_vmx.vmx. Windows hides
file extensions by default and so 95% of Windows users are going to
have difficulties locating the vmx file.

Ted

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Putting parentheses around -1.

2008-01-24 Thread Carl Witty

On Jan 23, 11:41 pm, Paul Zimmermann <[EMAIL PROTECTED]> wrote:
> Thus you have constructed a nice expression for 1:
>
> sage: sol[2].subs(a=1).right()
> (2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) + 10/27)^(1/3)) + 1/3
>
> Quiz: how to simplify that expression to 1 within SAGE? I've tried simplify,
> and radical_simplify, but neither succeeds...

The Sage rings AA and QQbar can decide equalities between radical
expressions (over the reals and complex numbers respectively):

sage: a = AA((2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) +
10/27)^(1/3)) + 1/3)
sage: a
[0.99988 .. 1.0003]
sage: a == 1
True

By the way, when I implemented AA/QQbar, I decided on the following
behavior for exponentiation:

sage: AA(-1)^(1/3)
-1
sage: QQbar(-1)^(1/3)
[0.49994 .. 0.50012] + [0.86602540378443859 ..
0.86602540378443871]*I

So when taking roots, for AA we prefer real roots if they exist, but
for QQbar we take the principal root.

Carl Witty

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] printing long lines from notebook

2008-01-24 Thread bill.p

I have some longish expressions in my notebook.
When I try to print them out they get truncated.
Is there a convention for splitting lines so that they will be treated
as
a single logical line so that I can make them fit into the paper
width?

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Trying to plot symbolic algebra

2008-01-24 Thread bill.p

Thanks, Harald. That worked just right!
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: sage on disk

2008-01-24 Thread William Stein

On Jan 24, 2008 8:51 AM, Robert Miller <[EMAIL PROTECTED]> wrote:
>
> > I have sage running now on my windows-based laptop, but not without some
> > difficulty.  Even so, it was faster than my internet download attempts
> > earlier.  Here are a few comments.  The disk includes a program called 7zip
> > used to unpack the file sage-vmware-2.10.7z.  My first attempts to do this
> > failed even though I had installed (successfully) 7zip and it was listed in
> > my program files. Windows still couldn't find it.  Finally I clicked on 7zip
> > itself and then 7zip couldn't find sage-vmware-2.10.7z even though it was
> > sitting on my desktop.
>
> This sounds a lot like the one and only time I tried to use Windows
> Vista- it was pretending to do one thing, and really doing another! A
> very undesirable feature in an operating system...
>
> > I finally figured out how to get 7zip to unzip
> > sage-vmware and that produced a folder with jillions files.The instructions
> > in the readme file (included below) say to click on sage.vmx.  This file is
> > NOT in the folder.  So I clicked on every folder until I finally found the
> > one that works.   It is called simply sage (Vmware configuration file) in my
> > machine.  There is no ,vmx extension on the file name.  I recall that this
> > fooled William when he was installing sage on my office pc.  You might want
> > to change the instructions in the readme file.
>
> Is Windows hiding filename extensions? The fact that it said (Vmware
> configuration file) seems to indicate that the extension was there,
> but Windows wasn't showing it to you...

Definitely the extension is there.  It's just that windows hides it.

> >  Another question: To use the notebook feature I need to copy an address
> > into Firefox.  I can't figure out how to copy this address, so I end up
> > typing it in.  Is there a better way?
>
> I can't answer this one...

No.  You have to type it in.

>
> > But now everything seems fine.  By the way how to I download upgrades when
> > they become available.  Do I have to download the whole package again?
>
> My guess is that because of the following issue, you can't upgrade a
> vmware installation of Sage yet:
>
> http://trac.sagemath.org/sage_trac/ticket/1193
>
> I hope I'm wrong...
>

You are wrong.  I always make the new versions of he sage-vmware image
by simply upgrading from previous versions.
I have no clue what #1193 is about.  VERY likely it's just a permissions error.

> >   
> >
> > 1. Download sage-vmware-2.10.7z
> > 2. Extract it anywhere you want using 7zip (http://www.7-zip.org):
> >(This will .take about 15 minutes
> >despite anything Windows tells you.  Do *not* stop the
> >extract halfway through and think SAGE will still work.)
> > 3. Make sure you have installed the free VMware program:
> >http://www.vmware.com/products/player/
> > 4. Double click on sage.vmx in the sage-vmware-2.10
> >directory to run SAGE.
>
>
>
> --
> Robert L. Miller
> http://www.rlmiller.org/
> Department of Mathematics
> University of Washington, Seattle
>
> >
>



-- 
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
-~--~~~~--~~--~--~---



[sage-support] Re: sage on disk

2008-01-24 Thread Robert Miller

> I have sage running now on my windows-based laptop, but not without some
> difficulty.  Even so, it was faster than my internet download attempts
> earlier.  Here are a few comments.  The disk includes a program called 7zip
> used to unpack the file sage-vmware-2.10.7z.  My first attempts to do this
> failed even though I had installed (successfully) 7zip and it was listed in
> my program files. Windows still couldn't find it.  Finally I clicked on 7zip
> itself and then 7zip couldn't find sage-vmware-2.10.7z even though it was
> sitting on my desktop.

This sounds a lot like the one and only time I tried to use Windows
Vista- it was pretending to do one thing, and really doing another! A
very undesirable feature in an operating system...

> I finally figured out how to get 7zip to unzip
> sage-vmware and that produced a folder with jillions files.The instructions
> in the readme file (included below) say to click on sage.vmx.  This file is
> NOT in the folder.  So I clicked on every folder until I finally found the
> one that works.   It is called simply sage (Vmware configuration file) in my
> machine.  There is no ,vmx extension on the file name.  I recall that this
> fooled William when he was installing sage on my office pc.  You might want
> to change the instructions in the readme file.

Is Windows hiding filename extensions? The fact that it said (Vmware
configuration file) seems to indicate that the extension was there,
but Windows wasn't showing it to you...

>  Another question: To use the notebook feature I need to copy an address
> into Firefox.  I can't figure out how to copy this address, so I end up
> typing it in.  Is there a better way?

I can't answer this one...

> But now everything seems fine.  By the way how to I download upgrades when
> they become available.  Do I have to download the whole package again?

My guess is that because of the following issue, you can't upgrade a
vmware installation of Sage yet:

http://trac.sagemath.org/sage_trac/ticket/1193

I hope I'm wrong...

>   
>
> 1. Download sage-vmware-2.10.7z
> 2. Extract it anywhere you want using 7zip (http://www.7-zip.org):
>(This will .take about 15 minutes
>despite anything Windows tells you.  Do *not* stop the
>extract halfway through and think SAGE will still work.)
> 3. Make sure you have installed the free VMware program:
>http://www.vmware.com/products/player/
> 4. Double click on sage.vmx in the sage-vmware-2.10
>directory to run SAGE.



-- 
Robert L. Miller
http://www.rlmiller.org/
Department of Mathematics
University of Washington, Seattle

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: graphs(n) behavior under restriction

2008-01-24 Thread Jason Grout

kcrisman wrote:
> 
>> All right, extending Robert's patch, I've posted up trac #1908 at:
>>
>> http://sagetrac.org/sage_trac/ticket/1908
>>
>> This lets you do what you showed above:
>>
>> sage: show([circle((0,0),n) for n in [1..3]]) # three circles
>>
>> (note the extra "]" at the end, though).
>>
>> To plot concentric circles, of course, you use:
>>
>> sage: sum([circle((0,0),n) for n in [1..3]])
>>
>> Also the following are tiled:
>>
>> sage: show(graphs(3), layout='circular', vertex_size=50,
>> vertex_labels=False, graph_border=True)
>> sage: show(list(graphs(3)), layout='circular', vertex_size=50,
>> vertex_labels=False, graph_border=True)
>> sage: show(graphs(4), layout='circular', vertex_size=50,
>> vertex_labels=False, graph_border=True)
>> sage: show([plot(sin(i*x)) for i in range(30)]) # Two pages of images
>> sage: show([sin(i*x) for i in range(2)])
>> sage: show([sin(i*x) for i in range(30)], columns=1, rows=10)
> 
> As someone with not enough time or expertise to contribute this sort
> of truly useful functionality but with LOTS of ideas for making Sage
> better, I humbly thank both Jason and Robert for all this hard work. I
> don't think there could be a much better solution within the Sage/
> Python framework for these issues.  I especially like the contrast
> between
> 
> sage: sum([circle((0,0),n) for n in [1..3]])
> 
> and
> 
> sage: show([circle((0,0),n) for n in [1..3]]) # three circles
> 

Thanks.  I think it turned out well too.  We really, really, *really* 
appreciate your suggestions and feedback.  We need more people to use 
Sage and give feedback or write documentation or write code; whatever 
they are comfortable with or want to learn.  We're also very interested 
in what features Sage needs to be more useful in the classroom and for 
students.  One of the huge advantages we have being open-source is that 
anyone and everyone can contribute in whatever way they can.  In fact, 
that is needed for the project to survive and flourish.  So thank *you* too!



> As a final comment, I'll note that the following behavior with objects
> which automatically display is interesting:
> 
> sage: C=circle((0,0),1);P=plot(sin,0,1)
> sage: [C,P]
> [, ]
> 
> and then a display of circle above a plot of sin (in the notebook) or
> two separate pictures (in the command line).  I have no idea what, if
> any, connection should be made with this work, though.

I think it is just printing out the list for you to see and the "print" 
function for a graphics object displays the object, so you see each 
object "printed" out.

It would be nice if the text display indicated this, instead of "[, ]". 
  Maybe something like "[, ]", since the 
objects actually are there.  It misleadingly looks like you have an 
empty list.

This bug (displaying an apparently empty list, but really there are 
graphic objects in it) is trac #1912.  It should be a very easy fix for 
someone that knows how graphic objects are printed (and someone who 
remembers the difference between repr and string or something like that :).

> 
> Finally, sorry for the typo earlier!  But *that* at least I would
> expect my students to get - otherwise it misses the point of learning
> to use computers. Excel or Firefox would balk at weird syntax too.
> 
> Thank you all, and hope to contribute more suggestions in the future.

Thank you!  Happy Saging, or Sageing, or whatever you would say!

Jason



--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Putting parentheses around -1.

2008-01-24 Thread Jason Grout

kcrisman wrote:
> 
>> Thus you have constructed a nice expression for 1:
>>
>> sage: sol[2].subs(a=1).right()
>> (2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) + 10/27)^(1/3)) + 1/3
>>
>> Quiz: how to simplify that expression to 1 within SAGE? I've tried simplify,
>> and radical_simplify, but neither succeeds...
>>
>> Paul Zimmermann
> 
> Ted, I've been there - running into that sort of "nice" formula with
> Sage in the class, presumably via Maxima.  As cool as it is, it is
> also confusing and disheartening to my students, who have no
> experience to interpret it with.
> 
> More to the point, I would softly plead a different view on
> (-1)^(1/3).  As a mathematician, I think getting the "usual" primitive
> sixth root of unity is wonderful (though perhaps even making that
> choice is suspect, why not its complex conjugate?), but as a pedagogue
> it would cause me to question using Sage in any environment where I
> needed numerical solutions to simple algebraic equations, such as any
> HS class or many (though not all) freshman non-major math courses.
> 
> I definitely want my students to know how to do it by hand - in fact,
> they *should* solve x^3=-1 by hand.  But as Ted points out, getting a
> useful numerical approximation for x^3=-3 by typing (-3)^(1/3) is a
> legitimate need, even for students who aren't ready for complex
> numbers (and such students definitely exist).  And yet,
> 
> sage: (-3)^(1/3)
> (-1)^(1/3)*3^(1/3)
> sage: n(_)
> 0.721124785153704 + 1.24902476648341*I
> 
> Even using the decimal point to ensure we get a numerical solution,
> which does seems like something a student could understand why they
> should do when describing symbolic versus numerical computation,
> doesn't help:
> 
> sage: (-3.0)^(1/3)
> 0.721124785153704 + 1.24902476648341*I
> 
> and Sage fails something even my eight dollar CVS calculator can (to
> my surprise) do!  This seems problematic.

For the record, in Mathematica:

In[1]:= (-1)^(1/3)

Out[1]= (-1)^(1/3)

In[2]:= % // N

Out[2]= 0.5+ 0.866025 I

In[3]:= (-3)^(1/3) // N

Out[3]= 0.721125+ 1.24902 I


In previous versions of Mathematica, there was a "RealOnly" package 
which defined odd roots as negative and printed "Nonreal" anytime a 
complex number was unavoidable.  The idea was that you could simplify 
things for high school students or in situations in which you knew you 
were only interested real numbers.  That package has apparently been 
deprecated now in version 6.0, being replaced by the functionality to 
"Reduce" an equation over the reals, etc.  For details, you can see the 
package at http://library.wolfram.com/infocenter/MathSource/6771/

Jason


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: graphs(n) behavior under restriction

2008-01-24 Thread kcrisman


>
> All right, extending Robert's patch, I've posted up trac #1908 at:
>
> http://sagetrac.org/sage_trac/ticket/1908
>
> This lets you do what you showed above:
>
> sage: show([circle((0,0),n) for n in [1..3]]) # three circles
>
> (note the extra "]" at the end, though).
>
> To plot concentric circles, of course, you use:
>
> sage: sum([circle((0,0),n) for n in [1..3]])
>
> Also the following are tiled:
>
> sage: show(graphs(3), layout='circular', vertex_size=50,
> vertex_labels=False, graph_border=True)
> sage: show(list(graphs(3)), layout='circular', vertex_size=50,
> vertex_labels=False, graph_border=True)
> sage: show(graphs(4), layout='circular', vertex_size=50,
> vertex_labels=False, graph_border=True)
> sage: show([plot(sin(i*x)) for i in range(30)]) # Two pages of images
> sage: show([sin(i*x) for i in range(2)])
> sage: show([sin(i*x) for i in range(30)], columns=1, rows=10)

As someone with not enough time or expertise to contribute this sort
of truly useful functionality but with LOTS of ideas for making Sage
better, I humbly thank both Jason and Robert for all this hard work. I
don't think there could be a much better solution within the Sage/
Python framework for these issues.  I especially like the contrast
between

sage: sum([circle((0,0),n) for n in [1..3]])

and

sage: show([circle((0,0),n) for n in [1..3]]) # three circles

As a final comment, I'll note that the following behavior with objects
which automatically display is interesting:

sage: C=circle((0,0),1);P=plot(sin,0,1)
sage: [C,P]
[, ]

and then a display of circle above a plot of sin (in the notebook) or
two separate pictures (in the command line).  I have no idea what, if
any, connection should be made with this work, though.

Finally, sorry for the typo earlier!  But *that* at least I would
expect my students to get - otherwise it misses the point of learning
to use computers. Excel or Firefox would balk at weird syntax too.

Thank you all, and hope to contribute more suggestions in the future.

- kcrisman
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Putting parentheses around -1.

2008-01-24 Thread kcrisman


> Thus you have constructed a nice expression for 1:
>
> sage: sol[2].subs(a=1).right()
> (2/(3*sqrt(3)) + 10/27)^(1/3) - 2/(9*(2/(3*sqrt(3)) + 10/27)^(1/3)) + 1/3
>
> Quiz: how to simplify that expression to 1 within SAGE? I've tried simplify,
> and radical_simplify, but neither succeeds...
>
> Paul Zimmermann

Ted, I've been there - running into that sort of "nice" formula with
Sage in the class, presumably via Maxima.  As cool as it is, it is
also confusing and disheartening to my students, who have no
experience to interpret it with.

More to the point, I would softly plead a different view on
(-1)^(1/3).  As a mathematician, I think getting the "usual" primitive
sixth root of unity is wonderful (though perhaps even making that
choice is suspect, why not its complex conjugate?), but as a pedagogue
it would cause me to question using Sage in any environment where I
needed numerical solutions to simple algebraic equations, such as any
HS class or many (though not all) freshman non-major math courses.

I definitely want my students to know how to do it by hand - in fact,
they *should* solve x^3=-1 by hand.  But as Ted points out, getting a
useful numerical approximation for x^3=-3 by typing (-3)^(1/3) is a
legitimate need, even for students who aren't ready for complex
numbers (and such students definitely exist).  And yet,

sage: (-3)^(1/3)
(-1)^(1/3)*3^(1/3)
sage: n(_)
0.721124785153704 + 1.24902476648341*I

Even using the decimal point to ensure we get a numerical solution,
which does seems like something a student could understand why they
should do when describing symbolic versus numerical computation,
doesn't help:

sage: (-3.0)^(1/3)
0.721124785153704 + 1.24902476648341*I

and Sage fails something even my eight dollar CVS calculator can (to
my surprise) do!  This seems problematic.

- kcrisman
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Command-line usage on Mac OS X

2008-01-24 Thread kcrisman



On Jan 23, 9:30 pm, "Justin C. Walker" <[EMAIL PROTECTED]> wrote:
> Hi, all,
>
> In 2.10 (on 10.4.11), I notice that "readline" is behaving badly:
>
> If I "^R" and search for a string, and find it, and then either use  
> "^A" or "E" to move to the beginning or end of the found line, I end  
> up with the cursor at the right margin of my Terminal window, and on  
> the line above the now-displayed found line.  If I then type "^L" to  
> redraw the line, I get a prompt asking me if I want to display all  
> 1599 (or some positive number) items that match.
>
> At this point, not being sure what's going on, I hit "^C" to get back  
> to reality, but this has no effect.  Nothing works until I respond  
> with either 'y' or 'n'.  At this point, things seem to be back to  
> normal on the screen, and with the line editing functions, but it's  
> hard to have confidence that this is so.
>
> Is this expected?  Is there something borked in my configuration?  
> Anyone seen this?
>
> Thanks!
>
> Justin
>
> --
> Justin C. Walker, Curmudgeon-At-Large
> Institute for the Absorption of Federal Funds
> 
> Men are from Earth.
> Women are from Earth.
>     Deal with it.
> 

Hmm, that's bothersome.  I've often encountered a related issue.
While tab-completion works fine for commands and methods, in the
command-line (not notebook)

sage: zeta_zeros? [tab]
Display all 1544 possibilities? (y or n)

appears, which is the same as Justin's response.  However,

sage: zeta_zeros? [return]
Type:   function
Base Class: 
etc.

works fine.

On the other hand, in the notebook interface both [tab] and [shift-
enter] work; [shift-enter] stays visible, while [tab] disappears once
you start working elsewhere (which to me is a neat feature, as both of
these are useful, and should be highlighted in documentation).
Somehow this asymmetry with the notebook is disturbing, though I have
no idea whether it is possible to resolve.

Thanks for any thoughts on either of these issues.
- kcrisman
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: sage 2.10 - still problems with getting R work [ticket 1476]

2008-01-24 Thread Andrzej Giniewicz

btw...

in 1476 I also mentioned that sage-fortran (and it turns out that also
g95) isn't able to build Hmisc package that is required by many
others, is it possible to tell sage to use locally installed fortran
compiler? (as in gfortran it works)
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: CartesianProduct

2008-01-24 Thread Simon King

Dear David,

On Jan 24, 1:36 pm, "David Joyner" <[EMAIL PROTECTED]> wrote:
> Doesn't 
> tupleshttp://www.sagemath.org/doc/html/ref/module-sage.combinat.combinat.ht...
> or 
> Tupleshttp://www.sagemath.org/doc/html/ref/module-sage.combinat.tuple.html#...
> do what you want?

That's it! Thank you! Simply i didn't find that command.

Yours
  Simon
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: CartesianProduct

2008-01-24 Thread David Joyner

Doesn't tuples
http://www.sagemath.org/doc/html/ref/module-sage.combinat.combinat.html#l2h-3041
or Tuples
http://www.sagemath.org/doc/html/ref/module-sage.combinat.tuple.html#l2h-4417
do what you want?

On Jan 24, 2008 5:13 AM, Simon King <[EMAIL PROTECTED]> wrote:
>
> Dear Sage team,
>
> how can i compute the n-fold Cartesian product of of a list?
>
> My hope was that the following works
> sage: P=CartesianProduct([1,2], 3)
> sage: P.list()
>
> [[1, 1, 1],
>  [1, 1, 2],
>  [1, 2, 1],
>  [1, 2, 2],
>  [2, 1, 1],
>  [2, 1, 2],
>  [2, 2, 1],
>  [2, 2, 2]]
>
> but this is not supported.
>
> I find it inconvenient to explicitly plug n copies of [1,2] into
> CartesianProduct, in particular if i don't know the value of n in
> advance (say, if i use it inside a function that has n as an
> argument).
>
> I guess there is a standard function solving my problem, but i
> couldn't find it.
> Yours
>  Simon
>
> >
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] sage 2.10 - still problems with getting R work [ticket 1476]

2008-01-24 Thread Andrzej Giniewicz

Hi,

http://sagetrac.org/sage_trac/ticket/1476 was closed some time ago as
works-for-me, but both problems I was pointing out during 2.8.15
release are still here...  I'm still getting 
http://giniu.ravenlord.ws/result.txt
- first is small - in file $SAGE/local/lib/python2.5/site-packages/
rpy.py

--> 323 Rver = self.__getitem__('R_version_string')

should be

--> 323 Rver = self.__getitem__('R.version.string')

to fix second in files $SAGE/local/bin/R $SAGE/local/lib/r/bin/R I had
to comment out

#if test -n "${R_HOME}" && \
#   test "${R_HOME}" != "${R_HOME_DIR}"; then
#  echo "WARNING: ignoring environment value of R_HOME"
#fi

the above would work if someone have ${R_HOME} set to R installation
from Sage or doesn't have it at all, but as I use R as separate
package I have it set to other place, this echo's warning and it gets
in the way

after above changes, I got:

http://giniu.ravenlord.ws/result2.txt (I cut it when I saw it works)

cheers,
Andrzej.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: CartesianProduct

2008-01-24 Thread Simon King

Dear team,

i somehow solved my problem, but it gives rise to another question.

> how can i compute the n-fold Cartesian product of of a list?

Meanwhile i produced a callable object CP=CartesianPower(L, n) so that
sage: It = iter(CP,None)
yields an iterator for the n-fold Cartesian product of a list L.

So, it works, as long as i am in Sage.

But then i wanted to use it in a blah.spyx file. When i attached it,
it was refused to use "iter" with two arguments.

I understood that there is a python-iter (with one argument) and a
Sage-iter (with one or two arguments). But how can i import Sage's
"iter" into my blah.spyx? I didn't find out what module it is
contained in.

Yours
 Simon
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Trying to plot symbolic algebra

2008-01-24 Thread harald schilly

On Jan 23, 11:46 pm, "bill.p" <[EMAIL PROTECTED]> wrote:
> Only trouble is it won't print!

that's now a java applet, you need the png file version. try
plot3d(..., viewer='tachyon')
maybe this works.

h
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] CartesianProduct

2008-01-24 Thread Simon King

Dear Sage team,

how can i compute the n-fold Cartesian product of of a list?

My hope was that the following works
sage: P=CartesianProduct([1,2], 3)
sage: P.list()

[[1, 1, 1],
 [1, 1, 2],
 [1, 2, 1],
 [1, 2, 2],
 [2, 1, 1],
 [2, 1, 2],
 [2, 2, 1],
 [2, 2, 2]]

but this is not supported.

I find it inconvenient to explicitly plug n copies of [1,2] into
CartesianProduct, in particular if i don't know the value of n in
advance (say, if i use it inside a function that has n as an
argument).

I guess there is a standard function solving my problem, but i
couldn't find it.
Yours
 Simon

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Re: Does sage support solving integer and combinatorial optimization/ model solving of operational research

2008-01-24 Thread harald schilly

as far as i know there is just cvxopt included. there is a project
called openopt out there, which combines several solvers using a
python interface - and my wish where an inclusion in sage. i think it
uses lp_solve for milp problems.

h
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



[sage-support] Does sage support solving integer and combinatorial optimization/ model solving of operational research

2008-01-24 Thread [EMAIL PROTECTED]

i just check documents of sage, but i cann't find content about
combinatorial optimization / operational research
objective: Max/Min  f(x)
subjective to:
  f1(X)http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---