Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Aerospace Airfoil pressure distribution using joukowski transform

  1. Dec 28, 2009 #1
    I am given a project to transform an airfoil from a cylinder using joukowski transform. The cylinder is in zeta plane and the airfoil is in z plane. I did the plotting and i got the airfoil shape using matlab. but i want to know how to plot the pressure distribution over the airfoil.

    The inputs to my program are:

    Velocity, Angle of attack, coordinates of center of circle(zeta plane), radius of circle(zeta plane).
    Can somebody please tell me how to plot pressure distribution for an airfoil?

    I am using Matlab to do the stuff but i m getting weird plots for pressure distribution. Please help me of someone can...deadline near
  2. jcsd
  3. Dec 28, 2009 #2
    Have you tried http://www.desktopaero.com/appliedaero/airfoils1/airfoilpressures.html" [Broken]?
    Last edited by a moderator: May 4, 2017
  4. Dec 29, 2009 #3


    User Avatar
    Science Advisor

  5. Dec 29, 2009 #4
    Do your own work. This is easy stuff.
  6. Dec 30, 2009 #5
    I m stuck somewhere as i m not that good in programming. I know the physics behind that but i m not able to write a computer program for that.
  7. Dec 30, 2009 #6
    Thank u for ur help. I m having problems in plotting the graphs.
  8. Dec 30, 2009 #7
    What exactly do you need to do in terms of your code?
  9. Dec 30, 2009 #8
    I m stuck on how to write the loops for the points on airfoil where i have to plot the pressuer values
  10. Dec 30, 2009 #9
    You can use code tags by typing in:

    Code (Text):
    <copy paste your code here>[code]

    Replace the second code with /code for it work properly. Then you can explain what you are doing and what is going wrong. I've read about doing what you're asking in several books, but I have not implemented it, so I'll try and give a stab at it because I'd like to see it work. My background is flight dynamics and controls, not aerodynamics, so we need to be careful in doing things right. You will also have to supply me with the equations you are using, and what books they are coming from.
  11. Dec 30, 2009 #10
    Code (Text):

    clear all
    close all

    v_inf = input('  Enter the Speed [m/s]: ');
    v = v_inf/v_inf;
    alpha = input('  enter angle of attack [deg]: ');
    alpha = alpha*pi/180;
    s_x = input('  Circle Origin, X_0 [m]: ');
    s_y = input('  Circle Origin, Y_0 [m]: ');
    s = s_x + 1i*s_y;
    r = input('  Radius [m]: ');

    rho = 1.225;

    lambda = s_x + sqrt(r^2-s_y^2)%% this is the "C" in the currie book

    %  beta = (alpha);
    %  k = 2*r*v*sin(beta);
    %  Gamma = k/(2*pi) %CIRCULATION

    w = v * exp(1i*alpha);

    % toll = +5e-4;

    x = meshgrid(-10:.2:10);
    y = x';

    z = x + 1i*y;

    % Inside-circle points are Excluded!
    for a = 1:length(x)
        for b = 1:length(y)
            if abs(z(a,b)-s) <=  r
                z(a,b) = NaN;

    J = z+lambda^2./z;

    %GRAPHIC - Circle and Joukowski Airfoil
    angle = 0:.1:2*pi;
    z_circle = r*(cos(angle)+1i*sin(angle)) + s;
    z_airfoil = z_circle+lambda^2./z_circle;

    % L = v_inf*rho*Gamma;
    % L_str = num2str(L);


    %Circulation necessary to satisfy Kutta Condition

    Kutta_C = 4*pi*v_inf*r*sin(alpha+asin(s_y/r))

    %Chord Length
    c_length = max(real(z_airfoil))-min(real(z_airfoil))

    h = 2*s_y

    %thickness t??
    t = max(imag(z_airfoil))-min(imag(z_airfoil))

    % complex POTENTIAL
    %f =w*(z) + (v*exp(-(1i)*alpha)*r^2)/lambda + 1i*k*log(z);

    % Coefficient of lift from circulation
    %lift force, Y = pro*v_inf*circulation
    %C_lift = Y/(1/2)*pro*v_inf^2*l
    C_lift = 2*Kutta_C/(v_inf*c_length)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      

    %Coefficient of lift from thickness, chord length and curvature approach in

    Curr_cl = 2*pi*(1+0.77*(t/c_length))*sin(alpha+2*(h/c_length))

    w_tilde = v_inf.*exp(-i.*alpha) + i.*Kutta_C./(2*pi.*((r-s)-z)) + v_inf.*(r.^2)*exp(i.*alpha)./(((r-s)-z).^2);
    w = w_tilde./(1 + (z-(r-s)).^2/(s.^2));
    value = abs(w.^2);

    %aphi = (s.^2 - lambda^2)/s.^2;
    hold on
    axis equal
    axis on
    axis([-10 10 -10 10])

    hold on
    % contour(real(J),imag(J),real(f),[-10:.5:10])

    axis equal
    axis on
    axis([-10 10 -10 10])
    title('Transformed Airfoil');

    P_airfoil = 99500 + 0.5*1.225*((v_inf.^2) - (abs(w).^2));
    %Pressure distribution
     a = linspace(0,c_length,101);
     Cp = (P_airfoil - 99500)./(0.5*1.225*((v_inf.^2) - (abs(w).^2)));
    %Coefficient of pressure

    % cp = 1 - 4*sin(t).^2 + 2* G / (pi*a*V_i) *sin(t) - (2* G/ (pi*a*V_i) )^2 ;


    this program takes the coordinates of a cylinder in one plane and transforms it into an airfoil using the joukowski tranformation. The pressure distribution part is at the end. This is not working. I have no ideas on how to appraoch that. Sorry if i sound ignorant.
  12. Dec 30, 2009 #11
    First thing I will say, is ditch the user input at the command window. Have a variable for speed and AoA. Just set those variables before you hit run. You only really want user input if you are making something for other people to run. Every time you have to test your program, you waste time entering in values.
  13. Dec 30, 2009 #12
    Code (Text):

    clear all
    close all

    Actually, the way to do it is a

    [ code ] tag
    <your code>
    followed by a slashed code tag
    [ /code ]

    and leave out the spaces I've used to disable it.
  14. Dec 30, 2009 #13
    Can you explain this first block of code

    Code (Text):
    v_inf = input(' Enter the Speed [m/s]: ');
    v = v_inf/v_inf;
    alpha = input(' enter angle of attack [deg]: ');
    alpha = alpha*pi/180;
    s_x = input(' circle Origin, X_0 [m]: ');
    s_y = input(' Circle Origin, Y_0 [m]: ');
    s = s_x + 1i*s_y;
    r = input(' Radius [m]: ');
    What is v, and why don't you just define it as 1?
    Also, what is s_x, s_y, and s?
  15. Dec 31, 2009 #14
    s_x and s_y are the coordinates of the center of the circle and r is the radius of the circle in a complex plane which i have to transform to an airfoil using joukowski transform.

    s is he distance of the center of the circle from the origin. The imaginary part is there because this is a complex plane.

    i can define v as 1 but this doesnot make any difference
  16. Dec 31, 2009 #15
    If v is one, then define:


    it is a bad habbit to do what you did because when someone looks at your code they are goign to wonder why you are dividing a variable by itself, and takes more computational power to perform a division operation than a declaration. These kinds of things are big no-nos in blade element or CFD code, where you have to do lots of operations/loops.

    Edit: Also, why do you have '1i'?

    I would rewrite your block of code as follows:

    Code (Text):

    %Convert degrees to radian
    d2r = pi/180; s

    %Define freestream velocity
    v_inf = 30;  %[m/s]
    v = 1;

    %Define AoA
    alpha = 5*d2r;

    %Define transform coordinates
    s_x = 0.2; %[m]
    s_y = 0.2 %[m]
    s = s_x + i*s_y;
    r = 2; %[m]
    Last edited: Dec 31, 2009
  17. Dec 31, 2009 #16
    Thank you for that advice. I will implement that.
  18. Dec 31, 2009 #17
    True. M on a learning curve at the moment. Ur advices are helpful.
  19. Dec 31, 2009 #18
    I corrected your spelling above. I edited my post, but lets move on to the next block of code.
  20. Dec 31, 2009 #19
    Moving to the next block of code, can you explain what's going on here:

    Code (Text):
    rho = 1.225;

    lambda = s_x + sqrt(r^2-s_y^2)%% this is the "C" in the currie book

    % beta = (alpha);
    % k = 2*r*v*sin(beta);
    % Gamma = k/(2*pi) %CIRCULATION

    w = v * exp(1i*alpha);

    % toll = +5e-4;

    x = meshgrid(-10:.2:10);
    y = x';

    z = x + 1i*y;
  21. Jan 6, 2010 #20

    I just realized the flaw in my code. Thank you all for your help.
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Similar Threads - Airfoil pressure distribution Date
Aerospace No drag thin airfoil theory / Pressure drag Jan 21, 2018
Aerospace Determination of Static Presssure on an Airfoil May 8, 2017
Aerospace Stagnation Pressure on Airfoil Oct 16, 2012
How to plot pressure distribution around airfoil Mar 25, 2012
Aerospace Airfoil pressure distribution Mar 21, 2011