Fitting 3d data

8 vues (au cours des 30 derniers jours)
Bhar_tex
Bhar_tex le 1 Mar 2018
Commenté : Torsten le 1 Mar 2018
I have a nonlinear 3D data. Can someone help in providing me a function that fits my data? I would like to use that function for interpolation/extrapolation. Appreciate your help.

Réponses (1)

Torsten
Torsten le 1 Mar 2018
I suggest you interpolate directly from the data:
https://de.mathworks.com/help/matlab/ref/scatteredinterpolant.html
Best wishes
Torsten.
  2 commentaires
Bhar_tex
Bhar_tex le 1 Mar 2018
I am confused how to use function, F (= scatteredInterpolant(x,y,z)) for interpolation. i.e., if I have xnew,ynew and how can I predict corresponding znew using this F?
Torsten
Torsten le 1 Mar 2018
Put your first column in vector x, your second column in vector y and your third column in vector z.
Then call
F = scatteredInterpolant(x,y,z);
For a query point (xq,yq)
zq = F(xq,yq)
gives you the interpolated z-value.
Best wishes
Torsten.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Interpolation dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by