Skip to content

Commit

Permalink
remove type constraint on DotTheta
Browse files Browse the repository at this point in the history
  • Loading branch information
rveltz committed Sep 1, 2024
1 parent cd026c0 commit 0e43366
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/continuation/Palc.jl
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ DotTheta() = DotTheta( (x, y) -> dot(x, y) / length(x), x -> rmul!(x, 1/length(x
DotTheta(dt) = DotTheta(dt, nothing)

# we restrict the type of the parameters because for complex problems, we still want the parameter to be real
(dt::DotTheta)(u1, u2, p1::T, p2::T, θ::T) where {T <: Real} = real(dt.dot(u1, u2) * θ + p1 * p2 * (one(T) - θ))
(dt::DotTheta)(u1, u2, p1::T, p2, θ, θₚ = one(T) - θ) where {T <: Real} = real(dt.dot(u1, u2) * θ + p1 * p2 * θₚ)

# implementation of the norm associated to DotTheta
(dt::DotTheta)(u, p::T, θ::T) where T = sqrt(dt(u, u, p, p, θ))
Expand Down

0 comments on commit 0e43366

Please sign in to comment.