News for hackers. Stuff that matters.
Re:Mathematica v12.1 by armitron on Thursday March 19, 2020 @04:01AM (#22625481)
Mathematica is worth learning and using since it's so far ahead of the open source alternatives (e.g. Python/Jupyter and associated libraries ) in usability/interactivity/rapid development that it comes across like future-tech.

Unfortunately it's also the single tool most hampered by its licensing and silo-like ecosystem.

Re:Mathematica v12.1 by ryndbfsrw on Thursday March 19, 2020 @05:19AM (#22625824)
I've tried it for modeling tasks but I struggled with the sort of basic data manipulation that can be done within pandas/data.table. I can quite comfortably work with 100-million line CSVs using data.table on a standard laptop but Mathematica wasn't even able to ingest the file. I don’t disagree its technically very impressive but there's no point in having these amazing features if it stumbles with such basic tasks.
Re:Mathematica v12.1 by jiggawatts on Thursday March 19, 2020 @05:40AM (#22625921)
I've used Mathematica since about the year 2000, and I think Wolfram "missed the boat" of AI, big data, and machine learning.

They were in the unique position of having one of the best symbolic differentiation engines and one of the best numeric engines and a Lisp-like REPL that allows one to write terse, elegant code.

What they were always missing was efficient bulk data structures.

In recent versions they've added a handful of "special cases" where some types of data are stored as a plain data array like in C-derived languages, but this is hit-and-miss.

Similarly, they've dabbled with GPU acceleration and parallelism, but it's half-baked. It feels like a proof of concept, not something you'd ever actually use.

Julia and the like will slowly but surely eat their lunch.

Re:Mathematica v12.1 by currymj on Thursday March 19, 2020 @10:55AM (#22628041)
the neural network stuff is very good and relies on GPU acceleration. it is the "computation graph" paradigm -- have to define the whole architecture up front -- but it's actually quite pleasant to use.
Re:Mathematica v12.1 by leonvv on Thursday March 19, 2020 @04:38AM (#22625638)
Maxima is also an amazing tool for symbolic maths, and is free software. I especially recommend the wxMaxima interface which is close in spirit to jupyter notebook
Re:Mathematica v12.1 by lokedhs on Thursday March 19, 2020 @05:40AM (#22625920)
I'm taking this opportunity to post a video I made some time ago of my current work-in-progress, a new user interface to Maxima. It's more like a regular commandline compared to wxMaxima, which may or may not be what users want.

https://peertube.mastodon.host/videos/watch/df751bd5-5a26-44...

Re:Mathematica v12.1 by phillc73 on Thursday March 19, 2020 @04:08AM (#22625515)
I'm an R and sometimes Julia user, although not Python. Can you offer some examples of how Mathematica surpasses open source alternatives in those areas you've mentioned?
Re:Mathematica v12.1 by armitron on Thursday March 19, 2020 @04:12AM (#22625534)
It's hard to convey what I mean exactly by listing features, it's best if you use it yourself. Next best thing is to watch an expert use it.

Wolfram has released good videos to that end, here's the latest:

https://www.twitch.tv/videos/569938853

I find R to also be a lot better than Python and closer to Mathematica (especially if you combine it with RStudio and Shiny) but still not quite as good overall on the interactivity/environment end.

Re:Mathematica v12.1 by orbifold on Thursday March 19, 2020 @07:00AM (#22626317)
None of those can beat it in symbolic computation. You can write entire papers, by simply asking yourself the question: I wonder if this has an analytical integral? If you are lucky Mathematica spits out a solution in terms of a special function.
Re:Mathematica v12.1 by lonelappde on Thursday March 19, 2020 @08:47AM (#22626900)
Why hasn't Wolfram automatically published all those papers? Or sell a paper-generating plugin?
Re:Mathematica v12.1 by abdullahkhalids on Thursday March 19, 2020 @12:20PM (#22628948)
Because the most important part of the paper is formulating the question it is answering, and stating why asking that question is interesting and useful. That is not something anything short of AGI can do.
Re:Mathematica v12.1 by ur-whale on Thursday March 19, 2020 @04:32AM (#22625612)
How much symbolic computation can you do with R?
Re:Mathematica v12.1 by phillc73 on Thursday March 19, 2020 @05:00AM (#22625727)
There are several functions in base R for differentiation, integration, solving system of equations, etc. E.g. `solve`, `stats::D`, `stats::deriv`, `stats::integrate`, `stats::numericDeriv`.

R package Deriv for symbolic differentiation, it allows user to supply custom rules for differentiation.[1]

R package numDeriv[2] for calculating numerical approximations to derivatives.

R package gmp[3] and Rmpfr[4] provide multiple precision arithmetic and floating point operations. They also include some special functions, e.g. Rmpfr::integrateR for numerical integration.

R package mpc[5] available at R forge. It provides multiple precision arithmetic for complex numbers.

R package rSymPy[6] provides an interface to ‘SymPy’ library in python via rJava.

R package Ryacas[7] provides an interface to the ‘Yacas’ computer algebra system. It is easier to install compared to `rSymPy`.

R package symengine[8] is an R interface to the SymEngine C++ library for symbolic computation.

[1] https://cran.r-project.org/web/packages/Deriv/index.html

[2] https://cran.r-project.org/web/packages/numDeriv/index.html

[3] https://cran.r-project.org/web/packages/gmp/index.html

[4] https://cran.r-project.org/web/packages/Rmpfr/index.html

[5] http://mpc.r-forge.r-project.org/

[6] https://cran.r-project.org/web/packages/rSymPy/index.html

[7] https://cran.r-project.org/web/packages/Ryacas/index.html

[8] https://github.com/symengine/symengine.R

Re:Mathematica v12.1 by jrumbut on Thursday March 19, 2020 @05:27AM (#22625857)
I use R much more often than Mathematica and think is great for many reasons, but there are places where Mathematica is on another level. My mathematical maturity isn't high enough to really get how it's done or describe it well, but Mathematica has a way of being shockingly consistent across concepts and has pretty thorough documentation that can even help you learn the topics. R is very inconsistent even in the internal library, and documentation quality runs from best around to worse than no documentation.

There are also little nifty things like for image processing you can have a hard coded image show up in your code (I like plain text better but it's cool and future-techy). Distributions (as in normal, binomial, Poisson, etc) are a type and PDFs and CDFs can be obtained from them consistently rather than having to remember the different parameters of dnorm, dbinorm, etc.

I would love a real Mathematica expert to give us more. That's the real drawback of the closed ecosystem there is so much less information about it out there, fewer code samples, etc.

Re:Mathematica v12.1 by phillc73 on Thursday March 19, 2020 @06:45AM (#22626244)
Great information, thanks. I do totally agree about documentation for R libraries. It can be very hit and miss.
Re:Mathematica v12.1 by Aardwolf on Thursday March 19, 2020 @04:37AM (#22625634)
When I had the chance to try it, I didn't find it that easy to use due to the interface which felt clunky: the way the command line works: no feature to repeat previous comnand with up arrow, have to edit previous existing one, requiring more mouse usage, weird forms of cursor placement, weird default enter key behavior.

In ipython, matlab and octave it's much easier to repeat and modify last commands, which is something you seem to need all the time when experimenting with math.

What was I missing, usability/interactivity/rapid development wise?

Re:Mathematica v12.1 by kccqzy on Thursday March 19, 2020 @04:44AM (#22625663)
You are just not used to it.

> the way the command line works: no feature to repeat previous comnand with up arrow, have to edit previous existing one, requiring more mouse usage, weird forms of cursor placement, weird default enter key behavior.

It's not a command line. It's an interactive notebook. It's an entirely different experience. Repeating and modifying last commands can still be done with arrow keys, then Shift-Enter. Also, when you are doing math, you spend way more time thinking than typing and manipulating; the time needed to move your hands to the mouse is minuscule by comparison.

Re:Mathematica v12.1 by oefrha on Thursday March 19, 2020 @06:26AM (#22626152)
What command line are you talking about? If you want a command-line IPython-style REPL, enter MathKernel, which absolutely does support arrow keys to go backward and forward in history (and works over SSH without X). If you want a IPython (later Jupyter) notebook-style interface, enter Mathematica/Wolfram notebooks (guess where IPython notebook got its idea from). Sounds like you just didn’t bother to learn a bit about it before making up your mind.
Re:Mathematica v12.1 by improbable22 on Thursday March 19, 2020 @05:57AM (#22625988)
You're missing cmd+L (copy last command to cursor) and cmd+shift+L (last result).

Although, as others have said, many prefer the style of editing and re-running, rather than leaving the history above.

Re:Mathematica v12.1 by gmueckl on Thursday March 19, 2020 @04:49AM (#22625680)
Mathematica Notebooks have some REPL-like aspects, but they really should be uses like a script editor that shows the script output inline. You can jump between script segments and execute them out of order, which is useful in some cases. But notebooks are at their best when you have some discipline when editing, so that they stay in a state where you can open them, select execute notebook from the menu and everything works on the first try.