On 10.01.2010, at 13:55, Rock wrote:

As for the Java libraries, have you had a look at JScience? From what
I've seen, it's not at all bad.

It's an interesting library, but it lives clearly in the Java universe of strict typing. Moreover, it doesn't really have arrays, just vectors and matrices. Those are very well thought out and implemented, but it's still a more limited approach than providing general N- dimensional arrays.

A problem with all Java libraries is their orientation towards static typing. In Clojure (like in Python), it is natural to have nested data structures, and in particular nested vectors (in Python nested lists) as a conceptual representation of multidimensional arrays. This implies that array indexing operations can return either another array or an element, meaning that the return type must be Object. This can be done in Java but it is not a natural approach. Therefore the Java libraries typically have separate operations for accessing elements and for extracting subarrays, which makes many algorithms unnecessarily cumbersome.

Konrad.

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to