Saturday, 28 February 2009

Book review: "The Objective Caml Programming Language" by Tim Rentsch

Abscissa Press recently published The Objective Caml Programming Language by Tim Rentsch and were kind enough to send us a complimentary copy of the book for review even though we are the creators of the related book OCaml for Scientists.

The Objective Caml Programming Language is a 264-page paperback that covers many features of the OCaml programming language including expressions, variables, functions, pattern matching, tuples, lists, polymorphism, unions, references, loops, records, arrays, strings, exceptions, IO, compilation, debugging, modules, functors, objects, inheritance, polymorphic classes and touches upon some other topics including labeled and optional arguments and laziness.

The core content is derived largely from Jason Hickey's academic course on OCaml at Caltech but also includes 87 pages describing OCaml's object system. The book has been carefully typeset and is a pleasure to read. The style of writing is purely theoretical and presents technical content with many examples, academic exercises and it is mostly accurate. Consequently, this book is ideal for anyone who already has a strong background in computer science and wants to learn the OCaml language.

However, this is not a pragmatic book and no attention is given to programming style, libraries, tools, optimization or other issues that are very important for anyone who wants to use OCaml for general purpose programming.

The Objective CAML programming language by Tim Rentsch is available from Barnes and Noble and Amazon for only £25.


Friday, 20 February 2009

Building a Virtual Machine using LLVM: part 2

The OCaml Journal just published an article about the LLVM:

"This is the second article in the series about our high-level virtual machine (HLVM) project. This article builds upon the foundations laid in the first article to create a much more practically useful language implementation by adding tail call elimination, first-class structs, a foreign function interface (FFI) and first-class function pointers..."

To read this article and more, subscribe to The OCaml Journal today!

Thursday, 19 February 2009

Toy Lisp implementation written in C++ using LLVM

We recently stumbled upon this toy Lisp implementation. The compiler is written in C++ and uses LLVM for high performance JIT compilation. Although the compiler makes no attempt to be efficient with statically-known types the implementation is still interesting from an OCaml perspective because it includes first-class functions.

Sunday, 8 February 2009

Simulating smoke in real-time using fluid dynamics

The OCaml Journal just published an article about computational fluid dynamics:

"In scientific computing, the task of simulating fluid flow accurately by solving the Navier-Stokes equation is notoriously difficult. However, it is possible to compute numerical approximations quickly enough that fluids dynamics may be simulated in real time. This article describes a simple fluid dynamics simulator that uses OpenGL to visualize the results in real time..."

To read this article and more, subscribe to The OCaml Journal today!

New book: The Objective Caml Programming Language

Abscissa Press published a new book on OCaml called The Objective Caml Programming Language by Tim Rentsch in September 2008.

Information about this product is sparse: there have been no advertisements, nobody has written a review yet and it is not even clear what subjects the book covers but the description on Amazon implies that this is the first book to cover OCaml's object oriented capabilities in detail.