Skip to content

Commit e679b31

Browse files
committed
typo in householder
1 parent 649ef09 commit e679b31

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/hessenberg.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ is the first element of the output vector of H*x.
2929
end
3030
xnorm = norm(x[2:end])
3131
α = x[1]
32-
if !iszero(xnorm) || (n == 1 && !iszero(α))
32+
if !iszero(xnorm) || (!iszero(α))
3333
β = (real(α) > 0 ? -1 : +1) * hypot(α,xnorm)
3434
τ = 1 - α / β
3535
α = 1 /- β)
@@ -38,7 +38,7 @@ is the first element of the output vector of H*x.
3838
else
3939
τ = T(0)
4040
x .= 0
41-
β = real(T)(abs(α))
41+
β = real(T)(0)
4242
end
4343
return τ, β
4444
end

0 commit comments

Comments
 (0)