SymPy makes math fun again
wordsandbuttons.online
wordsandbuttons.online
As a simple example, consider the transfer function of a RLC circuit from basic electronics. It might contain a expression of the form: s^2 + (R/L) * s + 1/(LC). What's often helpful is to express this in terms of the unitless form 1 + s/(Q * w0) + (s/w0)^2, where w0 is the resonance frequency and Q is the quality factor. In a complicated example with more components, the value of w0 might be related to the simple form of 1/sqrt(LC) by some unitless factor, or there's some other helpful way to write things that neatly relate it to the basic case, but SymPy/Mathematica will drag its feet showing you that. I wish there was more done on improving the insight and meaningfulness of results from CAS to the experimenter.
That said, they can be very useful dealing with large multi-term expressions, or double-checking your work by hand, playing around with transforms, etc.
It's a tool though, and more about the insights you bring to it, than it brings to you if that makes sense.
I would love to see a CAS that knows identities of https://en.wikipedia.org/wiki/Geometric_algebra
A good starting point is John Koza's first book on Genetic Programming.
So to me, this article just confronts me with the soul-destroying parts of modern maths, while claiming that those are apparently the fun bits. I have no idea how to reconcile those two things so I can pass that learning on to someone who might be getting interested in maths...
YMMV, of course.
The most popular frontend is wxMaxima which provides a nice user interface on top of Maxima: https://wxmaxima-developers.github.io/wxmaxima/
I have been working on a different frontend, that leverages CLIM, which happens to be a perfect toolkit for something like Maxima. I made a screencast showing the current state of development:
https://peertube.mastodon.host/videos/watch/df751bd5-5a26-44...
I have a preview release available as an Appimage, but please note that it is not a completed product yet: https://github.com/lokedhs/docker-maxima-client/releases
Moreover, Sage integrates lots of other libraries seamlessly. I remember doing lots of polynomial calculations and groebner basis stuff, and generating Singular script from Python seemed to be very elegant in the beginning. However, this quickly showed severe drawbacks. With Sage this all became easy and seamless again.
As an aside, the statistical libraries and conveniences of R ("missing value" is a data type; every object is an array meaning you can call functions on arbitrary arrays) are the only reason that I still use R for some niche applications. I wonder whether pandas or something like Sage will actually take over this functionality. My impression is that the packages in R are so isolated (in a somewhat good sense) for a niche application that they are both difficult to emulate in Python and happen to keep on working long after they were written (and not necessarily maintained).
I plan my code on paper quite a lot, and actually quite enjoy talking about what I'm doing (Whiteboard or not) [I think some whiteboarding at interviews is a good thing]
You don't even have to install anything!
So to get good grades, it's not good enough to understand math, you also have to be able to focus enough to avoid mistakes. Between ADHD and the prefrontal cortex developing/maturing well past the age of 20, that's quite an ask.
And it took me a long time to realize for myself that with math, the proof of a theorem is actually isomorphic to understanding it.
Are you the author? That's a great sentiment and you express it well. In fact, the whole article is engaging. Good job!
That said, for my specific use case (modulo arithmetic / cyclic groups) I didn't get SymPy to work properly. While I was able to find guidelines on how to hack it together, I have not found a real solution. After 2 hrs of search, I retreated in shame to Mathematica. If anyone knows a solution or works with these structures, let me know!
If you're at university and have a site license, that is :(
And you can get a cluster of these for a price of one PC. Awesome!
You can find the original one here: https://github.com/verdverm/go-pge/blob/master/pge_gecco2013...
In this case, the author has picked seven points on the sine curve (or its integral or its derivative), and used those seven pieces of information to find a unique polynomial.
If I were to guess, I'd say that if the seven points were on the curve itself (not on its integral or derivative), and they were all very close to some point P, then the resulting polynomial would look a lot like the taylor series expansion around P.
But that's just a guess :)
In fact, with sine modelling, Taylor series beats this approach with lower error. But with this you get to choose your properties so you might get more useful model instead.
Say, if you want to conjoin two sine models got from Taylor series to have it on a full [0, 2pi], you will have derivative discontinuity - a bump - on the joint. But with this model you wouldn't since it's explicitly required to be the inverse number at 0 and at pi/2.
The idea here is: every differentiation or integration over a polynomial results in another polynomial, right? And a polynomial in a point is just a linear equation of its coefficients. You can shove them into a system and make SymPy solve it.
So you can use differential and integral properties of some random function in some points, turn it into a linear system - and have a model of a function as a polynomial. That's it!