[ANN] Symbolics.jl: A Modern Computer Algebra System for a Modern Language

Welcome to Julia, and thanks for dropping by to help!

I’d say that if you feel comfortable with the syntax of the language, you could just immerse yourself in the related packages:

  • Symbolics.jl has all the saucy CAS stuff
  • SymbolicUtils.jl for expression rewriting and simplification
  • ModellingToolkit.jl is the package where it all came from. Used as modelling framework to solve all kind of equations that describe physical systems by means of ODEs, PDEs, and such.

If you find yourself more comfortable directly talking with the people involved in the project, you could drop by the Zulip conversation and engage with them there: Zulip Symbolic Programming Chat

Thanks for your advice!

9 Likes

Since this discusion already deal with some many topics around computer algebra systems, I hope this question have its place hear.

Among other things, I’m interested in symbolic computing for general relativity usage. Case and point, I want to write down symbolic expression for metric tensor and get out Christoffel symbols (this is only tip of the iceberg, but already quit a computation).

Ideal test case for me is Schwarzschild metric, for which most of the Christoffel symbols should be equal to 0. Is using Symbolics.jl for this problem now or in the future is reasonable thing?

10 Likes

I am currently preparing a notebook for PlutoCon, using Symbolics.jl to explain Gaussian curvature. I think it is possible to do what you suggest, but my experience is that “simplifying expressions” (a difficult problem in CAS) to display is not really there, but if using Symbolics.jl to output programs that compute Christoffel symbols is definitely possible already.

3 Likes

Thank you, I now have another motivation to learn Symbolics.jl. This be quite a ride. :smile:

Let’s take new feature discussions to issues and new threads. The release post is 125 responses already, and I want everything to get its own visibility.

7 Likes

Yes welcome! Let’s take the implementation discussions to the repo.

1 Like

Thank you for mentioning that work. Due to blessings of MIT and internet I download Wang’s thesis and I hope I will read it in following weeks.

2 Likes

How do the term rewriting capabilities of SymbolicUtils.jl compare with Wolfram Mathematica’s pattern matching / replacement?

2 Likes

Please do not feel restricted by the current implementation. It has gone through a number of revisions – including revisions of approaches essential to CAS aspects. We still are quite interested in best guidance from those who have worked hard to accrue it.

6 Likes

yeah the documentation is wrong here. Default is polynorm=false.

2 Likes

GMP is dual licensed LGPL3+ or GPL2+ so it’s not really an issue. The only GPL-only dependency of Julia itself is SuiteSparse, which is a significant annoyance quite often but at least a commercial license can be purchased if necessary. In particular, the SuiteSparse dependency means that we cannot ship a version of Julia that uses MKL as its BLAS library, which many people have wanted over the years.

14 Likes

all the libraries I kept in mind are available under LGPL 2+, that is, like GMP.

1 Like

I don’t know what you have in mind, but the practical difference between LGPL and GPL is so large that lumping them all under “GPL” strikes me as quite misleading: LGPL libraries have no impact on what other libraries you can use whereas GPL libraries prevent redistributing an application that is not fully open source. For some that is fine, for others it’s a show stopper.

7 Likes

Is there an effort to make a julia implementation of something like suitesparse? I know it is a very optimized library so it might not be worth it

5 Likes

I don’t know what you have in mind, but the practical difference between LGPL and GPL is so large that lumping them all under “GPL” strikes me as quite misleading: LGPL libraries have no impact on what other libraries you can use whereas GPL libraries prevent redistributing an application that is not fully open source. For some that is fine, for others, it’s a show stopper.

Sorry for being careless here (although LGPL is relatively recent -
when in 1994 I wrote my 1st code using GMP, version 1.3, it was still
GPL only, only few years after LGPL appeared :-))

3 Likes

Yes - SymbolicTensors.jl exists already (currently calls out to Sympy), and is due for a SymbolicUtils.jl backend soon.

3 Likes

I take it you are familiar with https://sagemanifolds.obspm.fr/?

4 Likes

Maple has similar (an in some cases more complete) functionality DifferentialGeometry - Maple Help

1 Like

Was the SymPy feature parity issue not updated or it didn’t make any progress since? https://github.com/JuliaSymbolics/Symbolics.jl/issues/59

3 Likes

That just hasn’t been updated. We need to do some issue triaging.

3 Likes