Plotting

30 views
Skip to first unread message

brombo

unread,
Nov 10, 2021, 6:47:52 PM11/10/21
to sympy
This is a subject that is more general than sympy but is relevant to sympy and I don't know where else to ask this question.  For plotting in sympy and python for that matter we pretty much make do with mathplotlib.  The software package Asymptote


is much better (it has a 3d vector syntax for plotting) and can generate report quality graphics (especially in 3d and even interactive 3d as show in the galleries in the link).  The problem is that it was originally written in 2004 before the staying power of python was know so that it has it's own programming language.  What it needs is a complete python wrapper for the graphics related types (it uses a strongly typed interpreted programming language with the flavor of C or C++) and plotting commands.  This is beyond my programming abilities.  Where in the python community should I propose this as a task that should be worked on?  Note that some people who know more about programming than I do looked at the source code and said that it uses a virtual machine which would make writing a python api simpler.

gu...@uwosh.edu

unread,
Nov 10, 2021, 7:06:00 PM11/10/21
to sympy
I think that having a way of getting publication quality output would be great. However, I think for what most people do the good interactive graphics of the plotly (2D, mostly, see https://plotly.com/python/) and K3d (3D, see https://github.com/K3D-tools/K3D-jupyter) are better.

If enough people are interested, maybe one of the foundations could pay for the work.

Alan Bromborsky

unread,
Nov 10, 2021, 10:21:00 PM11/10/21
to sy...@googlegroups.com

I looked at both packages and what I did not see was the ability to use LaTeX to annotate the figures which to me is a back breaker for report quality graphics.

--
You received this message because you are subscribed to a topic in the Google Groups "sympy" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sympy/GJrShcfsveg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sympy+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/a4dabb52-9ebd-4526-86bd-dd6d7dd9034en%40googlegroups.com.

gu...@uwosh.edu

unread,
Nov 11, 2021, 7:58:14 AM11/11/21
to sympy
Both plotly and k3d support rendered LaTex for labels, text, etc.
Some pages with very simple examples for

Again, I would not argue that these packages easily generate publication quality graphics, but they have very good interactive interfaces making them good for routine work.

Alan Bromborsky

unread,
Nov 11, 2021, 8:02:48 AM11/11/21
to sy...@googlegroups.com

FYI attached is a figure I generated with Asymptote for a Foucault pendulum.

You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/9a43a06f-3539-4cf1-9ee7-3e52670e0831n%40googlegroups.com.
Coords.eps

Andreas Schuldei

unread,
Nov 11, 2021, 8:12:13 AM11/11/21
to sy...@googlegroups.com
Asymptote is capable of creating high-quality drawings, on par with what you would find in Springer books. I feel it produces superior results.

Alan Bromborsky

unread,
Nov 11, 2021, 10:39:10 AM11/11/21
to sy...@googlegroups.com

The wiki page explains what is different about the internal working of Asymptote -

https://en.wikipedia.org/wiki/Asymptote_(vector_graphics_language)

Reply all
Reply to author
Forward
0 new messages