in reply to double **

There isn't one. You've got a couple options that I know of. First, you could write pull the NVs out of your AVs and put them into a new double [][] that you New() and Safefree() on the spot. That will use lots of memory if your array is big. Alternately you could have your Perl code keep your data in packed C arrays to begin with, using something like Tie::CArray. Then you can write a little XS to put out the double** from that and pass it to your C code.

-sam

Replies are listed 'Best First'.
Re^2: double **
by pdupre (Acolyte) on Jul 03, 2008 at 15:55 UTC
    Hello Sam, thank for your email. SO my conclusion is that it is going to be efficient to call a c routine with a AoA, I imagined that the machine representation was close between a AoA and a double [][]! It looks like that I am wrong. Will it it be a lot more efficient to pass several double [] ? Regards. Patrick Dupre The University of York
        Thank again, I am just surprise to not find something ready to go (ie. conversion between double [][] and AoA). Patrick Dupre The University of York
      Yup, AVs and C arrays are very different beasts. If the volume of data is the same I don't think you'll see a big difference between a double[][] and several double[]s but only you know the details well enough to judge.

      -sam