Re: [sage-support] Solving system of equations

2014-12-02 Thread Jim Clark
I see numerous problems in your code snippet:
* variables v, psi_d and l (the letter ell in your definition of rp_f) are not 
defined
* you define rV_ra in the first line but refer to rV_fa inside the for loop
* the list sys is not defined

The following code snippet works:
v = 1
psi_d = 1
rV_ra=vector([v, 0, 0])
omega_ra = vector([0,0,psi_d])
rp_f = vector([1,0,0])

sys = [0,0,0]
ans1=rV_ra+omega_ra.cross_product(rp_f)
for i in range (0,3):
sys[i]=[ans1[i]==rV_ra[i]]
print sys

> On Dec 2, 2014, at 8:49 AM, SiL588 .  wrote:
> 
> Hi everybody, i'm new to sage and i'm having problems solving a two equations 
> system and in particular with a for-loop assignament. 
> 
> Here's what i've got:
> 
> rV_ra=vector([v, 0, 0])
> omega_ra = vector([0,0,psi_d])
> rp_f = vector([l,0,0])
> 
> ans1=rV_ra+omega_ra.cross_product(rp_f)
> for i in range (0,3):
> sys[i]=[ans1[i]==rV_fa[i]]   
> 
> but it gives the following error:
> TypeError: 'module' object does not support item assignment
> 
> What does it mean? It seems a pretty simple operation to me and I can't 
> understand what it is that i'm doing wrong.
> Thank you very much
> 
> -- 
> 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 post to this group, send email to sage-support@googlegroups.com 
> .
> Visit this group at http://groups.google.com/group/sage-support 
> .
> For more options, visit https://groups.google.com/d/optout 
> .

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Sage with Yosemite?

2014-10-21 Thread Jim Clark
On Oct 21, 2014, at 10:58 AM, Chris Maness  wrote:

> Has anyone tried the 6.3 binary with Sage?
> 
> Thanks,
> Chris

Just a bit-- started it up and ran the notebook. Seems to be there, but haven't 
tested old worksheets yet.
Jim Clark

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Problems getting Sage 6.2 & Python (matplotlib) to plot

2014-07-02 Thread Jim Clark
From earlier thread, either of two work-arounds worked for me in Sage 6.2:Work-around #1:sage: import matplotlibsage: matplotlib.use(‘agg’)sage: import matplotlib.pyplot as pltWork-around #2:rename ~/.matplotlib/matplotlibrc to .matplotlib/matplotlibrc.bakJim Clark-Original Message-
From: LouP 
Sent: Jul 2, 2014 8:38 AM
To: sage-support@googlegroups.com
Subject: [sage-support] Problems getting Sage 6.2 & Python (matplotlib) to plot









 
  0
  0
  1
  301
  1716
  NRL
  14
  4
  2013
  14.0
 
 
  
 



 
  Normal
  0
  
  
  
  
  false
  false
  false
  
  EN-US
  JA
  X-NONE
  
   
   
   
   
   
   
   
   
   
  
  
   
   
   
   
   
   
   
   
   
   
   
  

 
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
 










I am having problems with matplotlib, Sage plotting and,
apparently, backends.  I have installed
Sage 6.2 on my Mac Book Pro (system 10.6) (I just upgraded from Sage 4.2). I
have removed all copies of matplotlibrc from my computer except for the file
buried in Sage-6.2/.../mpl_data/. All choices of backend resulted in the
errors:  _backend not found, where
_backend is the name of the library that should load for the backend (e.g.
_tkagg for TKAgg).  My partial solution
is to use the _tkagg from my prior Sage version which I produced by a compile
many years ago before I had Sage.

I have tried several scenarios to run my code:  iPython (in Terminal), Sage (in Terminal), and
as a script.  Scripts and iPython are run through the Sage 6.2 package.  I mostly run from script
which has the most problems.  The most successful situation is with TKAgg.
However, calling plot(...) and show() from pylab and D.show() from Sage (where
D is a graph) have different successes. 
Here is a table of what does and does not work (view with monospace
font).

Backend   Plot
call    iPython 
Sage   Script

TKAgg D.show()     Yes  Yes   
No (but Preview does launch)

  pylab.plot()
Yes  Yes    Yes 

NoBackend   D.show()     Yes  Yes   
No (but Preview does launch)

  pylab.plot()
No   No     No

No Backend means I commented out the backend statement in matplotlibrc.

TKAgg is the most successful, but not fully.  And I had to add the _tkagg library to the
Sage package.

Sorry for the verbose post, but I thought I'd try several
things, first. I did see a previous post about some bug in Sage 6.2 using the
wrong .matplotlib folder, but I don't know what that tells me.

I can limp along with what I have above, but any help very
appreciated.



Code generating problems:

(1) D.show() version:

adjls=[[0, 1, 0, 1], [1, 0, 1, 0], [0, 1, 0, 1], [1, 0, 1,
0]]

M= Matrix(adjls)

D= Graph(M)

D.show() 

(2) pylab.plot version:

import numpy as NP

import pylab as PL

x= NP.array([1,2,3,4])

y= x**2

PL.plot(x,y)

PL.show()    



-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.




-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-28 Thread Jim Clark
On May 28, 2014, at 11:26 AM, John H Palmieri  wrote:

> It looks like the actual problem is a bug in Sage (which has been fixed in 
> the beta releases of Sage 6.3). Namely, when Sage runs, it is supposed to use 
> ~/.sage/matplotlib-1.3.1 rather than ~/.matplotlib for matplotlib 
> configuration (just for your sort of situation), but this doesn't work right 
> in Sage 6.2. This is fixed athttp://trac.sagemath.org/ticket/16305, in case 
> you want to make the change to your copy of Sage 6.2.

Ahh, so it is a bug.. I'm glad it's been found and fixed. I'll wait for Sage 
6.3, since I now have a workaround.
Thanks again for your help.
Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-28 Thread Jim Clark
On May 28, 2014, at 10:42 AM, Jim Clark  wrote:

> Also...
> ~/.matplotlib/matplotlibrc contains
> backend:  TkAgg
> 
> I'll try moving this out of the way...
> 

Found the culprit! Renamed matplotlibrc to matplotlibrc.bak,
started a fresh terminal window and restarted Sage
and now import matplotlib.pyplot as plt works.

Thanks, John Palmieri -- your suggestion led me to the source of the problem.

Perhaps I need to find a better way to insulate macports from Sage...

Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-28 Thread Jim Clark
On May 28, 2014, at 10:21 AM, John H Palmieri  wrote:

> Oh, and to answer your other question: I just downloaded the Sage binary on 
> an OS X Mavericks 10.9.3 machine and was unable to replicate the problem. I 
> wonder if the presence of the macports stuff is interfering somehow. Have you 
> set any environment variables related to matplotllib (other than 
> SAGE_MATPLOTLIB_GUI)?

Short answer: no.  Could be PATH or PYTHONPATH ?

Jims-computer:~ jim$ env
TERM_PROGRAM=Apple_Terminal
SHELL=/bin/bash
TERM=xterm-256color
TMPDIR=/var/folders/7f/87pw4jw1691785kvc9kw2lkrgv/T/
Apple_PubSub_Socket_Render=/tmp/launch-rgHVzO/Render
TERM_PROGRAM_VERSION=326
TERM_SESSION_ID=3E9FF6BD-7ADF-42F9-A763-BF3EC2E001B2
USER=jim
SAGE_BROWSER=open -a "/Applications/Google Chrome.app"
SSH_AUTH_SOCK=/tmp/launch-9nUl4C/Listeners
__CF_USER_TEXT_ENCODING=0x1FB:0:0
PATH=/opt/local/bin:/opt/local/sbin:/Library/Frameworks/Python.framework/Versions/2.7/bin:/Applications/sage:/usr/local/cuda/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/texbin:/usr/local/bin
__CHECKFIX1436934=1
PWD=/Users/jim
EDITOR=/usr/bin/edit
LANG=en_US.UTF-8
SHLVL=1
HOME=/Users/jim
DYLD_LIBRARY_PATH=/usr/local/cuda/lib:
PYTHONPATH=/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages:
LOGNAME=jim
SAGE_MATPLOTLIB_GUI=no
SECURITYSESSIONID=186a5
_=/usr/bin/env


Also...
~/.matplotlib/matplotlibrc contains
backend:  TkAgg

I'll try moving this out of the way...

Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-28 Thread Jim Clark
On May 28, 2014, at 10:15 AM, John H Palmieri  wrote:

> Try this: start a new Sage session and do
> 
> sage: import matplotlib
> sage: matplotlib.get_backend()
> 
> What does it return? If it returns 'TkAgg', try
> 
> sage: matplotlib.use('agg')
> sage: import matplotlib.pyplot as plt
> 
> Let us know what happens.
> 

ims-computer:~ jim$ sage
┌┐
│ Sage Version 6.2, Release Date: 2014-05-06 │
│ Type "notebook()" for the browser-based notebook interface.│
│ Type "help()" for help.│
└┘
sage: import matplotlib
sage: matplotlib.get_backend()
'TkAgg'
sage: matplotlib.use('agg')
sage: import matplotlib.pyplot as plt
sage: 


Success! A work-around (albeit an obscure one…)

Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-28 Thread Jim Clark
On May 28, 2014, at 5:11 AM, kcrisman  wrote:

> In fact, one test you could do is to test that one file.  You'd have to cd 
> into the actual Sage-6.2-... directory and then do
> 
> ./sage -t src/sage/plot/plot.py
>  
Fails the test (same error: cannot import name _tkagg):

Jims-computer:sage jim$ ./sage -t src/sage/plot/plot.py
init.sage does not exist ... creating
Running doctests with ID 2014-05-28-09-13-04-3aafce8a.
Doctesting 1 file.
sage -t src/sage/plot/plot.py
**
File "src/sage/plot/plot.py", line 262, in sage.plot.plot
Failed example:
from pylab import *
... (skipping)
from matplotlib.backends import _tkagg
ImportError: cannot import name _tkagg
... (skipping much more)
3 items had failures:
  11 of  77 in sage.plot.plot
   7 of  12 in sage.plot.plot.SelectiveFormatter
   7 of  12 in 
sage.plot.plot.SelectiveFormatter.None._SelectiveFormatterClass.__init__
[374 tests, 25 failures, 93.39 s]
--
sage -t src/sage/plot/plot.py  # 25 doctests failed
--
Total time for all tests: 93.8 seconds
cpu time: 70.3 seconds
cumulative wall time: 93.4 seconds

I captured the entire output into a log file that I could send, if that would 
help.

Still the question remains: does anyone else experience the failure on Mac OSX 
10.9 when you do:

sage: import matplotlib.pyplot as plt

Again, thanks,
Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] Re: Can't import matplotlib.pyplot in Sage 6.2

2014-05-27 Thread Jim Clark
Thank you for the response, kcrisman (sorry I don’t know your first name).

Configuration: Apple MacBook pro running OSX 10.9.3
Downloaded and installed vanilla sage-6.2-x86_64-Darwin-OSX_10.9_x86_64.dmg
I have set export SAGE_MATPLOTLIB_GUI=no in my .bash_profile (due to a similar 
situation in the past. I only want to use matplotlib to save to .png files, not 
to view interactively.) I am happy with Sage being built without tkagg support.
(I also have python, scipy, matplotlib, etc. installed via macports, but Sage 
has always worked as a stand-alone environment, which pleases me. I work in the 
two environments independently. macports stuff is up-to-date.)

Has anyone else experienced this problem? The test is exceedingly simple:
sage: import matplotlib.pyplot as plt

I actually found the same reports you suggest via Google before submitting this 
question to sage-support.
What I have attempted:

1. Acting on 
http://ask.sagemath.org/question/626/sage-python-import-matplotlib-no-module-named,
 I edited 
/Applications/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-macosx-10.9-x86_64.egg/matplotlib/backends/tkagg.py
changed import _tkagg
to import backend_tkagg as _tkagg
which then caused the error
ImportError: cannot import name backend_tkagg

2. Acting on 
http://ask.sagemath.org/question/3962/gui-backend-matplotlib-in-sage, I rebuilt 
matplotlib via sage -f matplotlib
That failed, probably for the reason explained in that report, so I reinstalled 
vanilla Sage 6.2

If I am the only person experiencing this problem, then it must be something in 
my configuration,
but I’d really like to know if this is a problem in the Sage 6.2 distribution, 
so it can get fixed.

Thanks to all,
Jim

On May 27, 2014, at 9:33 AM, kcrisman  wrote:

> Hi!  Is it possible that some locations changed in your installation?  Here 
> is an old post that has a very similar error:
> https://groups.google.com/forum/#!topic/sage-support/fV2VNL-5UuY
> 
> Otherwise, perhaps the problem may be the one described here:
> http://ask.sagemath.org/question/626/sage-python-import-matplotlib-no-module-named
> in which case the binary was probably compiled without tkagg support, which 
> is normal.  You could Compile Sage from scratch, perhaps could redo 
> matplotlib.  See also 
> http://ask.sagemath.org/question/3962/gui-backend-matplotlib-in-sage
> 
> Now, we did upgrade matplotlib in http://trac.sagemath.org/ticket/14993 so I 
> wouldn't be surprised if that did cause some problems (there were several 
> tickets fixed) but it is a little surprising that this is the one, since we 
> have this same line in the documentation at 
> http://www.sagemath.org/doc/reference/plotting/sage/plot/plot.html#sage.plot.plot.SelectiveFormatter
> 
> I hope that ONE of these things helps, but I'm sorry if not - in that event, 
> any other platform details would be very helpful for us.
> 
> On Tuesday, May 27, 2014 7:04:08 AM UTC-4, Jim wrote:
> Hello,
> 
> A script that I wrote in April under Sage 6.1.1 stopped working; attempting 
> to import matplotlib.pyplot produces an error:
> 
> Jims-computer:HW2 jim$ sage
> ┌┐
> │ Sage Version 6.2, Release Date: 2014-05-06 │
> │ Type "notebook()" for the browser-based notebook interface.│
> │ Type "help()" for help.│
> └┘
> sage: import matplotlib.pyplot as mpl
> ---
> ImportError   Traceback (most recent call last)
> 

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Can't import matplotlib.pyplot in Sage 6.2

2014-05-27 Thread Jim Clark
Hello,

A script that I wrote in April under Sage 6.1.1 stopped working; attempting to 
import matplotlib.pyplot produces an error:

Jims-computer:HW2 jim$ sage
┌┐
│ Sage Version 6.2, Release Date: 2014-05-06 │
│ Type "notebook()" for the browser-based notebook interface.│
│ Type "help()" for help.│
└┘
sage: import matplotlib.pyplot as mpl
---
ImportError   Traceback (most recent call last)
 in ()
> 1 import matplotlib.pyplot as mpl

/Applications/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-macosx-10.9-x86_64.egg/matplotlib/pyplot.py
 in ()
 96 
 97 from matplotlib.backends import pylab_setup
---> 98 _backend_mod, new_figure_manager, draw_if_interactive, _show = 
pylab_setup()
 99 
100 

/Applications/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-macosx-10.9-x86_64.egg/matplotlib/backends/__init__.pyc
 in pylab_setup()
 26 # imports. 0 means only perform absolute imports.
 27 backend_mod = __import__(backend_name,
---> 28  globals(),locals(),[backend_name],0)
 29 
 30 # Things we pull in from all backends

/Applications/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-macosx-10.9-x86_64.egg/matplotlib/backends/backend_tkagg.py
 in ()
  9 
 10 # Paint image to Tk photo blitter extension
---> 11 import matplotlib.backends.tkagg as tkagg
 12 
 13 from matplotlib.backends.backend_agg import FigureCanvasAgg

/Applications/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-macosx-10.9-x86_64.egg/matplotlib/backends/tkagg.py
 in ()
  1 from __future__ import print_function
> 2 from matplotlib.backends import _tkagg
  3 import Tkinter as Tk
  4 
  5 def blit(photoimage, aggimage, bbox=None, colormode=1):

ImportError: cannot import name _tkagg
sage: 

Downloaded and installed the Sage 6.2 binary on OSX 10.9.3.

Seems like a regression error, but I don’t know how to fix it…

Please help.
Thank you,
Jim Clark

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


[sage-support] Use of Scipy weave in Sage

2014-03-18 Thread Jim Clark
Hello all,

I would like to apply Scipy weave in Sage (i.e., call inline C code from 
Python).

Instructions are at http://www.sagemath.org/doc/numerical_sage/weave.html

When I copy the first example into a Sage Notebook cell, I get the following 
error traceback:

In file included from
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/syslimits.h:7:0,
 from
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/limits.h:34,
 from
/Applications/sage/local/include/python2.7/Python.h:19,
 from
/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx/ob\
ject.h:11,
 from
/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx/we\
ave_imp.cpp:7:
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/limits.h:169:61: fatal error: limits.h: No such file or
directory
compilation terminated.
In file included from
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/syslimits.h:7:0,
 from
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/limits.h:34,
 from
/Applications/sage/local/include/python2.7/Python.h:19,
 from
/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx/ob\
ject.h:11,
 from
/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx/we\
ave_imp.cpp:7:
/Applications/sage/local/bin/../lib/gcc/x86_64-apple-darwin13.0.0/4.7.3/\
include-fixed/limits.h:169:61: fatal error: limits.h: No such file or
directory
compilation terminated.
Traceback (click to the left of this block for traceback)
...
scipy.weave.build_tools.CompileError: error: Command "g++
-fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall
-I/Applications/sage/local/lib/python2.7/site-packages/scipy/weave
-I/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx
-I/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/blitz
-I/Applications/sage/local/lib/python2.7/site-packages/numpy/core/includ\
e -I/Applications/sage/local/include/python2.7 -c
/Applications/sage/local/lib/python2.7/site-packages/scipy/weave/scxx/we\
ave_imp.cpp -o
/var/folders/7f/87pw4jw1691785kvc9kw2lkrgv/T/jim/python27_intermedia\
te/compiler_63538caa8cf471defd3a9c039c6862c3/Applications/sage/local/lib\
/python2.7/site-packages/scipy/weave/scxx/weave_imp.o" failed with exit
status 1

Apparently the compiler can't find the file limits.h

Running Sage 6.1.1 on OS X 10.9.2 (Mavericks)

What's up?

Thanks for any insight/help anyone can provide.
Jim Clark

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.


Re: [sage-support] [new to SAGE] need starting advice

2013-12-17 Thread Jim Clark
Use the "load" function, e.g., load("phone.py")

In a notebook cell, type load? then press the TAB key for documentation.

Jim Clark

On Dec 17, 2013, at 2:05 PM, erwin16  wrote:

> I'm new to SAGE, just built and  installed it today (5.13) on OSX 10.9 
> 
> I have  a capture.csv data file and a python script  phone.py 
> 
>   phone.py --
> import csv
> import math
> import random
> import sage.plot.line
> import sage.plot.plot3d.shapes2
> import sage.rings.polynomial.convolution
> import scipy.fftpack
> ...
> def loadphonedata(csvname):
> ...
> ..
> def process_capture():
>   loadphonedata("capture.csv")
> ---
> 
> but then :
> once sage is launched and the browser opened,  I'm stuck, ...I don't see how 
> to run my python script..
> I should have missed a paragraph in the documentation... 
> can someone give me a link to the correct doc ? 
> 
> thanks a lot for enlightenment
> 
> -- 
> 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 post to this group, send email to sage-support@googlegroups.com.
> Visit this group at http://groups.google.com/group/sage-support.
> For more options, visit https://groups.google.com/groups/opt_out.

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [sage-support] Re: Sage Speed Issues

2013-06-11 Thread Jim Clark
Since you are writing your own algorithms in python, I suggest you investigate cython:http://docs.cython.orgto compile your python into machine code, instead of python's quasi-compiled byte code.Cython is included with sage -- just add the code %cython as the first line of a Sage worksheet cell.Alternatively, put you Sage code into a file with the extension .spyx, then load the file from the Sage command line.There are a couple of Sage-isms that won't work in cython, for example, you must replace e^{whatever} with e**{whatever}.Also, as others have pointed out, you might analyze your code a bit to calculate the number of operations you want to perform.You can easily reach a point that would require the fastest computer on earth hundreds, thousand, millions,... of years to compute.Jim ClarkThanks for your reply. Actually I have exponential function f(u) in 8-dimensions and I am using the general formula for Taylor series at available at http://en.wikipedia.org/wiki/Taylor_series (Taylor series in several variables). I want to expand summations in this equations for up to 6 or even more as I am using this expansion to calculate the bit error rate for the E8 lattice. The exponential function f(u) is of the following form. $$ f(u) = e^{(-(3.15987540437407e-36)*(99446621081482098*u1 + 99446621081482098*u2 + 99446621081482098*u3 + 49723310540741049*u4 + 99446621081482098*u5 + 165744368469136820*u6 + 198893242162964181*u7 +29833986326264)^2 - (3.15987540437407e-38)*(1790039179466677674*u1 - 298339863262490*u2 - 298339863262490*u3 - 149169931631245*u4 - 298339863262490*u5 - 2320421158567915270*u6 - 1988932421629641660*u7 - 994466210814820830)^2 - (3.15987540437407e-38)*(1790039179466677674*u1 + 298339863262715*u2 + 2320421158567915470*u3 - 149169931631245*u4 - 298339863262490*u5 - 2320421158567915270*u6 + 1988932421629641810*u7 - 994466210814820830)^2 - (3.15987540437407e-38)*(1790039179466677674*u1 + 298339863262715*u2 + 2320421158567915470*u3 - 149169931631245*u4 + 4972331054074104450*u5 - 2320421158567915270*u6 + 1988932421629641810*u7 - 994466210814820830)^2 - (3.15987540437407e-38)*(1790039179466677674*u1 + 298339863262715*u2 + 2320421158567915470*u3 + 447509794893960*u4 + 4972331054074104450*u5 + 5635308527950651670*u6 + 1988932421629641810*u7 - 994466210814820830)^2 - (3.15987540437407e-38)*(1790039179466677674*u1 + 298339863262715*u2 + 4972331054074104450*u3 + 447509794893960*u4 + 4972331054074104450*u5 + 5635308527950651670*u6 + 1988932421629641810*u7 - 994466210814820830)^2 - (3.15987540437407e-36)*(99446621081482098*u1 + 99446621081482098*u2 + 99446621081482098*u3 + 49723310540741049*u4 + 99446621081482098*u5 + 165744368469136820*u6 - 198893242162964166*u7 - 397786484325928347*u8 + 29833986326264)^2 - (3.15987540437407e-36)*(99446621081482098*u1 + 99446621081482098*u2 + 99446621081482098*u3 + 49723310540741049*u4 + 99446621081482098*u5 + 165744368469136820*u6 + 198893242162964181*u7 + 397786484325928347*u8 + 29833986326264)^2)}$$




-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 


Re: [sage-support] Notebook: How to print long output lines (>72 characters) without breaks?

2013-05-19 Thread Jim Clark
With the mouse pointer, click to the left of the line that is broken up. That 
will toggle the output line to the non-breaking state.

(I only recently discovered this solution when I was having the same problem.)

Jim Clark

On May 19, 2013, at 10:12 AM, geo909 wrote:

> Hi all,
> 
> I am using Sage 4.3 with the notebook interface. I would like
> to have very long output lines, probably 100 characters or 
> more, without breaks on the screen. 
> 
> For instance, if I give
> print 72*"x"
> I get
> xxx
> which is fine. 
> 
> But with
> print 100*"x"
> I get
> \ 
>  
> 
> I would like to have instead:
> 
>  
> 
> How can I force sage not to do automatic line breaks?
> 
> Many thanks in advance
> 
> 

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [sage-support] Cleaning temporary/easily generated files from ~/.sage

2013-04-04 Thread Jim Clark
Thank you for the response. I had not noticed the "Revisions" tab on the 
worksheet (feeling embarrassed).
Jim

On Apr 4, 2013, at 9:03 AM, kcrisman wrote:

> 
> 
> On Thursday, April 4, 2013 11:30:55 AM UTC-4, Jim wrote:
> Deep among the .sage/sage_notebook.sagenb subdirectories is a worksheet 
> subdirectory 
> that contains a subdirectory called "snapshots" that contains numerous *.bz2 
> files. 
> 
> I assume these are snapshots of the worksheet. 
> What causes their creation? 
> Do they contain a revision history? 
> 
> 
> At one time, long ago, they did do all these things.  Now they are probably 
> all the same - every time you "save" you get one, I believe.   You can see 
> the revisions by clicking on the "Revisions" tab on the upper right.
> 
> They used to be automatic saves, but that turned out to really really slow 
> down notebook servers, so we removed that.  For some reason, at the same time,
> 
> PEOPLE ALSO MADE IT SO ALL REVISIONS OVERWRITE THE PREVIOUS ONES
> 
> and I, at least, have no idea how to fix that - and I tried on some of the 
> previous codebase.  With the switch to the "flask" codebase a while ago it 
> has perhaps become easier or harder to fix.
> 
> If so, how do I examine a previous revision of the worksheet? 
> If there is not a way to look at the revision history, then why are they 
> maintained? 
> Can I safely delete them? 
> 
> Most likely, you can delete all but perhaps the last one.  I would just do 
> some spot checks but that's been my experience over the last quite-a-few 
> years.
> 
> See also 
> 
> http://code.google.com/p/sagenb/issues/detail?id=58
> http://code.google.com/p/sagenb/issues/detail?id=59
> both from an now-unmaintained codebase whose issues, however, did NOT 
> migrate to Github (!)
> http://trac.sagemath.org/sage_trac/ticket/8776
> probably bit rotted
> 
> -- 
> 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 post to this group, send email to sage-support@googlegroups.com.
> Visit this group at http://groups.google.com/group/sage-support?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [sage-support] Cleaning temporary/easily generated files from ~/.sage

2013-04-04 Thread Jim Clark
Deep among the .sage/sage_notebook.sagenb subdirectories is a worksheet 
subdirectory
that contains a subdirectory called "snapshots" that contains numerous *.bz2 
files.

I assume these are snapshots of the worksheet.
What causes their creation?
Do they contain a revision history?
If so, how do I examine a previous revision of the worksheet?
If there is not a way to look at the revision history, then why are they 
maintained?
Can I safely delete them?

Thank you,
Jim Clark

On Apr 4, 2013, at 1:28 AM, David Loeffler wrote:

> You can pretty much freely kill anything other than the
> "sage_notebook.sagenb" subdirectory -- the rest is just cache files,
> logs, command-line history, etc. The notebook subdirectory is
> important, because it contains your saved worksheets (if you use the
> sage notebook) -- if you use sage purely from the command line you can
> remove that too.
> 
> David
> 
> On 4 April 2013 07:46, Rogério Brito  wrote:
>> Hi.
>> 
>> I am preparing myself to backup my systems and I would like to clean
>> unnecessary, temporary files (or those that can be easily generated)
>> before actually proceeding to the backup and I was wondering what
>> would be safe to remove from my ~/.sage directory.
>> 
>> Are there guildelines here? Sorry if this is a FAQ, but my google-fu
>> is failing me.
>> 
>> 
>> Thanks in advance,
>> 
>> --
>> Rogério Brito : rbrito@{ime.usp.br,gmail.com} : GPG key 4096R/BCFC

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [sage-support] Re: Rendering of LaTeX in Sage Notebook

2013-01-29 Thread Jim Clark
On Jan 29, 2013, at 2:56 PM, Jason Grout wrote:

> On 1/28/13 12:50 PM, Jim Clark wrote:
>> On Jan 28, 2013, at 10:34 AM, Jan Groenewald wrote:
>> 
>>> Have you tried editing the html (there is a button for that)?
>>> Often extra  tags flood our students' cells and
>>> it has to be cleared out for the LaTeX to be interpreted.
>> 
>> Thank you, Jan, that worked (I also edited out a  tag)
>> 
>> but it's exceedingly tedious!
>> 
>> Is there a fix in the works?
> 
> Is the problem that there are html tags inside of math delimiters, like 
> $x^2$?  There is no current plan to automatically strip these out (how 
> in the world did they get there in the first place?), and such tags do 
> prevent the latex from rendering, IIRC.
> 
Yes, this is where they occur. It seems to happen mostly with LaTeX code that 
spreads over more than one line (helps readability...),
such as occurs in matrixes or case constructs. Editing out all of the 
interfering html tags leaves one long, very hard-to-read, wrapped line in the 
TinyMCE text editor.
Jim

-- 
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 post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [sage-support] Rendering of LaTeX in Sage Notebook

2013-01-28 Thread Jim Clark
On Jan 28, 2013, at 10:34 AM, Jan Groenewald wrote:

> Have you tried editing the html (there is a button for that)?
> Often extra  tags flood our students' cells and
> it has to be cleared out for the LaTeX to be interpreted.

Thank you, Jan, that worked (I also edited out a  tag)

but it's exceedingly tedious!

Is there a fix in the works?

Jim

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
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.
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [sage-support] new to sage/python and getting a syntax error

2012-07-08 Thread Jim Clark
There's an extra space character before the s =  line in the if t == 0: 
block.

On Jul 8, 2012, at 6:29 PM, Judson Wallace wrote:

> Euler's method for a  differential 
> ... i am only interested in writting the information if its at one of these 
> values... problem is, i keep getting a syntax error with the if/then 
> statements
> 
> 
> 
> fout = open('/selftest.txt','w')
> var('t y')
> f(t,y) = 5-3*y^(1/2)
> t = 0.0
> y = 2.0
> steps = 60
> h = 0.05
> for i in range(steps +1):
>if t == 0:  
> print 'i=', i, 't=', t, 'y=', y
>s ='i='+repr(i)+' t='+repr(t)+' y='+repr(y) +'\n'  <== extra space 
> before s =
> fout.write(s)
> y = (f(t,y)*h)+y
> t = t+h
>elif (t == 1.0):  
> print 'i=', i, 't=', t, 'y=', y
> s ='i='+repr(i)+' t='+repr(t)+' y='+repr(y) +'\n'
> fout.write(s)
> y = (f(t,y)*h)+y
> t = t+h
>elif (t == 1.5):  
> print 'i=', i, 't=', t, 'y=', y
> s ='i='+repr(i)+' t='+repr(t)+' y='+repr(y) +'\n'
> fout.write(s)
> y = (f(t,y)*h)+y
> t = t+h
>else:
> y = (f(t,y)*h)+y  
> t = t+h   
> 
> fout.close()

-- 
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] Sage crash report

2012-05-22 Thread Jim Clark
133 optimization.disable_optimization()
134 
135 _build_ext.build_ext.run(self)
136 
137 def build_extensions(self):
138 # First, sanity-check the 'extensions' list
139 self.check_extensions_list(self.extensions)
140 
141 for ext in self.extensions:
142 ext.sources = self.cython_sources(ext.sources, ext)
--> 143 self.build_extension(ext)
144 
145 def cython_sources(self, sources, extension):
146 """
147 Walk the list of source files in 'sources', looking for Cython
148 source files (.pyx and .py).  Run Cython on all that are
149 found, and return a modified 'sources' list with Cython source
150 files replaced by the generated C (or C++) files.
151 """
152 try:
153 from Cython.Compiler.Main \
154 import CompilationOptions, \
155default_options as pyrex_default_options, \
156compile as cython_compile
157 from Cython.Compiler.Errors import PyrexError
158 except ImportError:

/Applications/sage/local/lib/python/distutils/command/build_ext.pyc in 
build_extension(self=, 
ext=)
484 # The environment variable should take precedence, and
485 # any sensible compiler will give precedence to later
486 # command line args.  Hence we combine them in order:
487 extra_args = ext.extra_compile_args or []
488 
489 macros = ext.define_macros[:]
490 for undef in ext.undef_macros:
491 macros.append((undef,))
492 
493 objects = self.compiler.compile(sources,
494  output_dir=self.build_temp,
495  macros=macros,
496  include_dirs=ext.include_dirs,
497  debug=self.debug,
498  extra_postargs=extra_args,
--> 499  depends=ext.depends)
500 
501 # XXX -- this is a Vile HACK!
502 #
503 # The setup.py script for Python on Unix needs to be able to
504 # get this list so it can perform all the clean up needed to
505 # avoid keeping object files around when cleaning out a failed
506 # build of an extension module.  Since Distutils does not
507 # track dependencies, we have to get rid of intermediates to
508 # ensure all the intermediates will be properly re-built.
509 #
510 self._built_objects = objects[:]
511 
512 # Now link the object files together into a "shared object" --
513 # of course, first we have to figure out all the other things
514 # that go into the mix.

/Applications/sage/local/lib/python/distutils/ccompiler.pyc in 
compile(self=, 
sources=['/Users/jim/.pyxbld/temp.macosx-10.6-x86_64-2.7/pyrex/sage/libs/flint/flint.c'],
 output_dir='/Users/jim/.pyxbld/temp.macosx-10.6-x86_64-2.7', macros=[], 
include_dirs=[], debug=None, extra_preargs=None, extra_postargs=[], depends=[])
609 Raises CompileError on failure.
610 """
611 # A concrete compiler class can either override this method
612 # entirely or implement _compile().
613 
614 macros, objects, extra_postargs, pp_opts, build = \
615 self._setup_compile(output_dir, macros, include_dirs, 
sources,
616 depends, extra_postargs)
617 cc_args = self._get_cc_args(pp_opts, debug, extra_preargs)
618 
619 for obj in objects:
620 try:
621 src, ext = build[obj]
622 except KeyError:
623 continue
--> 624 self._compile(obj, src, ext, cc_args, extra_postargs, 
pp_opts)
625 
626 # Return *all* object filenames, not just the ones we just 
built.
627 return objects
628 
629 def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts):
630 """Compile 'src' to product 'obj'."""
631 
632 # A concrete compiler class that does not override compile()
633 # should implement _compile().
634 pass
635 
636 def create_static_lib(self, objects, output_libname, 
output_dir=None,
637   debug=0, target_lang=None):
638 """Link a bunch of stuff together to create a static library 
file.
639 The "bunch 

Re: [sage-support] Re: Sage 5.0 crashing, is unusable

2012-05-19 Thread Jim Clark
On May 19, 2012, at 7:34 PM, kcrisman wrote:

> 
>> here is a fix:
>> in SAGE_ROOT (the directiry where Sage startup script, called sage, is), run
>> ./sage -f 
>> http://boxen.math.washington.edu/home/jdemeyer/spkg/mpir-2.4.0.p4.spkg
>> this will install a patched MPIR  spkg.
> 
> 
> I get an interesting warning when doing this on a similar machine.
> 
> Successfully installed mpir-2.4.0.p4
> cat: /Users/.../sage/VERSION.txt: No such file or directory
> Deleting temporary build directory
> /Users/.../sage/spkg/build/mpir-2.4.0.p4
> Making Python scripts relocatable...
> Finished installing mpir-2.4.0.p4.spkg
> 
> And indeed, my Sage binary has no VERSION.txt in the SAGE_ROOT directory.
>  

I had not noticed the warning when I rebuilt mpir,
but my SAGE_ROOT directory also lacks VERSION.txt 

But when I start sage, it reports:

./sage
--
| Sage Version 5.0, Release Date: 2012-05-14 |

so sage seems to know which version it is. What is the role of VERSION.txt ?

Jim

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


Re: [sage-support] Re: Sage 5.0 crashing, is unusable

2012-05-19 Thread Jim Clark
As original creator of this thread, I followed the process described below.
I confirm that the original problem I reported has been resolved;
sage 5.0 is now usable for my projects.

Thank you Dima and all of the other team members who contributed to this 
solution!
Jim Clark

On May 19, 2012, at 6:16 AM, Dima Pasechnik wrote:

> here is a fix:
> in SAGE_ROOT (the directiry where Sage startup script, called sage, is), run
> ./sage -f 
> http://boxen.math.washington.edu/home/jdemeyer/spkg/mpir-2.4.0.p4.spkg
> this will install a patched MPIR  spkg.
> Then run
> ./sage -b
> to rebuild parts of Sage which depend upon MPIR (it takes a while, perhaps 15 
> minutes or so).
> 
> After this, Sage works as it should. The problem appears to be due to Core2 
> processors 
> (e.g. in some Macbooks Air) being unable to run certain instructions that 
> they are expected to run, and so
> an executable built on a "better" processor is unaware of this.
>  
> 
> On Thursday, 17 May 2012 01:11:05 UTC+2, Jim wrote:
> Hello sage team. 
> 
> I have just downloaded and installed Sage 5.0 on my system: 
> 
> Mac OS X 10.6.8 
> 
> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg. 
> 
> It keeps crashing and is unusable. 
> 
> Here is a simple session: 
> 
> -- 
> | Sage Version 5.0, Release Date: 2012-05-14 | 
> | Type notebook() for the GUI, and license() for information.| 
> -- 
> sage: # Feather parameters 
> sage: L_lv = 1300# length of leading vane in microns 
> sage: L_tv = 2300# length of trailing vane 
> sage: L_tot = L_lv + L_tv 
> sage: shaft_cenx = L_lv  # center of shaft 
> sage: shaft_ceny = 0 
> sage: R_shaft = 185  # radius of shaft 
> sage: dx = 10# nominal spacing between grid points 
> sage: T_v1 = 10  # thickness of vane at edge 
> sage: T_v2 = 20  # thickness near center 
> sage: L_planar_lv = int(L_lv * .75)# length of planar segment of vane 
> 
>  
> Unhandled SIGILL: An illegal instruction occurred in Sage. 
> This probably occurred because a *compiled* component of Sage has a bug 
> in it and is not properly wrapped with sig_on(), sig_off(). You might 
> want to run Sage under gdb with 'sage -gdb' to debug this. 
> Sage will now terminate. 
>  
> /Applications/sage/spkg/bin/sage: line 312:  1513 Illegal instruction 
> sage-ipython "$@" -i 
> logout 

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


Re: [sage-support] Re: How to enable interactive matplotlib

2012-05-17 Thread Jim Clark
On May 17, 2012, at 7:11 PM, Keshav Kini wrote:

>> building 'matplotlib.backends._macosx' extension
>> gcc -DNDEBUG -g -fwrapv -O3 -Wall -O2 -g -m64 -DPY_ARRAY_UNIQUE_SYMBOL=
>> MPL_ARRAY_API -DPYCXX_ISO_CPP_LIB=1 -I/Applications/sage-5.0/local/lib/
>> python2.7/site-packages/numpy/core/include -I/Applications/sage-5.0/local/
>> include -I. -I/Applications/sage-5.0/local/lib/python2.7/site-packages/numpy/
>> core/include -Isrc -Iagg24/include -I. 
>> -I/Applications/sage-5.0/local/include/
>> python2.7 -c src/_macosx.m -o build/temp.macosx-10.6-x86_64-2.7/src/_macosx.o
>> gcc: error: src/_macosx.m: Objective-C compiler not installed on this system
> 
> This is a known problem. As far as I know there is no solution yet,
> other than to make sure that when compiling Sage you have a sufficiently
> new and complete GCC that Sage does not bootstrap one - I am not sure of
> the details. See
> https://groups.google.com/d/msg/sage-release/cloOmbv38zk/p76HQCqC6SwJ .
> 
> -Keshav

Thanks for the response, Keshav. I use the gcc that Apple provides; as far as I 
know, sage does not need to bootstrap one for OS X.

I do have a workaround: I normally save all of my matplotlib plots to a file in 
addition to viewing them interactively;
this problem means that I will need to open the files manually in order to view 
my plots, until such time as a solution
is found for this problem.

Jim

-- 
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] How to enable interactive matplotlib

2012-05-17 Thread Jim Clark
Hello everyone,

I have built sage 5.0 from source and want to use matplotlib interactively.

I have followed the instructions in http://wiki.sagemath.org/sage_matlab

This process worked for me in sage 4.8. Now, however, at step 9
(Now rebuild matplotlib again with "sage -f matplotlib". It should build 
cleanly now.)

It doesn't build cleanly. Here is the error report:

ld: warning: directory '/Users/jim/sage/sage-5.0/local/lib' following -L not 
found
building 'matplotlib.backends._macosx' extension
gcc -DNDEBUG -g -fwrapv -O3 -Wall -O2 -g -m64 
-DPY_ARRAY_UNIQUE_SYMBOL=MPL_ARRAY_API -DPYCXX_ISO_CPP_LIB=1 
-I/Applications/sage-5.0/local/lib/python2.7/site-packages/numpy/core/include 
-I/Applications/sage-5.0/local/include -I. 
-I/Applications/sage-5.0/local/lib/python2.7/site-packages/numpy/core/include 
-Isrc -Iagg24/include -I. -I/Applications/sage-5.0/local/include/python2.7 -c 
src/_macosx.m -o build/temp.macosx-10.6-x86_64-2.7/src/_macosx.o
gcc: error: src/_macosx.m: Objective-C compiler not installed on this system
error: command 'gcc' failed with exit status 1
Error building matplotlib package.

real1m10.565s
user0m58.168s
sys 0m4.852s

Error installing package matplotlib-1.1.0

Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the relevant part of the log file
  /Applications/sage-5.0/spkg/logs/matplotlib-1.1.0.log
Describe your computer, operating system, etc.

I'm running Mac OS X 10.6.8

(Background: I started the thread yesterday "[sage-support] Sage 5.0 crashing, 
is unusable"
which resulted in the trac ticket 
http://trac.sagemath.org/sage_trac/ticket/12954
I am not the only person reporting this problem.)
So I have built sage 5.0 from source, and it now works, except for the 
matplotlib interactive calls.

Thanks in advance for any help provided.

Jim Clark

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


Re: [sage-support] Re: Sage 5.0 crashing, is unusable

2012-05-17 Thread Jim Clark
On May 17, 2012, at 8:08 AM, Keshav Kini wrote:

>>> Why not just look at the md5 checksum? That would have saved you
>>> downloading it a second time, and you would be 99.999 (not sure
>>> how many 9s) percent sure the file is not corrupted.
>> 
>> Why?  Because I don't know how to apply the checksum to test the downloaded 
>> file.
> 
> For future reference, run `md5sum ` in a terminal to check the
> MD5 sum of a file.

Thank you Keshav. This is helpful. I will file this away in my list of helpful 
things to know.
Jim

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-17 Thread Jim Clark
On May 17, 2012, at 6:05 AM, David Kirkby wrote:

>> Update: I downloaded and installed sage 5.0 again.
>> 
>> The sequence of commands below induces the same SIGILL crash.
>> 
>> I find it hard to blame a defective download.
> 
> Why not just look at the md5 checksum? That would have saved you
> downloading it a second time, and you would be 99.999 (not sure
> how many 9s) percent sure the file is not corrupted.

Why?  Because I don't know how to apply the checksum to test the downloaded 
file.

Jim

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
On May 16, 2012, at 6:30 PM, Volker Braun wrote:

> Its a Penryn Core 2 Duo, should support everything up to SSE4.1.
> 
> Can you run "sage -gdb", cause the crash, and then type "bt" into gdb? This 
> will print more detailed information about where it crashes.
> 
> 
Here's the transcript:

sage: L_lv = 1300# length of leading vane in microns
sage:  L_planar_lv = int(L_lv * .75)# length of planar segment of vane

Program received signal EXC_BAD_INSTRUCTION, Illegal instruction/operand.
0x0001016e3ed9 in case1 ()
(gdb) bt
#0  0x0001016e3ed9 in case1 ()
#1  0x000103e3cba4 in parsed_string_to_mpfr ()
#2  0x000103e3d7fb in mpfr_strtofr ()
Previous frame inner to this frame (gdb could not unwind past this frame)
(gdb) 



As D.S. McNeil pointed out, the problem seems to be with int() with a 
non-integer argument.

I got my provocation of the error down to the two statements shown in the 
transcript.

Thank you, and good luck!
Jim

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
On May 16, 2012, at 4:11 PM, Jim Clark wrote:

> I have just downloaded and installed Sage 5.0 on my system:
> 
> Mac OS X 10.6.8
> 
> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg.
> 
> It keeps crashing and is unusable.

Here's where I first experienced the problem.

In a long piece of code running in the notebook, the following line works:

pts.show(axes_labels = (r"$x (\mu)$", r"$y (\mu)$"), figsize = (8, 2))

I changed the 2 in the figsize parameter to 1.5:

pts.show(axes_labels = (r"$x (\mu)$", r"$y (\mu)$"), figsize = (8, 1.5))

and instead of a plot, I get

   

Unhandled SIGILL: An illegal instruction occurred in Sage.
This probably occurred because a *compiled* component of Sage has a bug
in it and is not properly wrapped with sig_on(), sig_off(). You might
want to run Sage under gdb with 'sage -gdb' to debug this.
Sage will now terminate.


and in the Terminal window from which I invoked notebook() is the messge:

2012-05-16 17:33:43-0700 [HTTPChannel,3,127.0.0.1] 
2012-05-16 17:36:28-0700 [HTTPChannel,3,127.0.0.1] got EOF subprocess must have 
crashed...
2012-05-16 17:36:28-0700 [HTTPChannel,3,127.0.0.1] 

The notebook keeps running and I seem to be able to exit from the notebook and 
from sage normally.

Is there a log file somewhere that provides more data?

Jim

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
Hardware Overview:

  Model Name:   iMac
  Model Identifier: iMac9,1
  Processor Name:   Intel Core 2 Duo
  Processor Speed:  2.66 GHz
  Number Of Processors: 1
  Total Number Of Cores:2
  L2 Cache: 6 MB
  Memory:   2 GB
  Bus Speed:1.07 GHz
  Boot ROM Version: IM91.008D.B08
  SMC Version (system): 1.36f3
  Serial Number (system):   W8905GVT0TF
  Hardware UUID:9D23EB65-097B-5851-8E10-79F393005D7A


On May 16, 2012, at 5:28 PM, Volker Braun wrote:

> Which CPU do you have? e.g. the output of the "system_profiler" command.
> 
> 
> 
> On Wednesday, May 16, 2012 8:14:39 PM UTC-4, Jim wrote:
> On May 16, 2012, at 4:43 PM, William Stein wrote: 
> 
> >>> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg. 
> > 
> > Do you have a 6-4bit computer and OS install?  The error message means 
> > that there is some sort of architecture mismatch between the binary 
> > and your computer. 
> > 
> > 
> Yes, it's a 64-bit computer. 
> 
> I've been running from  sage-4.8-OSX-64bit-10.6-x86_64-Darwin.dmg for months. 

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
Update: I downloaded and installed sage 5.0 again.

The sequence of commands below induces the same SIGILL crash.

I find it hard to blame a defective download.

Are there any other tests I can perform to get to the bottom of this?

Jim
On May 16, 2012, at 4:11 PM, Jim Clark wrote:

> Hello sage team.
> 
> I have just downloaded and installed Sage 5.0 on my system:
> 
> Mac OS X 10.6.8
> 
> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg.
> 
> It keeps crashing and is unusable.
> 
> Here is a simple session:
> 
> --
> | Sage Version 5.0, Release Date: 2012-05-14 |
> | Type notebook() for the GUI, and license() for information.|
> --
> sage: # Feather parameters
> sage: L_lv = 1300# length of leading vane in microns
> sage: L_tv = 2300# length of trailing vane
> sage: L_tot = L_lv + L_tv
> sage: shaft_cenx = L_lv  # center of shaft
> sage: shaft_ceny = 0
> sage: R_shaft = 185  # radius of shaft
> sage: dx = 10# nominal spacing between grid points
> sage: T_v1 = 10  # thickness of vane at edge
> sage: T_v2 = 20  # thickness near center
> sage: L_planar_lv = int(L_lv * .75)# length of planar segment of vane
> 
> 
> Unhandled SIGILL: An illegal instruction occurred in Sage.
> This probably occurred because a *compiled* component of Sage has a bug
> in it and is not properly wrapped with sig_on(), sig_off(). You might
> want to run Sage under gdb with 'sage -gdb' to debug this.
> Sage will now terminate.
> 
> /Applications/sage/spkg/bin/sage: line 312:  1513 Illegal instruction     
> sage-ipython "$@" -i
> logout
> 
> 
> I'm going to reinstall sage 4.8; I can't get any work done with 5.0.
> 
> Jim Clark

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
On May 16, 2012, at 4:43 PM, William Stein wrote:

>>> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg.
> 
> Do you have a 6-4bit computer and OS install?  The error message means
> that there is some sort of architecture mismatch between the binary
> and your computer.
> 
> 
Yes, it's a 64-bit computer.

I've been running from  sage-4.8-OSX-64bit-10.6-x86_64-Darwin.dmg for months.

Jim

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


Re: [sage-support] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
Actually, this behavior is so severe, I can't imagine it escaped the attention 
of testers.

I'm going to download sage 5.0 again, suspecting that my downloaded file is 
defective.

Please stand by...

Jim
On May 16, 2012, at 4:11 PM, Jim Clark wrote:

> Hello sage team.
> 
> I have just downloaded and installed Sage 5.0 on my system:
> 
> Mac OS X 10.6.8
> 
> I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg.
> 
> It keeps crashing and is unusable.
> 
> Here is a simple session:
> 
> --
> | Sage Version 5.0, Release Date: 2012-05-14 |
> | Type notebook() for the GUI, and license() for information.|
> --
> sage: # Feather parameters
> sage: L_lv = 1300# length of leading vane in microns
> sage: L_tv = 2300# length of trailing vane
> sage: L_tot = L_lv + L_tv
> sage: shaft_cenx = L_lv  # center of shaft
> sage: shaft_ceny = 0
> sage: R_shaft = 185  # radius of shaft
> sage: dx = 10# nominal spacing between grid points
> sage: T_v1 = 10  # thickness of vane at edge
> sage: T_v2 = 20  # thickness near center
> sage: L_planar_lv = int(L_lv * .75)# length of planar segment of vane
> 
> 
> Unhandled SIGILL: An illegal instruction occurred in Sage.
> This probably occurred because a *compiled* component of Sage has a bug
> in it and is not properly wrapped with sig_on(), sig_off(). You might
> want to run Sage under gdb with 'sage -gdb' to debug this.
> Sage will now terminate.
> 
> /Applications/sage/spkg/bin/sage: line 312:  1513 Illegal instruction 
> sage-ipython "$@" -i
> logout
> 
> 
> I'm going to reinstall sage 4.8; I can't get any work done with 5.0.
> 
> Jim Clark

-- 
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] Sage 5.0 crashing, is unusable

2012-05-16 Thread Jim Clark
Hello sage team.

I have just downloaded and installed Sage 5.0 on my system:

Mac OS X 10.6.8

I downloaded sage-5.0-OSX-64bit-10.6-x86_64-Darwin.dmg.

It keeps crashing and is unusable.

Here is a simple session:

--
| Sage Version 5.0, Release Date: 2012-05-14 |
| Type notebook() for the GUI, and license() for information.|
--
sage: # Feather parameters
sage: L_lv = 1300# length of leading vane in microns
sage: L_tv = 2300# length of trailing vane
sage: L_tot = L_lv + L_tv
sage: shaft_cenx = L_lv  # center of shaft
sage: shaft_ceny = 0
sage: R_shaft = 185  # radius of shaft
sage: dx = 10# nominal spacing between grid points
sage: T_v1 = 10  # thickness of vane at edge
sage: T_v2 = 20  # thickness near center
sage: L_planar_lv = int(L_lv * .75)# length of planar segment of vane


Unhandled SIGILL: An illegal instruction occurred in Sage.
This probably occurred because a *compiled* component of Sage has a bug
in it and is not properly wrapped with sig_on(), sig_off(). You might
want to run Sage under gdb with 'sage -gdb' to debug this.
Sage will now terminate.

/Applications/sage/spkg/bin/sage: line 312:  1513 Illegal instruction 
sage-ipython "$@" -i
logout


I'm going to reinstall sage 4.8; I can't get any work done with 5.0.

Jim Clark

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


Re: [sage-support] issues with if statements in a loop.

2012-03-30 Thread Jim Clark
On Mar 30, 2012, at 9:41 AM, Eric Kangas wrote:

> Hi,
> 
> I am trying to find the values, and locations of those values in a sequence 
> of numbers. I have written up code that I thought would work, but it doesn't. 
> Here is the code:
> 
> l31 = [len(l3[i]) for i in range(a/len(l))];
> l32 = [];
> l33 = [if x=6: l32.append((x,l31[x])) for x in l31];
> 
> I get the normal invalid syntax error. What am I missing in this code for the 
> line with l33 = ?
> 
When I encountered a similar problem (an if-statement in a list comprehension), 
I eventually solved my problem with the python filter function — I suggest you 
look it up.

I wish you well.
Jim Clark

-- 
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] numpy vectorize and cython

2012-03-22 Thread Jim Clark
Hello experts,

Running sage version 4.8 on Mac OS X 10.6.8.
I am attempting to cython-ize a sage script that applies numpy, but I can't get 
cython to compile numpy.vectorize — the error message is

ValueError: failed to determine the number of arguments for 

Is this a bug in cython, or am I mis-applying numpy and cython?

The test script (test.spyx) that produces this error is

import numpy as np
cimport numpy as np
gamma = 1.4
def pressure(rho, u, v, rho_E): return (gamma - 1) * (rho_E - rho * (u * u + v 
* v) / 2.)
vpressure = np.vectorize(pressure, otypes = [np.float], \
 doc = "Vectorized pressure(rho, u, v, rho*E)")

and the full error traceback when I invoke sage: load("test.spyx") is:

Compiling /Users/jim/Documents/Fluid_Mechanics/AA543_HW5/test.spyx...
---
ValueErrorTraceback (most recent call last)

/Users/jim/ in ()

/Applications/sage/local/lib/python2.6/site-packages/sage/structure/sage_object.so
 in sage.structure.sage_object.load (sage/structure/sage_object.c:7715)()

/Applications/sage/local/lib/python2.6/site-packages/sage/misc/preparser.pyc in 
load(filename, globals, attach)
   1648 elif fpath.endswith('.spyx') or fpath.endswith('.pyx'):
   1649 import interpreter
-> 1650 exec(interpreter.load_cython(fpath), globals)
   1651 elif fpath.endswith('.m'):
   1652 # Assume magma for now, though maybe .m is used by maple and

/Users/jim/ in ()

/Users/jim/_Users_jim_Documents_Fluid_Mechanics_AA543_HW5_test_spyx_1.pyx in 
init _Users_jim_Documents_Fluid_Mechanics_AA543_HW5_test_spyx_1 
(_Users_jim_Documents_Fluid_Mechanics_AA543_HW5_test_spyx_1.c:3322)()
  7 cimport numpy as np
  8 gamma = 1.4
  9 def pressure(rho, u, v, rho_E): return (gamma - 1) * (rho_E - rho * (u 
* u + v * v) / 2.)
---> 10 vpressure = np.vectorize(pressure, otypes = [np.float], \
 11  doc = "Vectorized pressure(rho, u, v, rho*E)")

/Applications/sage/local/lib/python2.6/site-packages/numpy/lib/function_base.pyc
 in __init__(self, pyfunc, otypes, doc)
   1767 self.thefunc = pyfunc
   1768 self.ufunc = None
-> 1769 nin, ndefault = _get_nargs(pyfunc)
   1770 if nin == 0 and ndefault == 0:
   1771 self.nin = None

/Applications/sage/local/lib/python2.6/site-packages/numpy/lib/function_base.pyc
 in _get_nargs(obj)
   1699 
   1700 raise ValueError(
-> 1701 "failed to determine the number of arguments for %s" % 
(obj))
   1702 
   1703 

ValueError: failed to determine the number of arguments for 

Thank you,
Jim Clark

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


Re: [sage-support] Re: Error installing visualization software on OS X

2012-03-11 Thread Jim Clark
On Mar 10, 2012, at 11:08 PM, Dima Pasechnik wrote:

> > Can someone please provide accurate instructions for installing vtk?
> Thank you for your report.
> 
> It seems that vtk support in sage has been
> abandoned for quite some timei (like, 4 years!). While there is still
> an experimental package vtk_meta-1.spkg, it would not work with a recent
> version of Sage on OSX, as there is no more python-***-framework package
> available for Sage. 
> Please note that vtk was always an experimental package, so it was never
> really supported.
> It would require some work to see if vtk (version 5.8 now) works with
> Sage, and if yes, how.
> We'll certainly update that hugely obsolete documenation soon, too.
> 
> This is now 
> http://trac.sagemath.org/sage_trac/ticket/12652 
> 
Thank you for your response and for creating the ticket in trac.
I will explore other means of creating the visualizations that I need.
Jim Clark

-- 
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] Error installing visualization software on OS X

2012-03-10 Thread Jim Clark
I want to install the visualization toolkit vtk into my sage on OS X 10.6.8. I 
am running sage 4.8.

Attempting to follow the instructions on 
http://www.sagemath.org/doc/numerical_sage/installation_osx.html

First of all, if I perform
cd $SAGE_ROOT/local/lib
rm libpng*.dylib
and then start sage, sage complains about not being able to find the libraries 
I just removed.

I reinstalled sage, started it first, then deleted the library files in a 
separate Terminal window.

Next I issued (and received the response following)
sage: install_package('python-2.5.1-framework')
---
ValueErrorTraceback (most recent call last)

/Users/jim/ in ()

/Applications/sage/local/lib/python2.6/site-packages/sage/misc/package.pyc in 
install_package(package, force)
153 if is_package_installed(package):
154 raise ValueError, "Package is already installed. Try 
install_package('%s',force=True)"%(package)
--> 155 raise ValueError, "There is no package name starting with 
'%s'."%(package)
156 os.system('sage -f "%s"'%(L[0]))
157 __installed_packages = None

ValueError: There is no package name starting with 'python-2.5.1-framework'.


I tried again with parameter force=True as suggested in the traceback, but that 
produced exactly the same traceback.

Can someone please provide accurate instructions for installing vtk?

Thank you,
Jim Clark

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


Re: [sage-support] Overriding default browser

2012-03-05 Thread Jim Clark
On Mar 5, 2012, at 2:06 PM, Justin C. Walker wrote:

> Terminal starts a login shell for each window/tab that it opens, so your 
> intuition needs a little polishing :-}  Think of Terminal as a glorified 
> xterm, in that all the windows belong to one Terminal, rather than each xterm 
> owning one window.

Thanks, Justin, for helping with the polishing. I'm learning more about 
Terminal than I ever wanted to know — I just want to get on with using Sage to 
solve the problem I'm working on.
Jim

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


Re: [sage-support] Overriding default browser

2012-03-05 Thread Jim Clark
On Mar 5, 2012, at 12:49 PM, Justin C. Walker wrote:

> To clarify this, I believe that the man page says that .bash_profile is 
> checked for a login shell, and that .bashrc is checked for a non-login, 
> interactive shell.
> 
> I'm not at a 10.6 system right now to verify that, but it is the case on 
> 10.7, and I have my "profile/rc" set up with that assumption on both 10.6 and 
> 10.7.

Thanks, Mr. Curmudgeon ;-)

That is indeed what I read in the man page, but my intuitive sense is that 
Terminal should open a "non-login, interactive shell" — after all, I am able to 
start entering UNIX commands interactively, and the shell does not prompt for a 
login. But when I actually try it out, the contents of .bashrc have no effect 
in Terminal/bash, but the contents of .bash_profile are processed. I conclude 
that something about a deeper understanding of Mac OS X and/or UNIX is eluding 
me.

Jim

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


Re: [sage-support] Re: Overriding default browser

2012-03-05 Thread Jim Clark
On Mar 5, 2012, at 8:57 AM, John H Palmieri wrote:

> This works for me:
> 
>   export SAGE_BROWSER='open -a /Applications/Firefox.app'
> 
> (Change this to the path to the firefox app, if necessary.) The documentation 
> apparently needs to be fixed, at least as far as OS X is concerned.
> 
> Oh, a few more things, in case people are reading this who aren't that 
> familiar with the Terminal app and bash: you can give the command
> 
>   export SAGE_BROWSER='open -a /Applications/Firefox.app'
> 
> at the shell prompt and it will have immediate effect, so you can test it 
> right away.  Second, if you instead change .bashrc, you should start a new 
> terminal window for the changes to take effect. You can test whether it has 
> done anything by typing 'export' and seeing if SAGE_BROWSER is listed with 
> the appropriate setting.

Thanks for your help, John.

It turned out to be more complicated, trying to understand the deep mysteries 
of the bash shell and how Terminal is configured on my system. In spite of what 
the man page for bash says, Terminal seems to be ignoring the .bashrc file in 
my home directory, and instead reads .bash_profile. I was finally able to get 
Sage and notebook() to start Firefox by putting the export SAGE_BROWSER line 
into .bash_profile, not .bashrc.

This has taken much more time than I hoped for, but at least my problem is now 
solved.

Jim

-- 
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] Overriding default browser

2012-03-05 Thread Jim Clark
I am running Sage 4.8 on Mac OS X 10.6.8.

I have been using Safari as my default browser, but I am getting discouraged 
because Safari crashes frequently.

All of my bookmarks and ways of browsing the web are in Safari, so I want to 
keep Safari as my default browser,
but I am switching to Firefox when using Sage.

According to the Sage document 
http://www.sagemath.org/doc/reference/sagenb/notebook/notebook_object.html
I can override the default browser by putting export SAGE_BROWSER="firefox"
in the file .bashrc in my home directory. This I have done. It has no effect. 
When I issue the command notebook() at the sage: prompt, the notebook still 
starts up in Safari. I have to kill Safari and then start Firefox manually 
(where I have set my home page to be http://localhost:8000).

It's annoying. Is there any way to get this documented feature to work as 
advertised?

Thank you,
Jim Clark

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


Re: [sage-support] Re: Syntax error attempting to load a python file

2012-01-20 Thread Jim Clark
On Jan 20, 2012, at 5:05 PM, Nils Bruin wrote:

> On Jan 20, 4:30 pm, Jim Clark  wrote:
>> Could anyone shed light on what is happening here?
>> 
>> In a sage notebook cell I wish to load a python file; I wrote the command:
>> 
>> load("/Users/jim/Documents/Fluid_Mechanics/AA543_HW2/physical_constants.py")
>> 
>> which produces:
>> 
>> SyntaxError: Non-ASCII character '\xce' in file
>> /Users/jim/Documents/Fluid_Mechanics/AA543_HW2/physical_constants.py on
> 
> If you type the following in a notebook cell:
> --
> %sh
> xxd -g1 /Users/jim/Documents/Fluid_Mechanics/AA543_HW2/
> physical_constants.py | head
> --
> you'll see all first few bytes in your file. It should be pretty
> straightforward to spot the "ce" from that.
> 
Thank you, Nils, that revealed the problem.

The file in the path was an alias, created in Finder, and OS X added the link 
info at the beginning of the file.

I replaced the OS X alias with a Unix symbolic link, and now I can load the 
file.

again, thanks,
Jim

-- 
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] Syntax error attempting to load a python file

2012-01-20 Thread Jim Clark
Could anyone shed light on what is happening here?

In a sage notebook cell I wish to load a python file; I wrote the command:

load("/Users/jim/Documents/Fluid_Mechanics/AA543_HW2/physical_constants.py")

which produces:

SyntaxError: Non-ASCII character '\xce' in file
/Users/jim/Documents/Fluid_Mechanics/AA543_HW2/physical_constants.py on
line 2, but no encoding declared; see
http://www.python.org/peps/pep-0263.html for details

I am unable to find the offending character in the file. In fact I deleted the 
first 20 lines of the file (it contains only variable definitions) and I still 
get the same error pointing to "line 2".

I have used the load command successfully in the past with a different python 
file.

Running sage 4.7.2 on an iMac with OS X 10.6.8

Thanks in advance for any insights.
Jim Clark

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


Re: [sage-support] Trouble Installing and Running Sage 4.6 on my MacBook

2011-02-21 Thread Jim Clark
Hello Ken,

Did the drag and drop operation complete successfully?
You must watch the operation carefully; occasionally files do not copy.
If an error occurs, there is a README file (perhaps with OSX in the filename) 
in the .dmg file that provides instructions for copying with the cp command in 
a Terminal window.

I don't have insight into the specific error message you report.
Jim Clark

On Feb 21, 2011, at 11:01 AM, kmcmu...@ramapo.edu wrote:

> Hi, I just downloaded this version of SAGE: 
> 
> sage-4.6-OSX-32bit-10.4-i386-Darwin.dmg 
> 
> and attempted to install it on my macbook pro with Intel Core 2 Duo, running 
> Mac OS X 10.4.11. After 
> 
> (1) dragging and dropping the sage folder from dmg into Applications 
> (2) Double-Clicking on the new sage icon 
> (3) Selecting "Terminal" and Clicking on "Update" 
> 
> I got this error message in the newly opened terminal window: 
> 
> Last login: Mon Feb 21 11:35:40 on ttyp1 
> /Applications/sage/sage; exit 
> Welcome to Darwin! 
> macbook:~ kmcmurdy$ /Applications/sage/sage; exit 
> -- 
>  
> | Sage Version 4.6, Release Date: 2010-10-30 | 
> | Type notebook() for the GUI, and license() for information.| 
> -- 
>  
> The Sage install tree may have moved 
> (from /Users/Shared/sage/sage-4.6 to /Applications/sage) 
> Changing various hardcoded paths 
> (please wait at most a few minutes)... 
> Do not interrupt this. 
> Done resetting paths 
> Traceback (most recent call last): 
>  File "/Applications/sage/local/bin/sage-cleaner", line 100, in  
>setup_daemon() 
>  File "/Applications/sage/local/bin/sage-cleaner", line 94, in setup_daemon 
>pid = open(pidfile).read() 
> IOError: [Errno 22] Invalid argument 

-- 
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: Sage 4.1.2 Problem HTML cell Latex arrays 2X2 no longer work

2009-10-23 Thread Jim Clark

This problem (+ another problem that I did not describe) has been  
solved in alpha.sagenb.org.
Verified with both Safari and Firefox browsers.

Thanks for your efforts!
Jim Clark

On Oct 22, 2009, at 7:58 PM, William Stein wrote:

> On Thu, Oct 22, 2009 at 1:48 PM, Jim Clark  
>  wrote:
>>
>> Here's another case that was working in the tinyMCE cell in Sage 4.0,
>> produces the error "Couldn't find \end for begin{cases}" in Sage  
>> 4.1.2,
>> but works in a normal (html) cell:
>>
>> %html
>> For the potential defined by:$$ V(x) = \begin{cases}
>>
>> 0 & 0 \leq x \leq a\cr
>>
>> \infty & x<0, x > a
>>
>> \end{cases}$$
>>
>> the stationary state solutions are $\psi_n(x) = \sqrt{\frac{2}{a}} 
>> \sin
>> {\frac{n \pi x}{a}}$.
>
> Hello,
>
> Thanks for reporting this.  It is now fixed in the new alpha version
> of the notebook (which will be released soon).
>
> By the way, I've setup
>
> http://alpha.sagenb.org/
>
> with the new notebook server, so you can confirm that the problem  
> is fixed.
>
> You might want to test http://alpha.sagenb.org/.  In particular, try
> opening the same page in two different browser, and see whether you
> get massive corruption or not.


--~--~-~--~~~---~--~~
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: Sage 4.1.2 Problem HTML cell Latex arrays 2X2 no longer work

2009-10-22 Thread Jim Clark

Here's another case that was working in the tinyMCE cell in Sage 4.0,
produces the error "Couldn't find \end for begin{cases}" in Sage 4.1.2,
but works in a normal (html) cell:

%html
For the potential defined by:$$ V(x) = \begin{cases}

0 & 0 \leq x \leq a\cr

\infty & x<0, x > a

\end{cases}$$

the stationary state solutions are $\psi_n(x) = \sqrt{\frac{2}{a}}\sin 
{\frac{n \pi x}{a}}$.

On Oct 22, 2009, at 9:42 AM, madison.mich...@gmail.com wrote:

> I frequently shift-click over a cell and define my problems over the
> cell using Latex.  On importing my old work sheets most of those look
> fine.  Arrays that are 1X2 are fine however all  of the 2x2 arrays
> don't wwork in the html cell. If I include the same Latex code inside
> my cell using html it works fine.
>
> Here is an example that does not work in the html cell, but works fine
> in a calculating cell.
>
> In the text/HTML cell this does not work:
>
> $ S = \left( \begin{array}{cc} 3.7 & 0.9 \\ 0.9 & 1.4 \end{array}
> \right) $.
>
>
> in a calculating cell this does work:
>
> html(r"$ S = \left( \begin{array}{cc} 3.7 & 0.9 \\ 0.9 & 1.4 \end
> {array} \right) $.")
>
> I think something is broken in the notebook.


--~--~-~--~~~---~--~~
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: problem with a couple definite integrals

2009-10-19 Thread Jim Clark

Thanks for the response, kcrisman. The questions you ask are exactly  
what I've
been pondering myself.
After much additional messing around, I found the problem (and its  
solution):

the factor in front should be 2/a, not a/2:

sage: var('a, n, x')
(a, n, x)
sage: assume(a>0)
sage: assume(n,'integer')
sage: integral(2/a * x * sin(n*pi*x/a)^2,x,0,a).simplify_full()
1/2*a

(I apologize for taking up bandwidth on this.)
Jim

On Oct 19, 2009, at 12:25 AM, kcrisman wrote:

> On Oct 19, 1:02 am, Jim Clark  wrote:
>> Hi sage supporters,
>>
>> I am attempting to verify some properties of the quantum mechanics
>> "particle in a box" problem.
>> integral() is returning the wrong results for  and .
>> I can't figure out what I might be doing wrong.
>>
>> To find :
>> - 
>> -
>> | Sage Version 4.1.2, Release Date:  
>> 2009-10-14   |
>> | Type notebook() for the GUI, and license() for  
>> information.|
>> - 
>> -
>> sage: var('a, n, x')
>> (a, n, x)
>> sage: assume(a > 0)
>> sage: assume(n, 'integer')
>> sage: integral(a/2 * x * sin(n*pi*x/a)^2,x,0,a).simplify_full()
>> 1/8*a^3
>>
>> The result should be a/2, which can almost be verified by inspection,
>> but I have worked out the integral by hand also, and I am  
>> confident that
>> a/2 is the correct result.
>
> Dear Jim,
>
> Hmm, I get the same answer as Sage with Wolfram Alpha.  Are you sure
> you typed this in correctly?  Don't forget to use u-substitution in
> calculating  - it looks like maybe something like that might
> account for the missing constants.
>
>
> Hope we can resolve this for you!
>
> - kcrisman


--~--~-~--~~~---~--~~
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] problem with a couple definite integrals

2009-10-18 Thread Jim Clark

Hi sage supporters,

I am attempting to verify some properties of the quantum mechanics  
"particle in a box" problem.
integral() is returning the wrong results for  and .
I can't figure out what I might be doing wrong.

To find :
--
| Sage Version 4.1.2, Release Date: 2009-10-14   |
| Type notebook() for the GUI, and license() for information.|
--
sage: var('a, n, x')
(a, n, x)
sage: assume(a > 0)
sage: assume(n, 'integer')
sage: integral(a/2 * x * sin(n*pi*x/a)^2,x,0,a).simplify_full()
1/8*a^3

The result should be a/2, which can almost be verified by inspection,
but I have worked out the integral by hand also, and I am confident that
a/2 is the correct result.

To find :
sage: integral(a/2 * x^2 * sin(n*pi*x/a)^2,x,0,a).simplify_full()
1/24*(2*pi^2*a^4*n^2 - 3*a^4)/(pi^2*n^2)

I believe that the correct result is 1/3*a^2.

However, sage does perform the indefinite integrals correctly:

sage: integral(x*sin(x)^2,x)
1/4*x^2 - 1/4*x*sin(2*x) - 1/8*cos(2*x)

(which I used to hand-calculate , getting the result a/2.)

and
sage: integral(x^2*sin(x)^2,x)
1/6*x^3 - 1/8*(2*x^2 - 1)*sin(2*x) - 1/4*x*cos(2*x)

I am running sage 4.1.2 on OS X 10.4 (compiled myself from source).

Thanks in advance for any insights!
Jim Clark

--~--~-~--~~~---~--~~
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: Cannot copy on OSX

2009-03-17 Thread Jim Clark

On Mar 17, 2009, at 4:57 PM, William Stein wrote:

>
> On Tue, Mar 17, 2009 at 4:55 PM, Jim Clark  
>  wrote:
>>
>> On Mar 17, 2009, at 4:45 PM, William Stein wrote:
>>
>>> Thanks for the offer.  But we release new sage versions every 1-2
>>> weeks (!), and having
>>> old binaries doesn't help much
>>>
>>> William
>>
>> But the binary that you offer at sagemath.org doesn't work,
>> as the originator of this thread reported and as Michael Abshoff  
>> and I
>> confirmed.
>
> In one week we will release a new version of Sage.  And another new
> one a week or two later, etc.  Are you going to physically deliver new
> binaries every week or two?
>
That's a good question, one I have not thought through.

As it is, you have not been providing OSX PPC binaries with every  
Sage release --
the previous one was for version 3.2.3 last November.

Do you know how much demand there is for OSX PPC binaries?

Would it help to provide new binaries at major releases, which seem  
to come every month or two,
not every one to two weeks? That's a way that I would be willing to  
help.

Jim

--~--~-~--~~~---~--~~
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
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Cannot copy on OSX

2009-03-17 Thread Jim Clark

On Mar 17, 2009, at 4:45 PM, William Stein wrote:

> Thanks for the offer.  But we release new sage versions every 1-2
> weeks (!), and having
> old binaries doesn't help much
>
> William

But the binary that you offer at sagemath.org doesn't work,
as the originator of this thread reported and as Michael Abshoff and I
confirmed.

Jim

--~--~-~--~~~---~--~~
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
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Cannot copy on OSX

2009-03-17 Thread Jim Clark

Hi Sage supporters,

I have now succeeded in building sage 3.4 for OSX 10.4 PowerPC (G3).

It copies, installs and runs successfully (on my two computers).

I live close to the UW; if one of you will give me directions to the  
Sage lab, I can
hand-deliver a sage 3.4 .dmg that I think will work for those of us  
with older iMacs.

(It's getting late in the day on Tuesday, Mar. 17, so the best  
arrangement for me
will be Wednesday a.m., but Tues. evening after 7 p.m. would also be  
o.k.)

Cheers!
Jim Clark

>
> On Mar 15, 2009, at 11:09 PM, mabshoff wrote:
>
>>>  
>>> -
>>> -
>>> | Sage Version 3.4, Release Date:
>>> 2009-03-11 |
>>> | Type notebook() for the GUI, and license() for
>>> information.|
>>>  
>>> -
>>> -
>>> The SAGE install tree may have moved.
>>> Regenerating Python.pyo and .pyc files that hardcode the install  
>>> PATH
>>> (please wait at
>>> most a few minutes)...
>>> Do not interrupt this.
>>
>>
>> 
>>
>>> ImportError: dlopen(/Applications/sage/local/lib/python2.5/site-
>>> packages/sage/misc/randstate.so, 2): Library not loaded: /tmp/fooo/
>>> sage-3.4/local/lib/libgmp.3.dylib
>>>Referenced from: /Applications/sage/local/lib//libcsage.dylib
>>>Reason: no suitable image found.  Did find:
>>> /Applications/sage/local/lib//libgmp.3.dylib: incompatible
>>> cpu-subtype
>>
>> This seems to be the trouble, i.e. the MPIR we build on OSX 10.4/PPC
>> is on a G4 and now seems to produce a library that does not run on a
>> G3. That might be caused by newer XCode releases, but I am not 100%
>> sure. I do not think that we changed anything inside MPIR that would
>> cause this.
>>
>

--~--~-~--~~~---~--~~
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
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Cannot copy on OSX

2009-03-16 Thread Jim Clark

On Mar 15, 2009, at 11:09 PM, mabshoff wrote:

>> - 
>> -
>> | Sage Version 3.4, Release Date:  
>> 2009-03-11 |
>> | Type notebook() for the GUI, and license() for  
>> information.|
>> - 
>> -
>> The SAGE install tree may have moved.
>> Regenerating Python.pyo and .pyc files that hardcode the install PATH
>> (please wait at
>> most a few minutes)...
>> Do not interrupt this.
>
>
> 
>
>> ImportError: dlopen(/Applications/sage/local/lib/python2.5/site-
>> packages/sage/misc/randstate.so, 2): Library not loaded: /tmp/fooo/
>> sage-3.4/local/lib/libgmp.3.dylib
>>Referenced from: /Applications/sage/local/lib//libcsage.dylib
>>Reason: no suitable image found.  Did find:
>> /Applications/sage/local/lib//libgmp.3.dylib: incompatible
>> cpu-subtype
>
> This seems to be the trouble, i.e. the MPIR we build on OSX 10.4/PPC
> is on a G4 and now seems to produce a library that does not run on a
> G3. That might be caused by newer XCode releases, but I am not 100%
> sure. I do not think that we changed anything inside MPIR that would
> cause this.
>
The next thing I will try is building from source -- I have not  
updated XCode.
It's just that "make" requires about 24 hours on my old, underpowered  
computer...

Jim


--~--~-~--~~~---~--~~
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
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Cannot copy on OSX

2009-03-16 Thread Jim Clark

Thanks for the response, Michael.


On Mar 15, 2009, at 11:09 PM, mabshoff wrote:

> On Mar 15, 5:04 pm, Jim Clark  wrote:
>> On Mar 14, 2009, at 4:52 PM, mabshoff wrote:
>> I have downloaded both Michael's .dmg and the one from http://
>> sage.math.washington.edu/sage/osx/powerpc/index.html
>>
>> In both cases, after I start sage, it fails as follows:
>> (My computer is a 300 MHz G3 running OSX 10.4.)
>
> Hmm, I am not 100% sure the binary will run on a G3. IIRC some people
> have reported working binaries on G3 CPUs, but that might have been a
> while.
>
I have most recently been running sage 2.3.2 on my G3 computer. Prior  
versions have also worked fine.

> Can you check if the md5sum of the dmg matches?
>
> mabsh...@sage:/scratch/mabshoff/sage-3.4$ md5sum ~/sage-3.4-OSX-10.4-
> PowerMacintosh-Darwin.dmg
> 3285260d94023d27a86faeb05bd0dcef  /home/mabshoff/sage-3.4-OSX-10.4-
> PowerMacintosh-Darwin.dmg
>
I need some more help here; I get:

Jim-and-Elaines-computer:~/Downloaded docs jim$ md5sum sage-3.4- 
OSX-10.4-PowerMacintosh-Darwin.dmg
-bash: md5sum: command not found

Again, thanks.
Jim

--~--~-~--~~~---~--~~
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
URLs: http://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-support] Re: Cannot copy on OSX

2009-03-15 Thread Jim Clark


On Mar 14, 2009, at 4:52 PM, mabshoff wrote:

>
> On Mar 13, 11:30 am, Carl Witty  wrote:
>> On Mar 13, 11:02 am, mabshoff >
>> dortmund.de> wrote:
>>> On Mar 13, 10:55 am, kcrisman  wrote:
 Any ideas?
>>
>>> The build box where that binary is being build had some changes  
>>> to the
>>> file system layout, i.e. William might have build on an NFS mount
>>> instead of a local file system. I did a build on a local file  
>>> system,
>>> so once I find some time I will get that binary uploaded to test  
>>> if it
>>> makes a difference.
>>
>> It looks like the build was done on a case-sensitive filesystem,
>> probably?
>
>
> Yep. I have a build from a HFS partition - see
>
>   http://sage.math.washington.edu/home/mabshoff/sage-3.4-OSX-10.4- 
> PowerMacintosh-Darwin.dmg
>
> can someone confirm that it works so I can upload it to the website?
>
> Cheers,
>
> Michael
>
I have downloaded both Michael's .dmg and the one from http:// 
sage.math.washington.edu/sage/osx/powerpc/index.html

In both cases, after I start sage, it fails as follows:
(My computer is a 300 MHz G3 running OSX 10.4.)

--
| Sage Version 3.4, Release Date: 2009-03-11 |
| Type notebook() for the GUI, and license() for information.|
--
The SAGE install tree may have moved.
Regenerating Python.pyo and .pyc files that hardcode the install PATH  
(please wait at
most a few minutes)...
Do not interrupt this.
 
---
ImportError   Traceback (most recent call  
last)

/Applications/sage/local/bin/ in ()

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
preparser_ipython.py in ()
   6  
 
###
   7
> 8 import sage.misc.interpreter
   9
  10 import preparser

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
interpreter.py in ()
 100
 101 import os
--> 102 import log
 103
 104 import remote_file

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/log.py  
in ()
  63
  64 import interpreter
---> 65 import latex
  66 import misc
  67

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
latex.py in ()
  41 import random
  42
---> 43 from misc import tmp_dir
  44 import sage_eval
  45 from sage.misc.misc import SAGE_DOC

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
misc.py in ()
  26
  27 import operator, os, stat, socket, sys, signal, time,  
weakref, resource, math
---> 28 import sage.misc.prandom as random
  29
  30 from banner import version, banner

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
prandom.py in ()
  54 # setting seeds should only be done through  
sage.misc.randstate .
  55
---> 56 from sage.misc.randstate import current_randstate
  57
  58 def _pyrand():

ImportError: dlopen(/Applications/sage/local/lib/python2.5/site- 
packages/sage/misc/randstate.so, 2): Library not loaded: /tmp/fooo/ 
sage-3.4/local/lib/libgmp.3.dylib
   Referenced from: /Applications/sage/local/lib//libcsage.dylib
   Reason: no suitable image found.  Did find:
 /Applications/sage/local/lib//libgmp.3.dylib: incompatible  
cpu-subtype
WARNING: Failure executing code: 'import  
sage.misc.preparser_ipython;   
sage.misc.preparser_ipython.magma_colon_equals=True'
 
---
ImportError   Traceback (most recent call  
last)

/Applications/sage/local/lib/python2.5/site-packages/IPython/ 
ipmaker.py in force_import(modname)
  64 reload(sys.modules[modname])
  65 else:
---> 66 __import__(modname)
  67
  68

/Applications/sage/local/bin/ipy_profile_sage.py in ()
   1 import os
   2 if 'SAGE_CLEAN' not in os.environ:
> 3 import sage.misc.misc
   4 from sage.misc.interpreter import preparser, _ip
   5 preparser(True)

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
misc.py in ()
  26
  27 import operator, os, stat, socket, sys, signal, time,  
weakref, resource, math
---> 28 import sage.misc.prandom as random
  29
  30 from banner import version, banner

/Applications/sage/local/lib/python2.5/site-packages/sage/misc/ 
prandom.py in ()
  54 # setting seeds should only be done through  
sage.misc.randstate .
  55
---> 56 from sage.misc.randstate import current_randstate
  57
  58 def _pyrand():

ImportError: dlopen(/Applications/sage/local/lib/python2.5/site- 
packages/sage/misc/randstate.so, 2): corrupt binary, library ordinal  
too big
Error importing ipy_profile_sage - perhaps you should run %upgrade?
WARNING: Loading of ipy_profile_s

[sage-support] Re: Sage 3.2 released

2008-12-01 Thread Jim Clark

On Nov 30, 2008, at 3:34 PM, mabshoff wrote:

> On Nov 30, 1:58 pm, Jim Clark <[EMAIL PROTECTED]> wrote:
>
>> I am puzzled by one of the binaries:http://sage.math.washington.edu/
>> sage/osx/powerpc/sage-3.2-G5-PowerMacintosh-Darwin.dmg
>>
>> Does the "G5" in the name mean it's specific for the G5 processor?
>> Usually the binaries are named according to the OSX version -- is
>> this one for OSX 10.4 or 10.5?
>
> That is an OSX 10.4 binary build on a G4. I am not 100% sure if it
> will be running on a G4. That G5 is the only 10.4 box we have access
> to 24/7 and it is also substantially faster (and has multiple CPUs)
> than any G4. So if you are attempting to run it on a G4 I would be
> very interested to see what happens if you run "make check"

Downloaded and ran "make check" on my G3 computer -- works fine!
(slowly, however, but I'm used to that :-)

Thanks for your help, Michael.
Jim

--~--~-~--~~~---~--~~
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-announce] Sage 3.2 released

2008-11-30 Thread Jim Clark

I am puzzled by one of the binaries: http://sage.math.washington.edu/ 
sage/osx/powerpc/sage-3.2-G5-PowerMacintosh-Darwin.dmg

Does the "G5" in the name mean it's specific for the G5 processor?  
Usually the binaries are named according to the OSX version -- is  
this one for OSX 10.4 or 10.5?

Thanks,
Jim Clark

On Nov 29, 2008, at 10:15 PM, mabshoff wrote:

>
> [Binaries for all common platforms are available and haven been
> mirrored out. Please use a local mirror to download]
>
> Hello folks,
>
> Sage 3.2 was released on November 20th, 2008. It is available at
>
>http://www.sagemath.org/download.html
>
> * About Sage (http://www.sagemath.org)
>
> Sage is developed by volunteers and combines 71 open source packages.
> It is available for download from www.sagemath.org and its mirrors in
> source or binary form. If you have any questions and/or problems,
> please report them to the Google groups sage-devel or sage-support.
> You can also drop by in #sage-devel or #sage-support in freenode.
>

--~--~-~--~~~---~--~~
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: arcsinh(1) == ln(1+sqrt(2)) ?

2008-10-31 Thread Jim Clark

Thanks to all. Your responses have been helpful.

Jim
On Oct 31, 2008, at 1:51 PM, John Cremona wrote:

>
> arcsinh(x) = log(1+sqrt(1+x^2)), I seem to remember.  [Proof:  
> exercise]
>
> John Cremona
>
> 2008/10/31 William Stein <[EMAIL PROTECTED]>:
>>
>> On Fri, Oct 31, 2008 at 12:57 PM, Jim Clark
>> <[EMAIL PROTECTED]> wrote:
>>>
>>> Hello sage gurus,
>>>
>>> Using sage to check a manually calculated integral :
>>>
>>> sage: var('r,h')
>>> (r, h)
>>> sage: integrate(r/sqrt(r^2 - sqrt(2)*h*r + h^2), r, 0, sqrt(2)
>>> *h).factor()
>>> sqrt(2)*arcsinh(1)*h
>>>
>>> My manual result (using an old table of integrals) was sqrt(2)*ln 
>>> (sqrt
>>> (2)+1)*h
>>>
>>> So, wondering whether arcsinh(1) = ln(sqrt(2)+1), I asked:
>>>
>>> sage: bool(arcsinh(1) == ln(1+sqrt(2)))
>>> False
>>>
>>> but then,
>>>
>>> sage: arcsinh(1).n()
>>> 0.881373587019543
>>> sage: ln(1+sqrt(2)).n()
>>> 0.881373587019543
>>>
>>> They look equal to my eyes...
>>>
>>> Also,
>>> sage: bool(arcsinh(1).n() == ln(1+sqrt(2)).n())
>>> False
>>>
>>> What am I missing here?
>>>
>>> Thanks,
>>> Jim Clark
>>
>> If expr is a symbolic expression in Sage, then
>>
>>bool(expr)
>>
>> evaluates to True only if expr can be proved to be True.
>> Otherwise it always evaluates to False.
>>
>> The actual code that decides this is currently in Maxima.
>>
>>  -- 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] arcsinh(1) == ln(1+sqrt(2)) ?

2008-10-31 Thread Jim Clark

Hello sage gurus,

Using sage to check a manually calculated integral :

sage: var('r,h')
(r, h)
sage: integrate(r/sqrt(r^2 - sqrt(2)*h*r + h^2), r, 0, sqrt(2) 
*h).factor()
sqrt(2)*arcsinh(1)*h

My manual result (using an old table of integrals) was sqrt(2)*ln(sqrt 
(2)+1)*h

So, wondering whether arcsinh(1) = ln(sqrt(2)+1), I asked:

sage: bool(arcsinh(1) == ln(1+sqrt(2)))
False

but then,

sage: arcsinh(1).n()
0.881373587019543
sage: ln(1+sqrt(2)).n()
0.881373587019543

They look equal to my eyes...

Also,
sage: bool(arcsinh(1).n() == ln(1+sqrt(2)).n())
False

What am I missing here?

Thanks,
Jim Clark


--~--~-~--~~~---~--~~
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: Odd behavior of gradient()

2008-10-23 Thread Jim Clark

On Oct 22, 2008, at 7:17 PM, Jason Grout wrote:

> You have to do "sage -b" first.
>
> The -b makes Sage rebuild itself to incorporate changes.  The first  
> time
> you run it, it will take a while (maybe 20 minutes?).  After that,
> depending on the changes you make, it will take seconds.
>
> If you're not sure how to apply the patch, probably the easiest way to
> apply the patch is to do the following at the sage command line:
>
> hg_sage.apply('http://trac.sagemath.org/sage_trac/attachment/ticket/ 
> 4343/gradient.patch?format=raw')
>
> Then quit out of Sage, run sage -b, then start sage back up again.

Thank you for the detailed instructions, Jason. The patch works!

The details:
Applied the patch in sage 3.1.2 (from downloaded OSX 10.4/PPC binary).
"sage -b" required 13.5 HOURS on my iMac with a 400 MHz G3 processor...
(William said he wanted to know :-)

The tests I previously reported in this thread now perform as I expect.

My application (calculating a vector electric field from a scalar  
potential field) also provides correct results.

I see that the trac ticket is in state "needs review", but I don't  
have a login id needed to report this review directly.
In my opinion the ticket could now be advanced to an "approved" state.

Regards,
Jim

--~--~-~--~~~---~--~~
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: Odd behavior of gradient()

2008-10-22 Thread Jim Clark


On Oct 22, 2008, at 5:28 PM, Jason Grout wrote:

> I've posted a patch to http://trac.sagemath.org/sage_trac/ticket/4343
>
> Can you apply the patch and test it out?
>
>
> Here is the new behavior:
>
>  sage: f(x,y) = x^n+y^n
>  sage: f.gradient()
>  ((x, y) |--> n*x^(n - 1), (x, y) |--> n*y^(n - 1))
>  sage: f.gradient([y,x])
>  ((x, y) |--> n*y^(n - 1), (x, y) |--> n*x^(n - 1))
>
Thanks for the quick response, Jason. As for applying the patch...

I run sage from a binary distribution that I downloaded.
I know I can manually edit the calculus.py file in the executable  
path on my system.
Will a changed file be picked up automatically when I run sage?

Again, thanks.
Jim

--~--~-~--~~~---~--~~
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] Odd behavior of gradient()

2008-10-22 Thread Jim Clark

The reference manual shows the following example for the gradient()  
function:

sage: x,y = var('x y')
sage: f = x^2+y^2
sage: f.gradient()
(2*x, 2*y)

However, if instead I enter:

sage: x,y,n = var('x y n')
sage: f = x^n+y^n
sage: f.gradient()
(y^n*log(y) + x^n*log(x), n*x^(n - 1), n*y^(n - 1))

(not what I wanted, but I can understand what happened.)
So I tried:

sage: f(x,y) = x^n+y^n
sage: f.gradient()
((x, y) |--> y^n*log(y) + x^n*log(x), (x, y) |--> n*x^(n - 1), (x, y)  
|--> n*y^(n - 1))

So even if I specify that f is a function of x and y,
gradient() still insists on also differentiating w.r.t. n

How do I tell gradient() that n is a constant?

Thanks in advance for insights.
Jim Clark



--~--~-~--~~~---~--~~
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: bug in notebook display typesetting fractional exponents

2008-09-30 Thread Jim Clark

Thank you Jason! I have looked through the documentation for vector  
analysis examples, without success. I was not aware of the gradient()  
function.

HOWEVER, the bug that I came upon in my initial effort is real. I  
could probably fix it myself if I were familiar with the sage code,  
but my hopes in posting the report is that someone who already has  
that familiarity could quickly put their finger on the problem.

Cheers,
Jim Clark

On Sep 30, 2008, at 4:35 PM, Jason Merrill wrote:

>
> On Sep 30, 6:26 pm, Jim Clark <[EMAIL PROTECTED]> wrote:
>> Hi there,
>>
>> I found a teeny bug in sage's rendering of fractional exponents (3/2
>> in this case) in notebook's output:
>>
>>  sagebug.tiff
>> 54KViewDownload
>
> Hi Jim,
>
> Try replacing %delW with %latex(delW).  Or just do
>
> sage: show(W.gradient())
>
> Best,
>
> JM
>

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

2008-04-23 Thread Jim Clark

I'll think about doing it, but it will take me a couple of days to  
dedicate the time to the task.
Jim
On Apr 23, 2008, at 9:47 AM, William Stein wrote:

>
> On Wed, Apr 23, 2008 at 9:08 AM, Jim Clark  
> <[EMAIL PROTECTED]> wrote:
>>  Will you be providing a binary for OS X 10.4 PowerPC?
>
> Unfortunately I no longer have access to *any* OS X 10.5 powerpc  
> machines.
> I personally don't own any ppc machines, but I have access to three.
> The owners of all three of those machines recently upgraded them to  
> 10.5.
> So the only way for Sage to provide 10.4 binaries is to either:
>(1) for me to buy a ppc os x machine and put 10.4 on it.  Yuck.
>(2) for a user to volunteer to be the provider of os x 10.4  
> binaries.
>
> So who wants to volunteer to do (2)?
>
> All you have to do is install Sage from source;
>
>tar xvf sage-3.0
>cd sage-3.0
>make
>
> and this just requires that you have XCode installed (nothing else
> is required!).  Note that XCode comes with your Mac on the DVD;
> or you can download it from the apple website.  Once you build
> Sage, you should make sure it works:
>
>make check
>
> then make a binary:
>
>./sage -bdist 3.0-osx10.4-ppc
>
> and you'll get a file
>
>SAGE_ROOT/dist/sage-3.0-osx10.4-ppc.dmg
>
> that you then make available to me somehow, so it can
> be put on the sagemath.org website.
>
> The above will take < 4GB disk space.
>
>  -- William
>
>>
>>
>>
>>
>> Index of /SAGEbin/apple_osx/powerpc
>>  NameLast  
>> modified  Size
>> Description
>>
>>
>>  Parent  
>> Directory -
>>  README.txt      21-Jan-2008  
>> 20:31   53
>>  sage-2.11-osx10.4-ppc-PowerMacintosh-Darwin.dmg 30-Mar-2008  
>> 19:36  265M
>>  sage-3.0-osx10.5-ppc-PowerMacintosh-Darwin.dmg  22-Apr-2008  
>> 06:23  225M
>>
>> Thank you,
>> Jim Clark
>>
>>
>> On Apr 23, 2008, at 4:58 AM, mabshoff wrote:
>>
>> Hello folks,
>>
>>
>> Sage 3.0 has been released on April 21st, 2008. It is available at
>>
>>
>>http://sagemath.org/download.html
>>
>>
>> * About Sage (http://www.sagemath.org)
>>
>
>
>
> -- 
> 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 3.0 released

2008-04-23 Thread Jim Clark

Will you be providing a binary for OS X 10.4 PowerPC?Index of /SAGEbin/apple_osx/powerpc  Name                                            Last modified      Size  Description  Parent Directory                                                     -     README.txt                                      21-Jan-2008 20:31   53     sage-2.11-osx10.4-ppc-PowerMacintosh-Darwin.dmg 30-Mar-2008 19:36  265M    sage-3.0-osx10.5-ppc-PowerMacintosh-Darwin.dmg  22-Apr-2008 06:23  225M  Thank you,Jim ClarkOn Apr 23, 2008, at 4:58 AM, mabshoff wrote:Hello folks,  Sage 3.0 has been released on April 21st, 2008. It is available at             http://sagemath.org/download.html  * About Sage (http://www.sagemath.org) 

[sage-support] Re: Sage 2.11 for OS X 10.5 not working properly

2008-04-02 Thread Jim Clark

Hi all,

I just want to report my experience of late:

SAGE 2.11
OS X 10.4.11 (PowerPC)
Safari 3.1
None of
tab key (completion)
Delete key (backspace) to delete a cell
up- and down-arrow keys to move from cell to cell
function.

I reported these to Apple via the "report a bug" function in Safari.

Jim Clark
On Apr 2, 2008, at 12:42 AM, Samuel Gaehwiler wrote:
>
> Same issue with Sage 2.10.3.
> ---
>
> I would appreciate any kind of help.
> Anyone else working on Mac OS X 10.5.2 Intel with or without this
> problem?
>

--~--~-~--~~~---~--~~
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: Tutorial difficulties

2008-03-28 Thread Jim Clark

Thanks for the help, David.

The solution is quite simple: y = k1 e^(ix) + k2 e^(-x)

Needless to say, it is quite the algebraic challenge to verify that  
sage's result (maxima's result?) is the same as this simple expression.
Jim
On Mar 28, 2008, at 9:17 AM, David Joyner wrote:
> I haven't checked if this is correct or not, but hope it helps:
>
>
> sage: t = var('t')
> sage: x = function('x', t)
> sage: de = lambda y: diff(y,t,t) + (1-I)*diff(y,t) - I*y
> sage: desolve(de(x(t)),[x,t])
> '%e^((%i-1)*t/2)*(%k1*sin(sqrt(-4*%i-(1-%i)^2)*t/2)+%k2*cos(sqrt(-4* 
> %i-(1-%i)^2)*t/2))'
>
>
> On Fri, Mar 28, 2008 at 12:04 PM, Jim Clark
> <[EMAIL PROTECTED]> wrote:
>>
>>  Thanks for the help provided so far, but I have encountered a new
>>  problem that I've been unable to solve: a second-order DE with
>>  constant but *complex* coefficients:
>>
>>  y'' + (1 - i)y' - iy = 0
>>
>>  sage: maxima.de_solve('derivative(y,x,2) + (1 - i) * derivative(y,x)
>>  - i * y = 0', ['x','y'])
>>
>>  yields:
>>
>>  Exception (click to the left for traceback):
>>  ...
>>  Is  i+1  zero or nonzero?
>>
>>  Looking at the maxima documentation, there appears to be a way to
>>  tell maxima maxima.assume('i+1 <> 0'), but this syntax seems to send
>>  sage into the ozone.
>>
>>  Thanks in advance for help offered.
>>  Jim Clark


--~--~-~--~~~---~--~~
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: Tutorial difficulties

2008-03-28 Thread Jim Clark

Thanks for the help provided so far, but I have encountered a new  
problem that I've been unable to solve: a second-order DE with  
constant but *complex* coefficients:

y'' + (1 - i)y' - iy = 0

sage: maxima.de_solve('derivative(y,x,2) + (1 - i) * derivative(y,x)  
- i * y = 0', ['x','y'])

yields:

Exception (click to the left for traceback):
...
Is  i+1  zero or nonzero?

Looking at the maxima documentation, there appears to be a way to  
tell maxima maxima.assume('i+1 <> 0'), but this syntax seems to send  
sage into the ozone.

Thanks in advance for help offered.
Jim Clark

On Mar 21, 2008, at 5:29 PM, David Joyner wrote:
>
> If your main interest is in solving DEs using SAGE, then you might be
> interested in the material on
> http://sage.math.washington.edu/home/wdj/teaching/index.html
> You may also be interested in joining sage-edu, which is
> unfortunately not on http://www.sagemath.org/lists.html
> but can be found here: http://groups.google.com/group/sage-edu
>
>
> On Fri, Mar 21, 2008 at 5:15 PM, Jim Clark  
> <[EMAIL PROTECTED]> wrote:
>> Hello SAGE people:
>>
>>  I want to report a problem I encountered in my attempts to learn  
>> SAGE
>>  via the tutorial.
>>
>>  First of all, I installed SAGE on my home computer, an iMac with  
>> OS X
>>  10.4.
>>
>>  I have been running the documentation by way of the "help" link in
>>  the notebook.
>>
>>  When I came to differential equations, this is what I saw on my  
>> screen:
>>
>>
>>>
>>
>>
>>
>>  This was puzzling, to say the least. (It has taken quite a bit of
>>  effort to discover how to solve simple differential equations...)
>>
>>  Along the way I decided to check out the documentation from the
>>  sagemath.org home page. The tutorial is presented differently. The
>>  same example appears:
>>
>>
>>
>>
>>  It made a lot more sense when I could see the equations!
>>
>>  Has this problem with the "live" tutorial been recorded? Is someone
>>  working on it?
>>
>>  I also have an opinion: This example is much too complicated for the
>>  tutorial. I think the tutorial should first present a single, simple
>>  DE before diving into systems of DEs.
>>
>>  Furthermore, I have an additional gripe, coming into SAGE with no
>>  knowledge whatsoever of the systems that SAGE is built upon. It
>>  appears that solving differential equations depends on something
>>  called maxima, about which I initially knew nothing (a Google search
>>  has now taught me a bit about what it is, but it appears that if I
>>  want to solve differential equations, then I must learn maxima in
>>  addition to SAGE.)
>>
>>  At any rate, I would have found it helpful in the tutorial if there
>>  were a bit of explanation of this relationship of SAGE to the  
>> various
>>  subsystems, perhaps with tables showing which subsystems do what,
>>  when one needs to be explicit about invoking the subsystem and how
>>  one goes about such invocation from SAGE.
>>
>>  At any rate, thanks for all you are doing. I hope that, by sharing
>>  the difficulties I have encountered coming into SAGE completely  
>> cold,
>>  you will be able to improve your product.
>>
>>  Jim Clark
>>
>>
>>
>
> >


--~--~-~--~~~---~--~~
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] Plotting gamma function

2008-03-07 Thread Jim Clark

Hi all,

I'm a SAGE newbie, (but I have experience with python). In the sage  
reference manual is the example:

P = plot(cos, -5, 5, thickness=5, rgbcolor=(0.5,1,0.5))
P   # show it

which works just fine, but if I replace "cos" with "gamma":

P = plot(gamma, -5, 5, thickness=5, rgbcolor=(0.5,1,0.5))
P   # show it

I get:

Exception (click to the left for traceback):P   # show it
...
TypeError: 'float' object is unsubscriptable


Why can't I plot the gamma function???

Thanks for any light you shine on this,
Jim Clark

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