SciD is a collection of numerical routines and bindings written in and for the D programming language. Currently, the collection is rather small (see below) but expanding.
For the time being, SciD simply aims to be a freely usable repository of numerical algorithms. The long-term goal is to ultimately produce a full-fledged, general-purpose scientific library à la the GNU Scientific Library or SciPy.
2014-12-02: SciD has suffered from bit rot due to lack of maintenance, and has failed to compile with recent DMD versions. This is fixed now, and the library happily compiles with DMD 2.066.1. Also, SciD is on code.dlang.org now!
2013-04-10: Updated to compile with DMD 2.062.
2012-04-15: Updated to compile with DMD 2.059.
2012-03-27: Exciting times: Will Cristi Cobzarenco's linear algebra project be accepted for yet another Google Summer of Code? The project started as a SciD fork (though it does not contain much of SciD anymore), and it will hopefully become part of Phobos (or, possibly, be reintegrated in SciD).
Below is a list of the main modules. Click on the links to get to the documentation (updated 2011-06-25).
There are also a few subpackages (click one of the links above and you'll find the API docs for these in the package tree):
SciD is very much a work in progress, and as such, the API is subject to breaking changes without notice. Furthermore, for the time being, no attempt will be made to retain compatibility with older versions of DMD and Phobos.
BLAS and LAPACK should be available in the package repositories of most Linux distros. Windows users may want to download the prebuilt binaries that are available on the MultiArray project page on DSource (look for multiarray-deps.zip under "Vitals").
Otherwise, the only way to get SciD is to download the development version from the repository. To download the code, use the following command:
git clone git://github.com/kyllingstad/scid.git
This will create a new directory named 'scid' containing a duplicate of the SciD repository. When you have already cloned the repository and want to update it with the latest changes, run:
To build SciD, use the D program
build.d, found in the root directory of the repository. The best way to run it is using the rdmd program which is bundled with the DMD compiler. To build the library and generate header files, run:
Any extra command line arguments will be passed on to DMD, so you can do for example:
rdmd build -inline -release -O
To generate the documentation, run:
rdmd build html
The generated files can be found in the
generated/ subdirectory. Currently, further installation must be done manually, but this will improve soon.
Warning: If you are using the gdmd front end to GDC, you should (due to a bug in gdmd) compile and run
build.d as follows:
gdmd build.d && ./build [arguments]
For numerical code, performance is key. However, there are enough libraries that provide awesome performance behind a butt-ugly API, so SciD need not go down that road. The design priorities are therefore, in order,
Luckily, D is the perfect programming language for hiding high-performance code behind a beautiful API, so ultimately SciD should be able to provide as good performance as other libraries.
As stated in the introduction, a goal of SciD is to become a community project. Contributors are very welcome, so if you want to participate, let me know.
Here's a small tip: There is a lot of established and extremely well tested numerical code lying around the Internet, just waiting to be ported to D. A lot of it is in the public domain, so we are free to use it in any way we want. Instead of spending a lot of time re-inventing the wheel, port some existing code and try to improve on it when you get it working.
Here are a few starting points: