Effacer les filtres
Effacer les filtres

How to extract specific data from the data files?

1 vue (au cours des 30 derniers jours)
hj lee
hj lee le 5 Oct 2020
Commenté : hj lee le 5 Oct 2020
Hello,
CL = [ 0.572526 0.601916 0.631107 ];
CD = [ 0.024868 0.025337 0.025902 ];
How to output the value of CD when CL is 0.6?
I want to use linear interpolation but I don't know how to do.
Thakns for reading.
  2 commentaires
Ameer Hamza
Ameer Hamza le 5 Oct 2020
What model does the data follow? Linear? Polynomial? Or is there some other nonlinear relation between CL and CD?
hj lee
hj lee le 5 Oct 2020
Both are okay! thanks for comment!

Connectez-vous pour commenter.

Réponse acceptée

KSSV
KSSV le 5 Oct 2020
Modifié(e) : KSSV le 5 Oct 2020
iwant = interp1(CL,CD,0.6)
This is the procedure:
CL = [ 0.572526 0.601916 0.631107 ];
CD = [ 0.024868 0.025337 0.025902 ];
xi = 0.6 ;
yi = interp1(CL,CD,xi) ;
plot(CL,CD)
hold on
plot(xi,yi,'*r')
  1 commentaire
hj lee
hj lee le 5 Oct 2020
That's perfect answer thanks!

Connectez-vous pour commenter.

Plus de réponses (0)

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