function [CL CD CM] = Coef0015(aoa)
%
% PURPOSE: Find the coefficients of lift and drag where the angle of attack
%          (AOA) may be greater than stall for Reynolds numbers in the range
%          20k-60k.  This is table look-up with a cubic spline interpolation.  
%
%          aoa is in radians.
%
% REFERENCE: "Aerodynamic Characteristics of Seven Symmetrical Airfoil
%            Sections Through 180-Degree Angle of Attack For Use In
%            Aerodynamic Analysis of Vertical Axis Wind Turbines"
%            R.E. Sheldahl, P.C. Klimas SAND80-2114  
%
% FIRST AUTHOR: Rob McEwen, 13 Feb 2008
%
% CHANGE LOG:
%
% Read in data off the charts.  I'm going mostly from the Sandia chart, but
% since it is for a higher Reynolds number, I'm going to blend in data for
% Re=42.9k from PNA, 3rd Ed. Vol 3, p.294, for aoa less than stall.
%
% In keeping with the chart, aoa is in degrees.
%
  persistent DM_aoa Daoa DCL DCD DCM;
  if( isempty(Daoa) )

   fprintf('Coef0015: Initializing parameter arrays.\n');
   Daoa=[0  2   4   6  8   10  12 14 16  20  30  40  50  60  70  80  90]';
   DCL =[0 .19 .38 .57 .76 .8 .75 .7 .65 .6  .8  1.  1.  .85 .6  .35 .1]';
%  DCD =[3 2.7 2.5 2.1 1.9 2.0 2.1 2.5 3 30  60  90  120 150 165 170 175]';
   DCD =[1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.7 6 30  60  90  120 150 165 172 175]';
   
   DM_aoa = [0   2.5   4.5   6.5   8.5   10.5   12.5   13.5   14.5   15.5   16    18    20    24      30   35    40    45    50     55     60     65     70     75     80     85     90]';
   DCM =    [0   .01  .016   .017   .034   .04    .05   .045   .0    -0.038    -.05  -.051   -.055 -.065   -.11  -.14  -.16  -.2   -.25  -.26    -.25  -.3     -.25   -.4    -.45  -.35  -.35]';
%
%  Contine for aoa > 90
% 
   Daoa = [Daoa' 100   110   120   130   140   150   160   170   180]';
   DCL  = [DCL'  -.2   -.45  -.7   -.9   -1.0  -.8   -.63  -.9    0 ]';
   DCD  = [DCD'  172  165    150   120   90    60    30    10     3 ]'/100;
   
   DM_aoa = [DM_aoa' 95    100   105   110   115   120   125   130   135   140   145   150    155    160    165    170    175   180]';
   DCM =    [DCM'    -.35  -.35  -.35  -.35  -.35  -.35  -.35  -.375 -.4  -.4   -.4  -.37    -.32  -.3     -.28   -.4   -.3    0 ]';
   
%
%  Add odd symmetry for negative values:
%
   Daoa = [  -[Daoa(end:-1:2)];   Daoa  ];
   DCL  = [  -[DCL(end:-1:2)];    DCL  ];
   DCD  = [   [DCD(end:-1:2)];    DCD  ];
   Daoa = Daoa*pi/180;
   
   DM_aoa = [ -[DM_aoa(end:-1:2)];   DM_aoa  ];
   DM_aoa = DM_aoa*pi/180;
   DCM  = [  -[DCM(end:-1:2)];    DCM  ];


  end
  
  
  idx = 1;
  while(~isempty(idx))
    idx = find(aoa > pi);
    aoa(idx) = aoa(idx)-2*pi;
  end
  idx = 1;
  while(~isempty(idx))
    idx = find(aoa < -pi);
    aoa(idx) = aoa(idx)+2*pi;
  end      
      
      
  CL = interp1(Daoa, DCL, aoa, 'spline');
  CD = interp1(Daoa, DCD, aoa, 'spline');
  CM = interp1(DM_aoa,DCM, aoa, 'linear');
%
% This is for the unit test.
%
  if(1)
    assignin('caller','Daoa',Daoa);
    assignin('caller','DCL',DCL);
    assignin('caller','DCD',DCD);
    assignin('caller','DM_aoa',DM_aoa);
    assignin('caller','DCM',DCM);
  end

end
