HARP_Opt Error

Good Morning,

I am working on rotor optimization and there is a weird error that is popping up. The situation is as follows:

  1. If I model the rotor with my FoilFam (edited and modified as per HARP instructions), the model starts to iterate and proceed forward - NO ERROR

  2. If I select “Model Blade with Circular Chord” I get the following error despite creating all files in same format with same Reynolds no. in all the files.

[i]
User inputs defined. Initializing…

??? Attempted to access AF2(:,4); index out of bounds because size(AF2)=[60,3].
Error in ==> Interp_Thickness_Coefs at 121
Error in ==> HARP_Opt>Optimize_Callback at 726
Error in ==> gui_mainfcn at 96
Error in ==> HARP_Opt at 47
Error in ==>
@(hObject,eventdata)HARP_Opt(‘Optimize_Callback’,hObject,eventdata,guidata(hObje
ct))
??? Error while evaluating uicontrol Callback
[/i]

File for the circular cross section

AeroDyn airfoil file. Compatible with AeroDyn v13.0.
Circular cross section with multiple Reynolds Numbers.
Data came from PROPID. Fourth column is the min. pressure coefficient (does not vary with Re).
3 Number of airfoil tables in this file
2.5 Reynolds numbers in millions
0.0 Stall angle (deg)
0.0 Zero lift angle of attack (deg)
0.0 Cn slope for zero lift (dimensionless)
0.0 Cn at stall value for positive angle of attack
0.0 Cn at stall value for negative angle of attack
0.0 Angle of attack for minimum CD (deg)
0.57 Minimum CD value
-180.0 0.0 0.57 -3.0
180.0 0.0 0.57 -3.0
EOT1
3.5 Reynolds numbers in millions
0.0 Stall angle (deg)
0.0 Zero lift angle of attack (deg)
0.0 Cn slope for zero lift (dimensionless)
0.0 Cn at stall value for positive angle of attack
0.0 Cn at stall value for negative angle of attack
0.0 Angle of attack for minimum CD (deg)
0.721 Minimum CD value
-180.0 0.0 0.721 -3.0
180.0 0.0 0.721 -3.0
EOT2
4 Reynolds numbers in millions
0.0 Stall angle (deg)
0.0 Zero lift angle of attack (deg)
0.0 Cn slope for zero lift (dimensionless)
0.0 Cn at stall value for positive angle of attack
0.0 Cn at stall value for negative angle of attack
0.0 Angle of attack for minimum CD (deg)
0.788 Minimum CD value
-180.0 0.0 0.788 -3.0
180.0 0.0 0.788 -3.0
EOT3

Can someone kindly guide me, as what is the problem that I am facing.

Pranav Bhatnagar

Hi Pranav,

I might know solution to problem you are facing. This might not be clear in the user guide … but when you use “circular root” option you should also enter an additional percent thickness value for the airfoil at the root. For example, if a circle is at blade root (i.e. a 100 % thick “airfoil”), then you should enter ThickVals = [100 thick1 thick2 … thickN] and you should create a corresponding airfoil file with filename something_1000.dat (the important part is suffix that notes a 100% thick airfoil).

Try adding “100” at beginning of the ThickVals field, let us know if that works

Also, do all of your airfoil files have the same number of tables for Reynolds number? I think that all airfoil files requires same number of Reynolds tables … maybe check for that too.

Best,
Danny Sale
University of Washington
PhD student - Mechanical Engineering
depts.washington.edu/nnmrec/
fluids.me.washington.edu/

Hello Danny,

Thank you very much for the solution. Still the problem was not solved. I tried to debug the error and go back to the source code. I located the file and the line mentioned. Then I started studying the code and understood the problem. The problem was, My new extrapolated data did not have the 4th column (pressure) while the default 100% section had it. I looked everything carefully by anyhow missed it. Later on correction it was working.

All the best for your PhD.
Thanks,

Pranav