Live data from Hacker News

Show HN: SymDerive – A functional, stateless symbolic math library

news.ycombinator.com

11–16 of 16 posts

Re: Show HN: SymDerive – A functional, stateless symbolic math library

#11
post #8

This looks wonderful, I've dreamt of something like this back when I was in academia! You mention some advanced stuff like abstract index notation which is usually the hardest part to get right with things like simpy and even mathematica, how does your package handle simplifications of complex tensor expressions (GR, hydrodynamics, etc.)?

You can specify symmetry/antisymmetry patterns for tensor index slots and it takes advantage of that to speed up the calculations. This part was pretty important for me so i spent some time thinking about it. I wanted to try to put xACT’s patterns in but it would have been quite the undertaking.

Re: Show HN: SymDerive – A functional, stateless symbolic math library

#12
post #8

This looks wonderful, I've dreamt of something like this back when I was in academia! You mention some advanced stuff like abstract index notation which is usually the hardest part to get right with things like simpy and even mathematica, how does your package handle simplifications of complex tensor expressions (GR, hydrodynamics, etc.)?

You can specify symmetry/antisymmetry patterns for tensor index slots and it takes advantage of that to speed up the calculations. This part was pretty important for me so i spent some time thinking about it. I wanted to try to put xACT’s patterns in but it would have been quite the undertaking.

It could definitely be better though

Re: Show HN: SymDerive – A functional, stateless symbolic math library

#13
post #9

Please never use `from something import *`, not even for a demo. It is not explicit, not maintainable, and goes against all Python guidelines. Certainly never expect any user to use it either.

Yeah, you’re not wrong. Makes the syntax a bit annoying here (goal was to lower barrier of entry for physicists). I agree this is bad practice.

In the limiting sense, especially when a user mixes your snippet with snippets from other packages, the barrier of entry becomes greater due to the resolution ambiguity, not less.

Re: Show HN: SymDerive – A functional, stateless symbolic math library

#14
post #7

> The "Pipe" approach (Cleaner for agents How did you verify the benefit?

Not rigorous, but intuition derived from expression string complexity for postfix operations vs standard sympy style. I’ll take this out, readme was written from sleazy used car salesman advertising point of view. Was more rigorous in examples/test

removed claim from README

Re: Show HN: SymDerive – A functional, stateless symbolic math library

#15
post #9

Earlier quoted context omitted.

Yeah, you’re not wrong. Makes the syntax a bit annoying here (goal was to lower barrier of entry for physicists). I agree this is bad practice.

In the limiting sense, especially when a user mixes your snippet with snippets from other packages, the barrier of entry becomes greater due to the resolution ambiguity, not less.

fixed in the readme. thanks -

while we are talking imports ... how did `import pyspark.sql.functions as F` ever get past the pep police

Post reply on HN