Question: @Markiyan Hirnyk  Sorry about that

This question is related to the Question odd ratio evaluation

@Markiyan Hirnyk 

Sorry about that I was not aware of this problem.  I have written now in text as follows:

In the following there needs to be two if conditions applied i.e. one for the k / p = 1,3,5,7   and second

if (m*Pi = k*bo)    and also same for if (m*p is not equal to k*bo)

When I try to solve it says invalid if statement termination:

restart:

n:=2: m:=2: bo:=0.002:alphaa1:=1:r:=0.05:Br:=1.2:mu0:=4*Pi*1e-7:mur:=1.05:Rr:=0.02685:Rm:=0.02985:Rs:=0.02785:alphai:=0:Rsb:=3.2e-3:

eti2:=proc(p::posint,k::posint)

if is((1/2)*k/p-1/2,posint) and (m.Pi) = (k.bo) then

evalf((bo/(2*Pi))*sin((m*Pi)/2))

else 0

if is((1/2)*k/p-1/2,posint) and (m.Pi) = (k.bo) then

evalf(((4*p*m*bo)*cos((k*bo)/2)*sin^2(m*Pi)/2))/(m^2*Pi^2-k^2*bo^2)

else 0

end if

end if

end proc

Best Regards

A.Q

 

Please Wait...