[Caml-list] solicitation for ocamlbuild examples to go in a new repository

2009-11-28 Thread Erick Matsen
Hello Ocaml-folk-- As the previous and many other posts on this list demonstrate, there is a need for a collection of ocamlbuild examples which can be adapted to various setting. I've started such a project (at Sylvain LeGall's suggestion) at http://forge.ocamlcore.org/projects/obuild-examples/

Re: [Caml-list] ocamlbuild documentation

2009-10-21 Thread Erick Matsen
Hi-- This is such a common theme on this list, I wonder if it would be worth setting up a repository of well-commented Ocamlbuild examples. That would go a long way towards helping beginners (like myself) out. Would people be interested in contributing such examples? Any ideas about where to

Re: [Caml-list] Cartesian product

2009-07-30 Thread Erick Matsen
Hello Ligia--- The following code takes cartesian products of lists: let listListPrepend x ll = List.map (fun l - x :: l) ll let rec cartesianProduct = function | aList :: listList - let prev = cartesianProduct listList in List.flatten ( List.map (fun x - listListPrepend

Re: [Caml-list] speeding up matrix multiplication (newbie question)

2009-02-23 Thread Erick Matsen
Hello Caml-community-- First of all, big thanks to Will Farr, Mike Lin, Martin Jambon, and Markus Mottl. So far, I rewrote things in a non-functional way to avoid unecessary memory allocation, and then used the float operations directly. This resulted in a 4 fold increase in speed. Second, I

[Caml-list] speeding up matrix multiplication (newbie question)

2009-02-20 Thread Erick Matsen
Hello Ocaml community--- I'm working on speeding up some code, and I wanted to check with someone before implementation. As you can see below, the code primarily spends its time multiplying relatively small matrices. Precision is of course important but not an incredibly crucial issue, as the

Re: [Caml-list] speeding up matrix multiplication (newbie question)

2009-02-20 Thread Erick Matsen
Wow, once again I am amazed by the vitality of this list. Thank you for your suggestions. Here is the context: we are interested in calculating the likelihood of taxonomic placement of short metagenomics sequence fragments from unknown organisms in the ocean. We start by assuming a model of

[Caml-list] RESOLVED: problem with LACAML and static linking

2009-01-29 Thread Erick Matsen
Thank you to Mauricio Fernandez, St\'{e}phane Glondu, and Makus Mottl for helping me with this problem. Review of problem: When doing static compilation using LAPACK, encountering the following error: /usr/lib/libblas.a(xerbla.o): In function `xerbla_': (.text+0x0): multiple definition of

Re: [Caml-list] problem with LACAML and static linking

2009-01-28 Thread Erick Matsen
Hello Stephane (and the rest of the ocaml community)--- Thank you for your input here. I do have libgfortran.a, but I might note that it's in /usr/lib/gcc/i486-linux-gnu/4.3/ rather than /usr/lib. This is in contrast to liblapack.a, etc, which just live in /usr/lib. This makes me wonder if this

Re: [Caml-list] problem with LACAML and static linking

2009-01-28 Thread Erick Matsen
...@glondu.net wrote: Erick Matsen a écrit : [...] /usr/lib/libblas.a(xerbla.o): In function `xerbla_': (.text+0x0): multiple definition of `xerbla_' /usr/lib/liblapack.a(xerbla.o):(.text+0x0): first defined here /usr/lib/ocaml/3.10.2/libasmrun.a(unix.o): In function `caml_dlopen': (.text+0x223

[Caml-list] problem with LACAML and static linking

2009-01-27 Thread Erick Matsen
Hello everyone--- I apologize for posting what is certainly a naive question, but I have not been able to find an answer on the web. I am having trouble with static compilation and LACAML. I have used ocamlopt with -ccopt -static a number of times sucessfully (with PCRE and I think GSL), but