From: Steven Jenkins Date: 2005-07-08T22:50:48+09:00 Subject: Re: Ruby as mathematical language Steven Jenkins wrote: > One thing to bear in mind, however. Wrapping (whether with SWIG or not) > often requires copying input and output parameters. That's usually not a > big deal, but you might take a substantial performance hit if you're > passing large numbers of large arrays through a wrapper. I looked at gsl_matrix_float.h as an example, and I don't think it's a problem. Barring any surprises, all the wrapping mechanics can be done with pointers. I just discovered that there are two different Ruby GSL's: http://sourceforge.net/projects/ruby-gsl/ http://rb-gsl.rubyforge.org/ The former seems a little more modern. In particular, it uses rb_define_class_under() to define the Matrix class. That may solve the OP's problem right there. Steve