this a code a wrote but it is not working something is wrong with the if condition any ideas ??
if true
clc
ncid=netcdf.open('doubleturbinewindref1_yz.nc');
data=netcdf.getVar(ncid,8,[0 0 0 0],[1 193 194 300]);
zu=netcdf.getVar(ncid,6,0,194);
y=netcdf.getVar(ncid,4,0,193);
time=netcdf.getVar(ncid,0,0,300);
radius=63;
centery=480;
centerz=90;
sumation1=zeros(300);
for s=1:300
sumationofspeed=0;
counter =0;
for p=1:193
for q=1:194
map(q,p)=data(1,p,q,s);
if((((p-centery)^2) +((q-centerz)^2)) <= radius^2 )
sumationofspeed=sumationofspeed+map(q,p);
counter =counter+1;
end
end
end
sumation1(s)= sumationofspeed/counter ;
end
end