Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ufechner7 committed Oct 22, 2024
1 parent afdaa9a commit 32c7485
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions src/KPS4.jl
Original file line number Diff line number Diff line change
Expand Up @@ -328,21 +328,16 @@ Updates the vector s.forces of the first parameter.
va_xz2 = va_2 - (va_2 y) * y
va_xy3 = va_3 - (va_3 z) * z
va_xy4 = va_4 - (va_4 z) * z
alpha_2 = rad2deg- acos2(normalize(va_xz2) x) - alpha_depower) + s.set.alpha_zero
alpha_3 = rad2deg- acos2(normalize(va_xy3) x) + rel_steering * s.ks * s.set.cs_4p) + s.set.alpha_ztip
alpha_4 = rad2deg- acos2(normalize(va_xy4) x) - rel_steering * s.ks * s.set.cs_4p) + s.set.alpha_ztip
s.alpha_2 = alpha_2
s.alpha_2b = rad2deg/2 + asin2(normalize(va_xz2) x))
s.alpha_3 = alpha_3
s.alpha_3b = rad2deg/2 + asin2(normalize(va_xy3) x))
s.alpha_4 = alpha_4
s.alpha_4b = rad2deg/2 + asin2(normalize(va_xy4) x))

if s.set.version == 3
alpha_2 = rad2deg/2 + asin2(normalize(va_xz2) x) - alpha_depower) + s.set.alpha_zero
alpha_3 = rad2deg/2 + asin2(normalize(va_xy3) x) - rel_steering * s.ks * s.set.cs_4p) + s.set.alpha_ztip
alpha_4 = rad2deg/2 + asin2(normalize(va_xy4) x) + rel_steering * s.ks * s.set.cs_4p) + s.set.alpha_ztip
alpha_3 = rad2deg/2 + asin2(normalize(va_xy3) x) + rel_steering * s.ks) + s.set.alpha_ztip
alpha_4 = rad2deg/2 + asin2(normalize(va_xy4) x) - rel_steering * s.ks) + s.set.alpha_ztip
drag_corr = 1.0
else
alpha_2 = rad2deg- acos2(normalize(va_xz2) x) - alpha_depower) + s.set.alpha_zero
alpha_3 = rad2deg- acos2(normalize(va_xy3) x) + rel_steering * s.ks) + s.set.alpha_ztip
alpha_4 = rad2deg- acos2(normalize(va_xy4) x) - rel_steering * s.ks) + s.set.alpha_ztip
drag_corr = DRAG_CORR
end

Expand Down

0 comments on commit 32c7485

Please sign in to comment.