[sage-support] importing functions from other worksheets

2009-11-08 Thread Peter

If I have one worksheet, say global functions, that defines several
general functions that all students should have access to, can they
easily include the latest version of the code from this worksheet into
their own worksheet with something similar to an attach or import
command at the top?

Or what other solutions are instructors using to address similar
problems? Is it recommended to add function definitions to the
init.sage file?

I suppose it is quite easy to put these functions into a global.sage
file and attach the file, but then the programs in this file have to
be developed in a terminal window rather than in the notebook (unless
I can figure out a simple way to save all input cells of the global
functions worksheet to a file global.sage on the server that is
accessible to all users).

Any suggestions are appreciated.

Thanks,
Peter
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: importing functions from other worksheets

2009-11-08 Thread William Stein

On Sun, Nov 8, 2009 at 9:23 AM, Peter peter.jip...@gmail.com wrote:

 If I have one worksheet, say global functions, that defines several
 general functions that all students should have access to, can they
 easily include the latest version of the code from this worksheet into
 their own worksheet with something similar to an attach or import
 command at the top?

No.


 Or what other solutions are instructors using to address similar
 problems? Is it recommended to add function definitions to the
 init.sage file?

 I suppose it is quite easy to put these functions into a global.sage
 file and attach the file, but then the programs in this file have to
 be developed in a terminal window rather than in the notebook (unless
 I can figure out a simple way to save all input cells of the global
 functions worksheet to a file global.sage on the server that is
 accessible to all users).

That is the current solution.

William

--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] New work sheet stopped working FireFox 3.5.4

2009-11-08 Thread madison.mich...@gmail.com

I am using Sage 4.2 in VirtualBox and FireFox 3.5.4.  The New
Worksheet has stopped working.  It brings up a previous worksheet.
On earlier versions of Sage I had the same problem, however then I
fixed it by empting the trash.  The does not seem to work now.  Is
there some way to reset the New Worksheet funcion?  I have tried
reinstalling Sate 4.2 on Virtual box and then reloading my worksheets
but that did not fix the problem  Thanks Mike
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] html does not do Latex \xi

2009-11-08 Thread madison.mich...@gmail.com

In both sagenb and using sage 4.2 in VirtualBox on an XP maching I
think I found a bug.

html( $\xi$)

or any combinations of things using \xi does not work.  If you press
evaluate the cell never stops evaluating.  It seems to work fine in
the html text box above the cell.



Thanks Mike
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Arch Linux and Sage

2009-11-08 Thread Josh

What is your work around for the sqlite issue?

On Nov 8, 12:13 am, Alex Ghitza aghi...@gmail.com wrote:
 I've been building Sage on 32-bit Archlinux for at least one year now.

 With 4.2, I only have two problems: the sqlite issue and the R issue.
 Thanks to previous threads on this sort of thing, I work around them
 by copying the system libreadline.so and libgcc.so to the appropriate
 places in the sage build directory.

 It's a bit annoying because as far as I can tell I have to wait for
 sqlite to fail before copying libreadline, and then for R to fail
 before copying libgcc.  So the whole thing needs a bit too much of my
 attention.

 On the other hand, after that I have sage-4.2-goodness with longtests
 passing.  There are no problems with Singular on my system.

 Best,
 Alex

 On Sat, Nov 07, 2009 at 09:06:36PM -0800, William Stein wrote:

   * Build hangs while building libfplll, which is worked around by copying 
   the
   system's libfplll, and editing the $SAGE_ROOT/local/installed/ to make the
   build system think that libfplll is installed.

  I didn't see this at all.

   * Finally, after the build is done, starting Sage or running the doctests
   fails with a message about a function in the Singular interface not being
   implemented. I do not know any workarounds to this.

  I didn't see this at all either.

 [...]

 --
 Alex Ghitza -- Lecturer in Mathematics -- The University of Melbourne
 -- Australia --http://www.ms.unimelb.edu.au/~aghitza/
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Arch Linux and Sage

2009-11-08 Thread William Stein

On Sun, Nov 8, 2009 at 3:33 PM, Josh chaotixmonju...@gmail.com wrote:

 What is your work around for the sqlite issue?

I don't know who you're asking, but for me it's to copy the
system-wide readline library into SAGE_ROOT/local/lib/, as you
suggested.

William

 On Nov 8, 12:13 am, Alex Ghitza aghi...@gmail.com wrote:
 I've been building Sage on 32-bit Archlinux for at least one year now.

 With 4.2, I only have two problems: the sqlite issue and the R issue.
 Thanks to previous threads on this sort of thing, I work around them
 by copying the system libreadline.so and libgcc.so to the appropriate
 places in the sage build directory.

 It's a bit annoying because as far as I can tell I have to wait for
 sqlite to fail before copying libreadline, and then for R to fail
 before copying libgcc.  So the whole thing needs a bit too much of my
 attention.

 On the other hand, after that I have sage-4.2-goodness with longtests
 passing.  There are no problems with Singular on my system.

 Best,
 Alex

 On Sat, Nov 07, 2009 at 09:06:36PM -0800, William Stein wrote:

   * Build hangs while building libfplll, which is worked around by copying 
   the
   system's libfplll, and editing the $SAGE_ROOT/local/installed/ to make 
   the
   build system think that libfplll is installed.

  I didn't see this at all.

   * Finally, after the build is done, starting Sage or running the doctests
   fails with a message about a function in the Singular interface not being
   implemented. I do not know any workarounds to this.

  I didn't see this at all either.

 [...]

 --
 Alex Ghitza -- Lecturer in Mathematics -- The University of Melbourne
 -- Australia --http://www.ms.unimelb.edu.au/~aghitza/
 




-- 
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 
sage-support-unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Arch Linux and Sage

2009-11-08 Thread William Stein

On Sun, Nov 8, 2009 at 3:55 PM, Josh chaotixmonju...@gmail.com wrote:

 I was wondering what I am suppose to do with libreadline to get it to
 compile.

Quoting from Tim's email: * Incompatible libreadline.so.6 -- the
libreadline in Sage is dynamically linked to libtermcap. Arch Linux
disables libtermcap, so one needs to copy the system's libreadline to
$SAGE_ROOT/local/lib. This is also the case in binary distributions.

--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Arch Linux and Sage

2009-11-08 Thread Alex Ghitza

On Sun, Nov 08, 2009 at 03:57:12PM -0800, William Stein wrote:
 
 On Sun, Nov 8, 2009 at 3:55 PM, Josh chaotixmonju...@gmail.com wrote:
 
  I was wondering what I am suppose to do with libreadline to get it to
  compile.
 
 Quoting from Tim's email: * Incompatible libreadline.so.6 -- the
 libreadline in Sage is dynamically linked to libtermcap. Arch Linux
 disables libtermcap, so one needs to copy the system's libreadline to
 $SAGE_ROOT/local/lib. This is also the case in binary distributions.
 

Yep.  On my system, when I get the sqlite error, I type

cp /usr/lib/libreadline.so /opt/sage-4.2/local/lib/

and then make again.


Best,
Alex



-- 
Alex Ghitza -- Lecturer in Mathematics -- The University of Melbourne
-- Australia -- http://www.ms.unimelb.edu.au/~aghitza/

--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: z-range issues in implicit_plot3d

2009-11-08 Thread Matt Rissler

Poking through the code

I think line 922 in sage/plot/plot3d/implicit_surface.pyx should read:

self.zrange = ranges[2][:2]

I'd submit the patch myself, but I'd have to create a login and figure
out the versioning system.  Someday, but not today.

Matt
On Oct 24, 11:34 pm, Micah micah.ja...@gmail.com wrote:
 Greetings all,

 I have been fiddling around withimplicit_plot3dfor most of the day
 and I have noticed that sometimes, the range of values for z are
 partially disregarded.

 sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,-5,5),(y,-5,5),(z,
 0,5),contour=2)

 should produce only the northern hemisphere of the sphere of radius
 sqrt(8) but it produces the entire sphere.  Meanwhile

 sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,0,5),
 (z,-5,5),contour=2)

 only produces the portion of the sphere in the first octant, rather
 than a full quarter of the sphere.

 Of course, the z-range is not always disregarded.

 sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,-5,5),
 (z,-5,5),contour=2)

 produces the expected output.

 This happens on both 4.1.1 (on sagenb) and 4.1.2 (my installation).
 For convenience, I've published the sagenb notebook.  
 http://sagenb.org/pub/830/

 I have tried tracing through the code, but I was quickly overwhelmed
 by the task.

 -Micah
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: z-range issues in implicit_plot3d

2009-11-08 Thread Matt Rissler

That's line 932

On Nov 8, 9:38 pm, Matt Rissler discn...@gmail.com wrote:
 Poking through the code

 I think line 922 in sage/plot/plot3d/implicit_surface.pyx should read:

 self.zrange = ranges[2][:2]

 I'd submit the patch myself, but I'd have to create a login and figure
 out the versioning system.  Someday, but not today.

 Matt
 On Oct 24, 11:34 pm, Micah micah.ja...@gmail.com wrote:



  Greetings all,

  I have been fiddling around withimplicit_plot3dfor most of the day
  and I have noticed that sometimes, the range of values for z are
  partially disregarded.

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,-5,5),(y,-5,5),(z,
  0,5),contour=2)

  should produce only the northern hemisphere of the sphere of radius
  sqrt(8) but it produces the entire sphere.  Meanwhile

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,0,5),
  (z,-5,5),contour=2)

  only produces the portion of the sphere in the first octant, rather
  than a full quarter of the sphere.

  Of course, the z-range is not always disregarded.

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,-5,5),
  (z,-5,5),contour=2)

  produces the expected output.

  This happens on both 4.1.1 (on sagenb) and 4.1.2 (my installation).
  For convenience, I've published the sagenb notebook.  
  http://sagenb.org/pub/830/

  I have tried tracing through the code, but I was quickly overwhelmed
  by the task.

  -Micah
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: html does not do Latex \xi

2009-11-08 Thread ma...@mendelu.cz

Hi Mike, have a look at strings in Python and use
html(r$\xi$) or html($\\xi$)

Robert

On 9 lis, 00:10, madison.mich...@gmail.com
madison.mich...@gmail.com wrote:
 In both sagenb and using sage 4.2 in VirtualBox on an XP maching I
 think I found a bug.

 html( $\xi$)

 or any combinations of things using \xi does not work.  If you press
 evaluate the cell never stops evaluating.  It seems to work fine in
 the html text box above the cell.

 Thanks Mike
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: z-range issues in implicit_plot3d

2009-11-08 Thread William Cauchois

Thanks for your work resolving this issue! I will be happy to create a
Trac ticket and submit a patch with this change.

-- Bill

On Nov 8, 7:38 pm, Matt Rissler discn...@gmail.com wrote:
 Poking through the code

 I think line 922 in sage/plot/plot3d/implicit_surface.pyx should read:

 self.zrange= ranges[2][:2]

 I'd submit the patch myself, but I'd have to create a login and figure
 out the versioning system.  Someday, but not today.

 Matt
 On Oct 24, 11:34 pm, Micah micah.ja...@gmail.com wrote:



  Greetings all,

  I have been fiddling around withimplicit_plot3dfor most of the day
  and I have noticed that sometimes, the range of values for z are
  partially disregarded.

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,-5,5),(y,-5,5),(z,
  0,5),contour=2)

  should produce only the northern hemisphere of the sphere of radius
  sqrt(8) but it produces the entire sphere.  Meanwhile

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,0,5),
  (z,-5,5),contour=2)

  only produces the portion of the sphere in the first octant, rather
  than a full quarter of the sphere.

  Of course, thez-rangeis not always disregarded.

  sage:  implicit_plot3d((x^2)/2+(y^2)/2+(z^2)/2,(x,0,5),(y,-5,5),
  (z,-5,5),contour=2)

  produces the expected output.

  This happens on both 4.1.1 (on sagenb) and 4.1.2 (my installation).
  For convenience, I've published the sagenb notebook.  
  http://sagenb.org/pub/830/

  I have tried tracing through the code, but I was quickly overwhelmed
  by the task.

  -Micah
--~--~-~--~~~---~--~~
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 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~--~~~~--~~--~--~---