       Re: interpolation problem with 2dimensional function

• To: mathgroup at smc.vnet.net
• Subject: [mg107760] Re: interpolation problem with 2dimensional function
• From: dh <dh at metrohm.com>
• Date: Thu, 25 Feb 2010 07:46:16 -0500 (EST)
• References: <hm56n3\$k6v\$1@smc.vnet.net>

```Hi Regina,
you are nearly there, Interpolation can do it, but you need to feed it
correctly. Here is an example:
f[Q_,R_]:= Q R;
x[Q_]:=2 Q;
y[R_]:=0.5 R;
dat=Flatten[Table[{{x[Q],y[R],f[Q,R]}},{Q,0,10},{R,0,10}],2];
fun=Interpolation[dat];
Plot3D[fun[x,y],{x,0,20},{y,0,5}]
Daniel

On 25.02.2010 07:52, Regina wrote:
> i have the following problem:
> i have two functions: f[Q] and x[Q] and i want f[x]. i cant invert
> x[Q], so i do this like this:
> fx=Interpolation[Table[{x[Q],f[Q]},{Q,0,10,0.1}]]
> this work fine.
> but now my function depends on 2 variables: f[Q,R] with given x[Q] and
> y[R]. How can i now interpolate the function f[x,y]?
> (I tried 'ListInterpolation' but couldnt find a solution)
> any help appreciated.
>

--

Daniel Huber
Metrohm Ltd.
Oberdorfstr. 68
CH-9100 Herisau
Tel. +41 71 353 8585, Fax +41 71 353 8907
E-Mail:<mailto:dh at metrohm.com>
Internet:<http://www.metrohm.com>

```

• Prev by Date: Re: SELinux not letting run Mathematica 7
• Next by Date: Re: Parsing awkward text in a nested list
• Previous by thread: interpolation problem with 2dimensional function
• Next by thread: Installing Mathematica 7 in Linux (ferora 12 x86_64)