29

Can Mathematica be used for developing "normal" stand-alone software? I understand "normal" is not a very good qualifier. What I mean by it is software that people usually develop in Java and C++ so it can be "installed" on computers and be launched by double clicking etc. I hope this makes sense. If there is, could you list some non-trivial examples besides anything made by Wolfram in-house such as Wolfram Alpha?

J. M.'s missing motivation
  • 124,525
  • 11
  • 401
  • 574
user13253
  • 8,666
  • 2
  • 42
  • 65
  • Difficult to think about this question without seriously assessing the current intellectual property protections available & not available with Mma. They include: compiling, encoding, and CDFs (lot's of discussion of all of this on this site), but I have yet to see a sound approach from Wolfram to protect IP in a way comparable to other languages. No language can provide absolute IP protection. With sufficient time, money, knowledge, and tools one can probably reverse engineer any code. That said, even though I use Mma exclusively, Java, C++, and the like provide much more protection. – Jagra Mar 03 '15 at 16:59
  • may be the wolfram engine SDK might be needed for this. Here is reference http://www.wolfram.com/engine/ I've seen talk of making Wolfram engine be standalone that can be part of executable. – Nasser Mar 03 '15 at 19:04
  • @Nasser - That could make a difference and do much ti close the gap between Mma and other development approaches. Thanks for the info. – Jagra Mar 03 '15 at 19:13
  • Does your view of "normal" include "shrink-wrapped" or desktop software? – Jagra Mar 03 '15 at 23:56
  • Related: http://mathematica.stackexchange.com/q/37888/1871 – xzczd May 19 '15 at 10:19

1 Answers1

27

Yes Mathematica executables can be distributed as CDF documents either directly or the Wolfram Kernel can be accessed programmatically in multiple ways via the Cloud and the Internet. The Wolfram kernel that is installed by both CDF player and Mathematica can be thought of (crudely) as the Virtual Machine the executable needs to access to run - so its just like Java or .Net in this respect, more so when you consider there is also a browser plug in.

To take the analogy further - Mathematica is the IDE (integrated development environment) where you write & test your code and CDF player is the run-time.

For lots of non-trivial examples see:

http://demonstrations.wolfram.com/

My favourite is the Radial Engine.

http://demonstrations.wolfram.com/RadialEngine/

People who are serious about writing Mathematica programs mighttake things one step further and use Wolfram Workbench (which is just the Eclipse IDE modified for Wolfram Language code development), together with a Version Control System (VCS) like Git. Infact my company has just spent some time working with a Wolfram consultant to produce a CDF Application who used exactly this set up.

A seriously heavyweight example with probably man years of Wolfram Language code in it:

http://emeraldcloudlab.com/

A commercial Smart Meter analytics Application competing with solutions from major vendors such as SAP.

http://www.wolfram.com/broadcast/video.php?c=311&v=74

one three more for the road

As requested a video player in Mathematica - enjoy ;)

How to build a bvh (a motion capture file format) player in Mathematica?

3D turn based strategy.

http://demonstrations.wolfram.com/3DChess/

3D puzzler/fps/God sim Mathematica Minecraft

One more for the road

Mathematica integrated with Unity game engine.

Gordon Coale
  • 2,341
  • 15
  • 20
  • 3
    The demonstration applications shown there is more like really light-weight Java Applets. But I'm more interested in serious large software such as a video player, an editor, etc. Has Mathematica ever been used for writing such softwares? – user13253 Mar 03 '15 at 16:15
  • @qazwsx You need to really consider your definitions, all languages have their stronger and weaker use cases, picking those 3 is very arbitrary. I wouldn't write an mpeg decoder in Mathematica, just the same as I wouldn't write a Radial Engine simulator in C. A "big" application has very little to do with the language its constrained by the Time and Resources you would throw at it. – Gordon Coale Mar 03 '15 at 16:23
  • I agree. I realize that so at the very beginning I pointed out the definition of "normal" is poorly defined. But I think you know what I mean by "normal" or "normal-looking" softwares. – user13253 Mar 03 '15 at 16:38
  • @qazwsx I added a couple of commercial examples. IMO a fair definition of "normal" is software that's sold commercially. Personally I think the Emerald labs one is amazing. – Gordon Coale Mar 03 '15 at 16:50
  • @qazwsx "a video player, an editor," <- Mathematica is not a general purpose programming language. Trying to do this in Mathematica would be just as counterproductive as using plain C with no third-party libraries for producing figures for your scientific publication ... – Szabolcs Mar 03 '15 at 18:10
  • @Szabolcs, I know that. What I'm trying to get to is that I need some concrete examples or some kind of evidence that such example does not exist as regularity to answer the question of "Mathematica can normally only be used as a tool for scientists but not for software developers to make normal/normal-looking softwares." – user13253 Mar 03 '15 at 22:09
  • 1
    @qazwsx I've given you 2 commercial examples. I personally know of a 3rd where there is a large CDF in a FMGC organisation. If you want more I suggest you ask Wolfram customer services for reference sites. Once a MMA project reaches a certain complexity there is zero difference between a scientist and software developer, the effort requires formal development methods and disciplines as already noted. If you truly want an answer that satisfies you, you need to spend some more time refining your definition of "normal softwares" otherwise your question is unanswerable. – Gordon Coale Mar 03 '15 at 22:46
  • 1
    What is FMGC? Could you define initialism before using it? – user13253 Mar 04 '15 at 08:26
  • Thanks for the acceptance. Small typo FMCG - fast moving consumer goods. The bulk of stuff you find on supermarket shelves that isn't fresh or frozen. http://en.wikipedia.org/wiki/Fast-moving_consumer_goods – Gordon Coale Mar 04 '15 at 08:31
  • @GordonCoale Well, maybe I can come with some examples of "normal softwares"... A turn-based strategy game like Heroes? A performance heavy FPS like Far Cry? A spreadsheet like Excel or LibreOffice Calc? A bookkeeping application? An app store? A search engine? Some kind of parser? Or, more generally: any end-user application targeted at average people whose purpose is not closely tied with science or scientific research or some heavy analysis, etc – gaazkam Mar 04 '15 at 12:21
  • @gaazkam Im unsure of the benefits of taking this any further - and which average user did you mean - the modal, mean or median one :) Ask a general question you get a general answer which I have tried to answer with specifics. Perhaps you would like to do some prior research before asking your question, and give a context & purpose? At the moment we are reduced to generalities Q: Why is language X more suited than language Y for purpose Z? A: Because it was engineered that way - usually purposely. – Gordon Coale Mar 04 '15 at 16:59
  • @GordonCoale You now, I'm actually not the OP ;P He's qazwsx, not gaazkam :) Besides, I'm really curious if I can make a turn-based strategy game in Mma ;) I take a performance-heavy FPS is rather outta the question, isn't it? But OK - I get it - MMa for science, other languages for anything else. Have I got you point correctly? – gaazkam Mar 04 '15 at 22:03
  • 3
    Not quite. I think the links prove that you can push the boundaries for MMA very far indeed, but IMO for most cases unless you have large amounts of time or you are an MMA ninja - if you want to do general purpose coding use a general purpose language. – Gordon Coale Mar 04 '15 at 22:55
  • 1
    I've just watched to another interesting example in this video from the recent WTC2016 ... – SquareOne Feb 02 '17 at 22:18