r/Mathematica • u/vleessjuu • May 23 '19
r/Mathematica • u/johnmcdonnell • Mar 20 '11
Seriously though. Multiple undo. Most major applications have had it since about 1994.
r/Mathematica • u/CuttingWithScissors • Jun 30 '22
Launching Version 13.1 of Wolfram Language & Mathematica 🙀🤠🥳
r/Mathematica • u/NC01001110 • Apr 20 '20
Book Scraping with Mathematica
Introduction
Many of you may know that the scientific book publisher Springer has released a large collection of their books to help teachers and learners. In the announcement they even included a complete Excel spreadsheet containing a bunch of the books' metadata, including the links to the respective pages for each freely downloadable books. And it turns out, while the provided urls themselves don't link to the download pages/files, there's an easy rule to transform the DOI addresses into the file pages. So after identifying this pattern/rule, I wrote some Mathematica to scrap the list and download each book.
I've divided the program into two different types, scraping all the books or choosing only the subjects you want (e.g. Physics and Astronomy, and Mathematics). Though to start things, we first pick out the relevant data from the book data.
Book Data
Once this code is run, you'll be prompted with two sequential file explorer dialogs. The first is to identify the book data CSV, and the second is to specify which directory to place the folder that will contain all the books (e.g. [chosen directory]\Springer_Books). The code automatically creates subdirectories for the different subjects and puts the books in the right one.
books = Import[SystemDialogInput["FileOpen", WindowTitle -> "FIND THE BOOK DATA SHEET"]];;(*Opens a file explorer so you can more easily pick the book data CSV*)
subjectsColumn = Position[books[[1]], "English Package Name"][[1, 1]];
subjects = books[[2 ;;, subjectsColumn]];
urls = StringReplace[#, "http://doi.org" -> "https://link.springer.com/content/pdf"] & /@ books[[2 ;;, Position[books[[1]], "DOI URL"][[1, 1]]]]; (*Picks out and transforms the DOI urls of the book webpages into the urls of the downloadable files*)
titles = Block[{n = 1}, StringReplace[#, {":" -> ",", "/" -> " and "}] & /@ books[[2 ;;, 1]] /. str : "Advanced Organic Chemistry" :> str <> ", Part " <> ToUpperCase@Alphabet[][[n++]]]; (*Some titles have a ":" in them, and Windows doesn't like those, so they have to first be edited into a friendly file name (e.g. ":" -> "-").*)
authors = With[
{
authorColumn = Position[books[[1]], "Author"][[1, 1]],
getLastNamesList = (StringSplit[StringSplit[#, ", "]][[;; , -1]] &),
lastNamesListToString = (StringJoin @@ If[Length@# > 1, Riffle[#, "; "], #] &),
fixNames = (FromCharacterCode[ToCharacterCode@#, "UTF8"] &) (*You could also use ImportString[#,"Text"]&, but the implemented method is much faster.*)
},
fixNames@*lastNamesListToString@*getLastNamesList /@ books[[2 ;;, authorColumn]]
];
years = ToString /@ books[[2 ;;, 5]];
(*Creating the subject directories*)
bookDir = FileNameJoin@{SystemDialogInput["Directory", WindowTitle -> "WHERE TO SAVE ALL THE BOOKS"], "Springer_Books"}; (*Opens a file explorer to choose a directory in which to put the folder that will contain all the books*)
CreateDirectory@FileNameJoin@{bookDir, #} & /@ DeleteDuplicates@subjects;
uniqueName[title_String, year_String, author_String] := title <> " (" <> year <> ")" <> " - " <> author
fetchBook[{url_, subject_, name_}] := URLSave[url, FileNameJoin[{bookDir, subject, name <> ".pdf"}]]
fetchBookList[data : {urls_, subjects_, names_}] := Monitor[
Block[
{n = 0},
(n++; fetchBook@#) & /@ Transpose@data
],
ProgressIndicator[n/Length@data[[1]]]
]Downloading
All the books
With all our definitions above, scraping all the books from the list is relatively simple, or at least concise.
fetchBookList@{urls, subjects, MapThread[uniqueName, {titles, years, authors}] (*Unique file names for each book*)}Specific Subjects
Instead of downloading each subject as a black box, I've made it so you can see what books comprise each subject you may want to scrape. Basically, you click the subjects you're interested in and the program displays the books in that subject, and then you can simply click the "Download" button at the bottom of the prompt and Mathematica fetches the listed books. Example.
Manipulate[
If[
subject === 0,
"",
Column@{
TableForm[
{#[[1]], #[[2, ;; , 2]]} & /@ data[[Sort@subject]],
TableAlignments -> {Left, Top},
TableSpacing -> {5, 5, 1.5}
],
Button[
"Download",
Thread /@ data[[Sort@subject]] /. {subject_, {url_, name_}} :> {url, subject, name} // Catenate // Transpose // fetchBookList
]
}
],
{
{subject, 0, "Subject"},
Thread[Range@Length@# -> #] &@Sort@DeleteDuplicates@subjects,
TogglerBar,
Appearance -> "Horizontal" -> {3, 8}
},
Initialization :> (data = {#1[[1, 1]], #[[;; , 2 ;;]]} & /@ GatherBy[Transpose@{subjects, urls, MapThread[uniqueName, {titles, years, authors}]}, First] // SortBy[#, First] &),
Deinitialization :> Clear@data
]Conclusion
I elected to download all the books because I'm becoming an /r/DataHoarder . It took a little over an hour to download everything over WIFI (This wasn't parallelized because I had some concerns when it came to writing the data to my hard disk.) and the finished folder of everything is about 8GB.
r/Mathematica • u/neel_basu • Oct 28 '18
Mathematica++ A C++ Library that Talks Mathematica
neelex.comr/Mathematica • u/somecou • Sep 28 '22
Mathematica vs MATLAB Spoiler
I’ve played around with MATLAB and it seems simple enough to learn. I had some extra time this semester and wanted to study it more.
I ran into Mathematica while doing some study research on MATLAB. It also sounds like a really cool program to learn.
Does anyone have an opinion on which is better to learn?
I’ve seen MATLAB work really well with Python. Can Mathematica work as well?
r/Mathematica • u/[deleted] • Jul 13 '19
Mathematica (WL) is BEAUTIFUL
I am a PhD student in CS/EE doing theory and simulations so I have to deal with tons of math,
I used a little bit of Mathematica in high school and then in college but in isolated instances,
After that I learned functional programming mostly with OCaml which I loved but because of the
ecosystem and the practical issues my go to language has become Python with JupyterLab.
After OCaml I can't help but feel that Python is OKAY but a bit ugly when you are trying to do some
functional programming things.
Recently I had a problem which I decided to solve with Mathematica. Impressed once again with
the greatness of the language for solving these symbolic problems I started delving beyond the
very surface. I realized that Mathematica combines many many things I wished I could find in
mainstream languages. Easy syntax for Lambdas. Pattern Matching. Beautiful Syntax overall. Even
the knowledge system built in is incredibly useful for research. In other words Mathematica was
way more than what I thought it was all these years.
I think the design of this language is underappreciated.
I hope the language will continue to evolve and be state of the art
r/Mathematica • u/mathshare • Apr 14 '13
Free ebook: Power Programming with Mathematica by David B. Wagner
r/Mathematica • u/Inst2f • Aug 05 '26
How to write apps with Wolfram & WLJS, or swimming against the stream
Any ""serious"" language like C/C++, C#, Pascal/Delphi, and many others offers tons of options for building standalone apps. What about WL/Mathematica/MMA?
One could say, well, yes (and no)! There's the CDF format (which for some reason is officially considered deprecated 👀), webMathematica (costs like a helicopter and is also depreciated), JavaView (a very niche legacy project), and Wolfram Cloud. But I'm personally not a big fan of any kinds of clouds, especially with shady subscription models, and I'd rather keep everything local.
CDF was one of the best solutions so far, but it requires Mathematica (also costly) to build it, which isn't something everyone has, though thankfully, WolframScript/WolframEngine is still freeware.
Other people would argue that WL is meant purely for prototyping, and that you should just "vibe-code something with an LLM and JS" instead. I don't share that point of view, and I've found another way to turn notebooks into tiny or medium-sized apps for my research group. It works so far quite well for a limited number of users: 3-4 - mostly students. I would like to warn you, that it won't work magically for a random Mathematica notebook, otherwise WR would steal this immediately.
If you're interested, here's the full story I wrote:
https://wljs.io/blog/making-apps
PS: The thumbnail image isn't an AI-generated, it's a few UI windows built with this method, printed out and cut from paper 🙂
r/Mathematica • u/According_Inside_143 • Mar 18 '26
Wolfbook: a VSCode notebook extension that gives AI agents live access to a Mathematica kernel
I gave an AI agent a live Mathematica kernel — here's what that looks like
I've been building Wolfbook, a VSCode extension that connects directly to a local Mathematica kernel via a native WSTP C++ addon. The notebook side is useful on its own, but the part I keep coming back to is the agentic setup.

GitHub Copilot (or any LM tools-compatible agent) can now:
Evaluate arbitrary Wolfram expressions in the live kernel and get results back (including errors and prints outputs)
Inspect variable values mid-session
Step through a running loop debugger — the agent can query the watch panel while a subsession is paused at a breakpoint
Look up symbol definitions and documentation from the live kernel context
What this means in practice: I'm working on a research computation (I work in theoretical physics), I hit unexpected output, and instead of copy-pasting into a chat window I just ask Copilot — it reaches into the kernel, checks what the variables actually are, and reasons about what went wrong. The kernel state is the context!
This feels qualitatively different from "AI autocomplete for code". The agent has genuine read/write access to a live symbolic computation environment. For anything involving iterative mathematical exploration — which is most of what Mathematica is actually used for — that changes what's possible.
Still an open-source personal project, rough edges and all but already producing transformative shift in my day to day workflow.
GitHub: vanbaalon/wolfbook VSCode: Marketplace
Curious whether anyone else has been thinking about agentic access to computational kernels (Julia, Maple, etc.) — feels like an underexplored space.
r/Mathematica • u/Specific-Result3696 • Jun 08 '25
Anyone here with working experience at Wolfram?
Just wondering, I am finishing my Phd, and although I would like to continue in academia, sometimes I also wonder how would it be to work in Wolfram (as a programmer probably). I started to seriously use Mathematica in the Phd, and it seems to me so much better than the alternative (like python) and I have developed some really big package, so it seems like an interesting opportunity.
r/Mathematica • u/CuttingWithScissors • Apr 14 '21
The Wolfram Physics Project: A One-Year Update—Stephen Wolfram Writings
r/Mathematica • u/CuttingWithScissors • Mar 08 '18
Stephen Wolfram announces the release of Mathematica 11.3
r/Mathematica • u/Inst2f • Oct 15 '24
A legendary screensaver
using pure Graphics3D and Tube
https://jerryi.github.io/wljs-docs/ https://gist.github.com/JerryI/1a522c4f20d81ef05079eee4c7772891
r/Mathematica • u/irchans • Jun 23 '22
A Mathematica Joke - Rotate[{1, 0}, Pi/2] (Hidden by NSFW NSFW
r/Mathematica • u/YiM_Yes_its_me • Feb 19 '22
Best book to learn mathematica?
I am trying to use mathematica to solve symbolic equations, but I find it relatively painful and clunky to use. I feel I need a good learning resource, preferably a textbook, although a good video series would also be OK. I would say I am about intermediate level at programming, I have written many programs in MATLAB, Julia, and Python for my research and classes.
This is a bit of a noob question, but is there any way to make mathematica resemble an IDE like visual studio code or MATLAB? I would really prefer it if I could have a script file with numbered lines that I could then just run in terminal, but I can't find a way to set it up, and I find the documentation for how to use the software to be a bit sparse and hard to learn from.
r/Mathematica • u/CuttingWithScissors • Feb 15 '21
Mathematica Essentials - Official Trailer (2021)
r/Mathematica • u/PaleBlueSpot • May 26 '20
[Shitpost] Two countably infinite sets: boasts in the documentation and brackets in the code.
r/Mathematica • u/lustikus • Oct 12 '11
The name "Mathematica" was invented by... Steve Jobs
r/Mathematica • u/antononcube • 7d ago
Using Apple's Foundation Models in Wolfram Language Sessions
community.wolfram.comr/Mathematica • u/KebeLebe • Dec 29 '21
Im new to this. How come it didn't graph anything
r/Mathematica • u/lazergodzilla • Dec 02 '21
Is there any way to turn Mathematica full dark theme?
[SOLVED]
I'm basically reading everything white on black and Mathematica has proven itself quite a pain to turn on dark mode. To be clear: I'm not talking about the stylesheet. I'm talking about the menu bars. I've been looking online and I just can't find a way to do this.
It does not seem to be impelmented by default. So I was wondering if it's possible to change it in the source code. I mean the colors have to be stored somewhere. However this seems quite radical and I'm not even sure if Mathematica allows tampering with the source...
Did someone have the same problem and came up with a solution?
SOLUTION: For anyone else wondering the same and stumbling upon this post: The answer (at least for Linux systens) is well described here.
Basically Mathematica looks for a file ~/. Mathematica/FrontEnd/frontend.css you can edit (you might have to create it first) this file to configure the menu bars.
BETTER SOLUTION:
In the meantime I wrote a package that lets you easily theme Mathematica according to your needs. Basically you give it some colors and it will generate and apply a StyleSheet and fitting menu bars. It is easy to use and can be found under maTHEMEatica
