Phil Trelford's Array
POKE 36879, 255

F# Units of Measure talk at Open Source eXchange III

July 26, 2009 09:36 by phil

The Open Source eXchange III was a mini-conference where members of the ALT.NET community talked about their favourite alternative .NET tools that increase programmer productivity. Units of Measure is a cool language feature in F#, developed by Andrew Kennedy, that lets you easily annotate values with units like metres, kilograms or seconds. Then F# type inference kicks in to give you automatic checking of your unit types at design and compile time, but cost you nothing at run time, e.g.

  let gravityOnEarth = 9.8f<m/s^2> // Acceleration

Following a bit of a Apollo 40th Anniversary theme, I presented 3 code samples (attached):

  • Statistics
  • Orbital Mechanics
  • Lunar Lander


Further reading:

Categories: .Net | F#
Actions: E-mail | Permalink | Comments (1) | Comment RSSRSS comment feed


October 21. 2011 16:29


Pingback from

Free Software | Free Templates | SEO Services |  » DoFollow Blogs-II

Add comment

(Will show your Gravatar icon)

  Country flag

  • Comment
  • Preview