MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Extracting Interpolating Function via mathlink

  • To: mathgroup at smc.vnet.net
  • Subject: [mg50786] Extracting Interpolating Function via mathlink
  • From: theoryboy at my-deja.com (Peter Saffrey)
  • Date: Tue, 21 Sep 2004 03:49:02 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

I'm writing an application that interfaces with Mathematicas
differential equation solving routines via mathlink. The equations are
loaded and solved and then I need to extract the resulting
interpolating functions for use in the rest of my application. At the
moment, I have a mathematica function which dumps the data points, one
by one, which I grab and insert into C++ objects. This works, but it's
very slow on large functions - when there are 10000 data points, this
takes about 30 seconds per function.

I suspect the reason for the poor performance is that I'm calling too
many mathlink functions - each data point is three "getpacket" calls,
one for the a list header, and one for each part of the data point. Is
there a way I can do this more quickly? How about exporting the whole
list of points as some kind of C++ structure I can then parse with
using mathlink? Does anybody know how I might do this?

Thanks,

Peter


  • Prev by Date: Re: ScatterPlot3D Plot Symbol
  • Next by Date: Re: Re: Forcing a Derivative
  • Previous by thread: Re: Font rendering in Mathematica 5.0 on Mac OS X
  • Next by thread: Re: Extracting Interpolating Function via mathlink