On Wed, Aug 29, 2012 at 2:27 PM, Juha Jeronen <[email protected]> wrote:
> Hi all,
>
> This time a question: is there a preferred way of getting a complete
> list of symbols reserved by SymPy, i.e. atoms which have a default
> meaning (E, pi, EulerGamma, oo, etc.)?

These are the singletoms (below, ignore methods with `__`). But they
can all be overwritten. The only reserved symbols that don't become
symbols upon sympification are Q-COSINE (the C will actually parse
like a symbol so in that sense it's not reserved; the "-" could help
you remember that).

>>> dir(S)
['Catalan', 'ComplexInfinity', 'EmptySet', 'EulerGamma', 'Exp1',
'GoldenRatio', 'Half', 'IdentityFunction', 'ImaginaryUnit',
'Infinity', 'Integers', 'NaN', 'Naturals', 'NegativeInfinity',
'NegativeOne', 'NumberSymbol', 'One', 'Pi', 'Reals', 'UniversalSet',
'Zero', '__call__', '__class__', '__delattr__', '__doc__',
'__format__', '__getattribute__', '__hash__', '__init__',
'__module__', '__new__', '__reduce__', '__reduce_ex__', '__repr__',
'__setattr__', '__sizeof__', '__slots__', '__str__',
'__subclasshook__']


>
> And finally, a related question: is there a way to get a human-readable
> description for a reserved name (e.g. "zoo" -> "complex infinity")? I
> didn't find anything in the API for this.
>

Not sure how to go further than

>>> type(oo)
<class 'sympy.core.numbers.Infinity'>

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

Reply via email to