Integrate with two dependent variables and solve a system
Afficher commentaires plus anciens
Hello all!
I will try to explain my problem:
I have two equations and two unknowns "w" and "T". One of the equations is an integral from a to b relative to a variable "r". The integral equation contains two terms that are function of both "w" and "r" and this term calls a value on a interpolated plot. Those terms are defined as Cd and Cl.
The equations are the following, knowing that:
- mult_Cl = CL(-((atan(20/(pi*r)) - pi/18) - atan(w/(omega*r)))*180/pi)* omega*r/(sqrt(omega.^2*r.^2+w.^2));
- mult_Cd = CD(-((atan(20/(pi*r)) - pi/18) - atan(w/(omega*r)))*180/pi)* omega*r/(sqrt(omega.^2*r.^2+w.^2));
and
- CL and CD are interpolated functions
T = integral ( rho/2*(omega.^2*r^2 + w.^2)* ( 4 - 2.35294*(r/50 - 0.1)) *( mult_Cl + mult_Cd ),5,50);
T = 2*pi*rho*R.^2*(Vinf - w)*w
----
Where rho, omega, Vinf are known values
I need to solve both T equations at the same time to find a value of "w" for both.
I have never tried that before, so I am kinda lost. Thank you very much!!
Réponses (1)
Torsten
le 9 Nov 2015
Use MATLAB's fzero on the function
f=@(w)integral ( rho/2*(omega.^2*r^2 + w.^2)* ( 4 - 2.35294*(r/50 - 0.1)) *( mult_Cl + mult_Cd ),5,50) - 2*pi*rho*R.^2*(Vinf - w)*w
to get w.
Then insert in one of the above equations to get T.
Best wishes
Torsten.
4 commentaires
Ricardo Rodrigues
le 9 Nov 2015
Modifié(e) : Ricardo Rodrigues
le 9 Nov 2015
Torsten
le 9 Nov 2015
CL and CD are arrays, not functions.
So CL(-atan...) and CD(-atan...) does not make sense to me.
Best wishes
Torsten.
Ricardo Rodrigues
le 9 Nov 2015
Torsten
le 10 Nov 2015
The first argument to "integral" must be a function handle, not an expression.
Best wishes
Torsten.
Catégories
En savoir plus sur Function Creation dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!