|
vbaでウインドウス10で以前のverでは値になっていたが今#NAME?と出る
数値にするには
VBAはFunctionで計算している
Function KA(C!, Gam!, rHo1!, sHo1!, fai1!, der!, aru1!, sit!) As Single
'Function KA(C!, Gam!, rHo!, sHo!, fai!, der!, aru!, sit!) As Single
Dim CC1 As Single
Dim CC2 As Single
Dim CC3 As Single
Dim RC1 As Single
fai = fai1 / 180 * 3.1415 'φ ラジアン
der = der / 180 * 3.1415 'δ
aru = aru1 / 180 * 3.1415 'α
sit = sit / 180 * 3.1415 'θ
'1.ok
CC1 = (Cos(fai1 - sit)) ^ 2 'cos(φ-θ)^2
'***********************************************************************
'2.ok
CC2 = (Cos(sit)) ^ 2 * Cos(sit + der) '分母-1 cosθ^2*cos(θ+δ)
'データ条件
RC1 = Sin(fai1 - aru1)
If fai1 < aru1 Then RC1 = 0
'3.
CC3 = (1 + ((Sin(fai1 + der) * RC1) / (Cos(sit + der) * Cos(sit - aru1))) ^ 0.5) ^ 2
'{1+√((sin(φ+δ)*sin(φ-α))/((cos(θ+δ)*cos(θ-α))}^2
KA = CC1 / (CC2 * CC3)
'ka=cc1/(cc2*cc3)
End Function
|
|