Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
putianyi889 committed Aug 11, 2024
1 parent d22cb7e commit 5e8680c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/BandedSylvesters.jl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ end

buffer(R::BandedSylvesterRecurrence) = R.buffer
function rdiv!(P::BandedSylvesterRecurrence, x)
rdiv!(P.buffer)
rdiv!(P.buffer, x)
P
end

Expand Down
7 changes: 4 additions & 3 deletions src/PseudostableRecurrences.jl
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ export stable_recurrence, precision_shift
Estimates `log2` of the amplification of `P` by performing a full recurrence based on random initial conditions.
"""
function precision_shift(P::AbstractLinearRecurrencePlan)
test, _ = init(P; init=:rand)
shift = 1
testmax = 1.0
test, start = init(P; init=:rand)
shift = 4 # safe choice from experiments
testmax = norm(start, Inf)
rdiv!(test, testmax)
while true
v = step!(test)
if isnothing(v)
Expand Down

0 comments on commit 5e8680c

Please sign in to comment.