Skip to content

Commit

Permalink
fix delay margin print when infinite
Browse files Browse the repository at this point in the history
  • Loading branch information
baggepinnen committed Feb 6, 2024
1 parent 59b75d3 commit 4b21b2c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/diskmargin.jl
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ function Base.show(io::IO, dm::Diskmargin)
delaymarg = π/180 * dm.ϕm / dm.ω0
print(io, "Delay margin: ", delaymarg, " s")
if isdiscrete(dm.L)
println(io, ", ", floor(Int, delaymarg / dm.L.Ts), " samples")
samples = delaymarg / dm.L.Ts
println(io, ", ", isfinite(samples) ? floor(Int, samples) : samples, " samples")
else
println(io)
end
Expand Down

0 comments on commit 4b21b2c

Please sign in to comment.