Updates:
        Cc: asmeurer
        Labels: NeedsReview

Comment #4 on issue 1719 by smichr: implement from sympy.abc import lower,  
greek
http://code.google.com/p/sympy/issues/detail?id=1719

Vinzent...for consideration, branch 1719 has a new abc folder with lower,  
upper and
greek scripts that allow one to do what you've said...and in contradiction  
to what I
said above, I've left a "safety" on the upper case in that none of the  
sympy-clashing
upper case symbols are imported. If someone really wants to do that they  
will have to
do it themselves i.e. N = Symbol('i_do_not_care_about_N'). Here's some  
interactive
session showing the behavior. ** There is a problem that I am having below,  
though. **

>>> from sympy import *
>>> alpha # not defined yet
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'alpha' is not defined

>>> from sympy.abc.greek import alpha
>>> beta # not defined yet
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'beta' is not defined
>>> alpha # but we did import this one successfully
alpha
>>> from sympy.abc.greek import *
>>> beta # now we have them all
beta

>>> A
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'A' is not defined
>>> a
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'a' is not defined
>>> from sympy.abc.lower import *
>>> a
a
>>> A
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
NameError: name 'A' is not defined
>>> from sympy.abc.upper import *
>>> A
A

*********************************
OK, here's the problem. I was updating the gotchas.txt file and ran into  
this problem:

>>> dir (sympy.abc)
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'abc'
>>> from sympy.abc import *


The dir command fails but I clearly can access abc as the next command  
shows...how do
I get the first one to succeed?

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--

You received this message because you are subscribed to the Google Groups 
"sympy-issues" group.
To post to this group, send email to sympy-iss...@googlegroups.com.
To unsubscribe from this group, send email to 
sympy-issues+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sympy-issues?hl=en.


Reply via email to