6 ms·
Is there an example of a problem where Pure would be a good choice of language in solving that problem?
by hossbeast 9y ago
Is there an example of a problem where Pure would be a good choice of language in solving that problem?
- blacksqr 9y agoFrom the FAQ: Why Pure? Thanks to LLVM, Pure offers state-of-the-art JIT compiler technology in an interactive environment, and makes it easy to interface to C in a direct fashion. Recent releases also provide the ability to directly import LLVM bitcode modules into Pure scripts and to inline code written in various languages (currently C/C++, Fortran and Faust). Scripts can also be compiled to standalone native executables (they are also executed during compilation, which makes it possible to employ partial evaluation techniques). Pure has an efficient MATLAB-like, GSL-compatible matrix type which makes it easy to interface to languages and libraries for doing numeric computations and digital signal processing. In particular, Pure interfaces to (GNU) Fortran, Octave and Grame's Faust, and you can directly invoke GSL routines on Pure matrices. In a way, this is like having Haskell, Octave, DSP programming and the term rewriting capabilities of a computer algebra system under one hood. It goes without saying that Pure can be used used for mathematical applications, but there's also a growing collection of extension modules for GUI, graphics, multimedia, database and web programming which makes Pure useful as a kind of algebraic/functional scripting language for a variety of purposes.
- 59nadir 9y agoI don't think this really does a great job of selling Pure as a solution to a problem. It's sort of saying "Well, you can kind of use Pure for anything, even GUIs!". I'm sure there's something Pure was designed to solve which could be brought forward as something it solves beautifully. It's not really obvious what that is from this text, though.
- rmbeard 9y agoFor me the symbolic math capabilities are interesting. I'm not sure I like the choice of reduce that much, but still few languages offer symbolic capabilities. Python does with SymPy and Maxima is based on Lisp but that's moe a case of a CAS being based on a language than the language having symbolic capabilities and then there is Mathematica (expense being the barrier).
- rurban 9y agoOnline, dynamic music synthesis. pure comes from pd I think, puredata, which has as default an unoptimized graphical language. pure can deal with real-world musical problems much better.