##// END OF EJS Templates
Merge pull request #1399 from asmeurer/sympyprinting...
Merge pull request #1399 from asmeurer/sympyprinting Use LaTeX to display, on output, various built-in types with the SymPy printing extension. SymPy's latex() function supports printing lists, tuples, and dicts using latex notation (it uses bmatrix, pmatrix, and Bmatrix, respectively). This provides a more unified experience with SymPy functions that return these types (such as solve()). Also display ints, longs, and floats using LaTeX, to get a more unified printing experience (so that, e.g., x/x will print the same as just 1). The string form can always be obtained by manually calling the actual print function, or 2d unicode printing using pprint(). SymPy's latex() function doesn't treat set() or frosenset() correctly presently (see http://code.google.com/p/sympy/issues /detail?id=3062), so for the present, we leave those alone.

File last commit:

r4669:45cf1867
r6482:ba882bf7 merge
Show More
__init__.py
11 lines | 319 B | text/x-python | PythonLexer
Thomas Spura
Unbundle of all external modules....
r3408 try:
import argparse
MinRK
use bundled argparse if system argparse is < 1.1
r4669 # don't use system argparse if older than 1.1:
if argparse.__version__ < '1.1':
raise ImportError
else:
from argparse import *
from argparse import SUPPRESS
except (ImportError, AttributeError):
Thomas Spura
Unbundle of all external modules....
r3408 from _argparse import *
Thomas Kluyver
Fix up argparse (update bundled version) so IPython starts whether or not argparse is installed system-wide.
r3456 from _argparse import SUPPRESS