Julia for Scientific Programming

Hans W. Borchers -- September 2014

Overview

New programming languages (statically typed, compiled, using CLI, ...):

2002    Io                  Smalltalk, LISP; prototype-based
2003    Nemerle             CLI; C#-like, LISP
2003    Scala               JVM; Java, Smalltalk, ML; statically-typed
2004    Groovy              JVM; Java, Python, Ruby, Smalltalk
2004    Nimrod              Python, Pascal; statically-typed
2005    F# (Microsoft)      CLI; C#-like, OCaml, Haskell
2007    Clojure             JVM, CLR; CommonLISP, Haskell, Erlang
2009    Go (Google)         C, Oberon; statically typed
2010    Rust (Mozilla)      C++-like, Haskell, Erlang, CommonLISP; LLVM
2012    Julia               MATLAB (, R); multiple dispatch; LLVM
2014    Swift (Apple)       Objective-C; LLVM

(CLI/R = Common Language Infrastructure (.NET/Mono); JVM = Java Virtual Machine)

See also: B. A. Tate. Seven Languages in Seven Weeks. The Pragmatic Bookshelve, 2010.

Other ongoing/just started projects involving the Low-Level Virtual Machine (LLVM):

Python+numba, LuaJIT, Rubinius, RLLVM, Haskell, Matlab(?), ...

"Julia is a high-level, high-performance dynamic programming language for technical computing, with syntax that is familiar to users of other technical computing environments. It provides a sophisticated compiler, distributed parallel execution, numerical accuracy, and an extensive mathematical function library.
"The library, largely written in Julia itself, also integrates mature, best-of-breed C and Fortran libraries for linear algebra, random number generation, signal processing, and string processing.
"IJulia, a collaboration between the IPython and Julia communities, provides a powerful browser-based graphical notebook interface to Julia."

Julia home page: http://julialang.org/

"Julia is a new language targeted at scientific computing, which combines the high-level abstractions and dynamic interactivity of languages like Python with the performance of low-level languages like C, thanks to being designed from the beginning for efficient just-in-time compilation by LLVM. But a major challenge for any young programming language is the availability of a large ecosystem of mature libraries and tools. To overcome this difficulty, Julia is "bootstrapping" off of the Python ecosystem, both by making it easy to call Python code and also by exploiting infrastructure such as IPython/Jupyter (http://jupyter.org/).

"Although most Julia–Python interaction is from Julia users calling Python, there is potential for benefits to flow in both directions in the future. The same PyCall software that allows Julia code to call Python can also allow Python code to call Julia, with the same data-sharing and rich interactivity. And Julia code can also be compiled to C-compatible interfaces—currently, this is mainly used to pass Julia callback routines to C library functions (including libpython), but in the future the same facility should allow the generation of C-callable libraries written in Julia."

Steven Johnson at EuoSciPy 2014

See also the 4-hours "Introduction to Julia" tutorial by David Sanders at the SciPy 2014 Conference (https://github.com/dpsanders/scipy_2014_julia).

What is LLVM?

"The LLVM compiler infrastructure project (formerly Low Level Virtual Machine) is a compiler infrastructure designed as a set of reusable libraries with well-defined interfaces. It is written in C++ and is designed for compile-time, link-time, run-time, and "idle-time" optimization of programs written in arbitrary programming languages."

Wikipedia

"LLVM is the winner of the 2012 Association for Computing Machinery System Software Award [...] and is a highly extensible compiler toolkit. LLVM is a C++ library we can integrate into R (and other languages) to generate native code for various different CPUs, GPUs and other output targets. The ability to integrate this very adaptable and extensible tool into high-level languages is a “game changer” for developing compilation tools and strategies."

Duncan Temple Lang, 2014

Contents

Resources

Web links

Special Interest Groups

Installations

Roadmap Julia 0.4+

A 'gang' of 40+ scientific computing environments (free and commercial)

   APL/J  Axiom  Ch  Euler  FLINT  FreeMat  
  GAUSS  GDL  Genius  GMP/MPFR/MPIR  gretl  
 IDL/PV-WAVE  jLab/GroovyLab  Julia  LabView  
  Magma  Maple  Mathcad  Mathematica  Matlab  
 Maxima  MuPad  O-Matrix  Octave  Ox  Pari/GP  
  Pylab[Python]  R  Rlab  ROOT  S-PLUS  SAGE  
    SAS  SCaViS  SciLab  SciRuby  Singular  
 Speakeasy  SPSS  Stata  Torch7[Lua]  Yorick