Detecting pitchfork bifurcations from side branch

@rveltz Is BifurcationKit.jl capable of detecting a pitchfork bifurcation when the continuation approaches along a side branch? I always use detect_bifurcation=3 as you suggested on slack, and have spent more time than I should exploring the continuation parameter space, but have very rarely had success with this. MWE:

using BifurcationKit, Plots

f(x, p) = @. -x^3 - p * x
prob = BifurcationProblem(
	f, [1.0], -1.0; record_from_solution=(x, p; _...) -> x[1]
)
contp = ContinuationPar(
	p_min=-1.0,
	p_max=1.0,
	dsmax=5e-2,
	detect_bifurcation=3,
)
br = continuation(prob, PALC(), contp; bothside=true)
plot(br)

Result

If I relax dsmax, the continuation may jump to the central branch and continue to the right, but in any case, the bifurcation is not detected.

I’m not surprised that this doesn’t work. Along this branch, no eigenvalue changes sign; it only tangentially touches zero before growing back with the same sign. Even so, the bifurcation is technically detectable since tol_stability > 0, but in practice, I find that I need to take extremely small steps for reliable detection—for this MWE, I need dsmax <= 2e-5, resulting in more than 100_000 steps to complete the continuation of this branch.

It’s OK if this is simply a hard problem that numerical continuation can’t reliably help with. Just curious if there’s an approach that might be more successful.

This solution is also unsatisfactory because it detects two bifurcations rather than one:

Trying to branch off of these points, for example using bifurcationdiagram, is likely to create a mess and may not even locate the central branch.

Oh I see what you mean now!
detect_bifurcation is based on a change of stability but there is no one along the branch. The only way to see it is through the fold and compute the normal form

This is a Bug

1 Like