Skip to Content.
Sympa Menu

texmacs-users - Re: [TeXmacs] Sympy plugin

Subject: mailing-list for TeXmacs Users

List archive

Re: [TeXmacs] Sympy plugin


Chronological Thread 
  • From: "David E. Miller" <address@hidden>
  • To: Bill Eaton <address@hidden>
  • Cc: address@hidden
  • Subject: Re: [TeXmacs] Sympy plugin
  • Date: Wed, 15 May 2013 15:00:04 -0400
  • Authentication-results: smtp02.embarq.synacor.com smtp.user=address@hidden; auth=pass (LOGIN)
  • X_cmae_category: 0,0 Undefined,Undefined

Bill:

Given your lists of "wants" below, since I am familiar with MathCAD I suggest the following:

* Maxima is arguably the best open-source CAS system I have used. The plugin works and
the TeXmacs Maxima plugin output looks nice.

* Maxima has a units module that you can load and use. I have not tried it personally. I
Use GNU Units instead for conversions and merely make sure that I use a consistent
set of units to begin with instead of mixing them together in expressions. This avoids
having to carry these unit abbreviations along with all the expressions involved. This
is really and pain in the you-know-what.

* Maxima can do numerical work as well, but that is not its primary strength. You might
try Octave instead. Python NumPy and SciPy modules work well also using the
Python plugin for this purpose. Maxima may have all you need though.

* I recommend loading the Maxima draw module for your plotting. Maxima has some
stock plotting functions, but in my opinion the draw module is superior to these.

Having said all this there are a couple of caveats here of which you should be aware:

- Maxima input is all text. There is no worksheet GUI environment like MathCAD uses.

- TeXmacs and the Maxima plugin does not replace a special purpose interface
to Maxima for routine work were there might be a lot of trial and error
involved. I think wxMaxima is best for work like this. You can use TeXmacs
for this if you choose, and to the credit of the developers there is much
that can be done, but TeXmacs is primarily for communicating results in
most instances. You will have to try both according to your needs and
see what works best for you.

- The TeXmacs existing Octave plugin has a bug it appears. I have a fix for this I
found by trial and error that seems to fix the issue so far for me.

- Including images in TeXmacs requires some know-how that is not obvious from the
interface. In the end TeXmacs likes PostScript, that is, Encapsulated PostScript image
format. All other formats are converted using "helper" programs on the fly as
image is inserted. So the best bet is to use a "terminal" ( I am using gnuplot lingo)
like epscairo to save any plot image to EPS. I have a paper I have written about the
issues of image insertion using TeXmacs that explains all this in detail. I will send it
to you if you have the interest. Images having any "transparency" effects are
a particular problem that needs to be addressed. These need to be "rasterized"
EPS files before insertion. These rasterized images can be large.

- I recommend that you stick with GNU/Linux instead of Windows or OS X versions
of TeXmacs or anything else for that matter. You will save yourself a barrel of
headaches. There are so many useful tools available and everything works
together it seems to me much better.

If you decide you want to use Maxima with TeXmacs, then I can help. I use it all
the time with TeXmacs and the Maxima plugin is top-notch in my opinion.
I have a paper I have written that provides users with the essential ins and outs of
using Maxima. It is an elaboration of a paper written by Robert Dodier
titled "Minimal Maxima." My version is called Minimal Maxima Revisited."
I will send this to you if you have the interest.

Best wishes,

David Miller

On 5/15/2013 12:37 PM, Bill Eaton wrote:
Thanks to everyone for feedback.

Honestly, I haven't done much with the Python plugin. But I could see how it
could be REALLY useful for writing tutorials with the varsession package.
The SymPy plugin seems to work mostly OK, but there are notable cases where
I don't get nicely typeset formulas. I don't know enough about what TexMacs
syntax should look like for formulas/equations.

Presumably, there is something about the sympy.printing.latex() function
that produces output that TexMacs doesn't like.

The behavior I see is in Linux. I haven't gotten the plugin to work in
Windows yet. I found the SymPy plugin from the SymPy source tree.

Just now, I was perusing through the Python plugin and I see there is a
function for spitting out PostScript code. Can that be used for inline
figures/plots? If so, that would be extremely useful.

My motivation for all of this is to find a good MathCAD replacement. I want
to have:
* typeset formulas
* symbolic manipulation for when I need to derive equations
* numerical evaluation for when I need to make calculations
* awareness of units
* ability to do plots
* make a pretty document that can serve as a report.

TexMacs is a good candidate for this, but it's been a struggle to figure out
how to get what I want.

--Bill




-----Original Message-----
From: address@hidden [mailto:address@hidden]
Sent: Wednesday, May 15, 2013 1:27 AM
To: David E. Miller
Cc: Bill Eaton; address@hidden
Subject: Re: [TeXmacs] Sympy plugin

On Wed, 15 May 2013, David E. Miller wrote:
I can't find a sympy plugin in either version in the distribution file
tree as installed.
It's a part of sympy.

Second, since this is a Python module, I would first try to use the
existing Python plugin and fire up a Python session in a TeXmacs doc and
load your sympy module and see how the Python plugin handles the some stress
tests you can try.
This is by far not sufficient. sympy is a CAS, and the main reason to use it
inside TeXmacs is to get nicely typeset formulas. The python plugin alone
will not do this.

What's needed is some hybrid of the current python plugin (distributed with
TeXmacs) and the current sympy plugin (distributed with sympy).

Andrey






Archive powered by MHonArc 2.6.19.

Top of Page