Skip to content

Commit

Permalink
Update WMat.jl
Browse files Browse the repository at this point in the history
Fix wrong call to OrbitalElements functions
  • Loading branch information
MathieuRoule committed Jun 14, 2024
1 parent 13fca59 commit bcd4b9a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/WMat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -61,19 +61,19 @@ function angle_fouriertransform!(
@assert length(result) == output_length "Result array length does not
match the function's output length."

# Integration step
Kwp = (params.ADAPTIVEKW) ? ceil(Int64,params.Kw/(0.1+(1-e))) : params.Kw
Orbitalparams = params.Orbitalparams

if L == 0.0
# need angular momentum
_, L = EL_from_ae(a, e, model, params)
_, L = EL_from_ae(a, e, model, Orbitalparams)
end
if Ω1 == 0.0 || Ω2 == 0.0
# need frequencies
Ω1, Ω2 = frequencies_from_ae(a, e, model, params)
Ω1, Ω2 = frequencies_from_ae(a, e, model, Orbitalparams)
end

# Integration step
Kwp = (params.ADAPTIVEKW) ? ceil(Int64,params.Kw/(0.1+(1-e))) : params.Kw
Orbitalparams = params.Orbitalparams

# Caution : Reverse integration (lower error at apocenter than pericenter)
# -> Result to multiply by -1
dw = -2/Kwp
Expand Down

0 comments on commit bcd4b9a

Please sign in to comment.