VSLab has just been updated with full support for Visual Studio 2008 Shell and the F# CTP release. It has been a rough couple of weeks for the VSLab team as F# CTP changed a number of things and they have been working hard to put together a compatible release. In this article I talk about a bit about what exactly VSLab is and walk you through creating a free VSLab installation.

 

What is VSLab?

VSLab is a Matlab-like interactive environment which is implemented on top of Visual Studio 2008 and F#. It is designed to speed the development of scientific applications and make visualizing data quick and easy. One of the great benefits, besides being free, is that VSLab allows you to compile your applications into binaries which can be easily redistributed. Also, because the code is being run on the CLR it is, in most cases, much faster than the notoriously slow Matlab and Mathematica.

The F# CTP was updated a few days ago in order to fix a number of bugs. Even if you aren't interested in VSLab, now would be a great time to update your CTP installation.

 

VSLab Quick Installation Instructions

With these two releases it's very easy to create your own free Matlab-Like Visual Studio environment. It's important that these steps are performed in order as each step depends on the previous step. Installing Managed DirectX is not strictly necessary but you will not be able to use the VSLab visualizations without it.

Prerequisites
If you already have a version of Visual Studio 2008 installed, it must be updated to SP1 before you can continue. The SP1 update package is available here.

All previous versions of F# and VSLab must be uninstalled before starting this process. Also, these steps must be followed in the order they appear here.

1) Install Visual Studio 2008 Shell.
1a) Download Visual Studio 2008 Shell (integrated mode).
1b) Run the installer to Extract VS 2008 Shell Package to a temporary directory.
1c) Inside that directory, run vside.enu.exe to launch the actual VS2 2008 Shell installer.

2) Install F# CTP
2a) Download F# September 2008 Release Installer (InstallFSharp.msi)
2b) Run the F# September CTP Installer, the default settings work great.

3) Install VSLab
3a) Download VSLab
3b) Run the VSLab Installer, the default settings work great here too.

4) Install Managed Direct X
4a) Download the latest DirectX End-User Runtimes (August 2008)
4b) Run the installer to extract the DirectX End-User Runtimes to a temporary directory.
4c) Inside that directory, Run DXSETUP.exe to update your DirectX drivers.

You now have a complete VSLab installation. 


Quick Start Information

1) First off, launch Visual Studio 2008 to get started.
2) Go to File->New->Project
3) Select Project Type: Visual F# and the VSLab Template
4) Hit Shift+Alt+V To activate the VSLab Interface
5) Right Click on your project and Click Add->New Item
6) On the left select the VSLab Category and Select the a the Viewer3D template.

Select all of the code before the calls to Close() and hit Alt-Enter to execute.


The real version is even animated.

Congratulations, you are now all set up to play with VSLab and F#.

Keys:
Shift+Alt+V: Starts The VSLab Interface
Alt-Enter: Send selected code to the F# interactive tool window

References:
The VSLab Tutorial
is a great resource but has not yet been updated for the new VSLab release. Note that the key bindings have changed as mentioned above and keep an eye on the VSLab Blog for updates.

 

edit: fixed a link and added a picture from VSLab.