interpolation 3+ variables and a datavector..

3 visualizaciones (últimos 30 días)
thomas
thomas el 4 de Dic. de 2013
Comentada: thomas el 4 de Dic. de 2013
Hi all I really need some help, with this little problem. :-)
I simply just need a way to make a linear/cubic interpolation in 3+ data variables (x,y,z,...) and get a interpolated result from another vector (r)
I've tried interpn and griddatan, but i couldn't get it to work..
lookup_point=[0.65,1,0.03]
x = 0.6000 0.2000 0.3000 0.5000 0.3000 0.6000 0.7000
y = 2 2 3 1 1 1 1
z = 0.1500 0.0200 0.0200 0.0300 0.0300 0.0200 0.0500
r = 222 333 442 324 532 100 200

Respuesta aceptada

Sean de Wolski
Sean de Wolski el 4 de Dic. de 2013
%Data
x = [0.6000 0.2000 0.3000 0.5000 0.3000 0.6000 0.7000]
y = [2 2 3 1 1 1 1]
z = [0.1500 0.0200 0.0200 0.0300 0.0300 0.0200 0.0500]
r = [222 333 442 324 532 100 200]
lookup_point=[0.65,1,0.03]
% Build interpolant
SI = scatteredInterpolant(x',y',z',r')
SI(lookup_point) %use it
  1 comentario
thomas
thomas el 4 de Dic. de 2013
Nice! What if I would like a cubic interpolation?

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Interpolation en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by