The problem has been proved to be convex. why is NaN,thanks.

%--------------------------------------------参数设置----------------------------------------------------------------

```
W=[350,245;175,90;100,120;160,130;395,290;45,50;240,200;110,200];%地面用户位置
yita=[0.96,0.72,0.94,1,0,0,0,0];%各用户卸载率
D=[37*1000,49.69*1000,37.88*1000,34.64*1000,0,0,0,0];%任务量(单位为bit)
V=[270,60;130,240];%窃听UAV位置
y=[205,160];%合法UAV位置
Hu=120;He=[110,130];%UAV高度
X=10;%位置估计误差
T=0.16;%时延限制
beta1=10^(-5);beta2=10^(-4);%信道功率增益
o2=10^(-14);%噪声功率
k=10^(-27);%功率消耗因子
r=10^(-11);%自干扰效率
F=1000;%每bitCPU转数
B=10^6;%传输带宽
fuavmax=2*10^(9);f0=2*10^(8);%合法UAV/用户本地计算能力
fiu=fuavmax/4;%UAV分配给卸载用户的计算能力
Puavmax=1;Puemax=0.1;%UAV/用户功率限制
B=10^(6);%传输带宽
Pue=[0.08;0.08;0.08;0.08;0.028;0.024;0.011;0.015];%初始用户功率
Pjamm=0.005;%合法UAV发送的干扰功率
% rou=r*Pjam+o2;%噪声+干扰功率
%--------------------------------------------信道增益-----------------------------------------------------------------
hiu=zeros(1,8);
hiemax=zeros(2,8);
hkemin=zeros(2,8);
heumin=zeros(1,2);
l=zeros(1,4);
for i=1:4
l(i)=D(i)*yita(i)/(B*(T-F*D(i)*yita(i)/fiu));%卸载传输的最低速率（时延限制下）
end
for i=1:8
for v=1:2
hiu(i)=beta1/(Hu^2+norm(y-W(i,:))^2);
hiemax(v,i)=beta1/(He(v)^2+(norm(W(i,:)-V(v,:))-X)^2);
hkemin(v,i)=beta1/(He(v)^2+(norm(W(i,:)-V(v,:))+X)^2);
heumin(v)=beta2/((Hu-He(v))^2+(norm(y-V(v,:))+X)^2);
end
end
h=[hkemin(1,:)*Pue,hkemin(2,:)*Pue];
%--------------------------------------------optimize----------------------------------------------------------------
cvx_begin
variables Pjam C0 r0
g=hiu*Pue+r*Pjam+o2;
q=hiu*Pue+r*Pjamm+o2;
maximize C0
subject to
r0>=0;
for i=1:4
for v=1:2
1+(hiemax(v,i)*Pue(i)*10^(11)*inv_pos((hkemin(v,:)*Pue-hkemin(v,i)*Pue(i)+Pjam*heumin(v)+o2)*10^(11)))<=2^(r0);
end
log2(g)-(log2(q-hiu(i)*Pue(i))+r*(Pjam-Pjamm)*10^(11)/((q-Pue(i)*hiu(i))*log(2)*10^(11)))-r0>=C0>=0;
log2(g)-(log2(q-hiu(i)*Pue(i))+r*(Pjam-Pjamm)*10^(11)/((q-Pue(i)*hiu(i))*log(2)*10^(11)))>=l(i);
0<=Pjam<=Puavmax-k*fiu*fiu*fiu*4;
end
cvx_end
```