Incorrect bifurcation diagram bifurcationkit.jl

You are asking too much here, make it

opt_newton = NewtonPar(tol = 1e-12, maxIter = 10)

You can easily debug these errors by going verbose like opt_newton = NewtonPar(tol = 1e-12, maxIter = 10, verbose = true)

Also, you cannot pass recordFromSolution to codim 2 (you could but you have to dispatch it on BorderedArrays), hence

hp_codim2 = continuation(br, 1, (@lens _.k1),
	ContinuationPar(opts_br, pMin = -0.5, pMax = 0.5,
		ds = -0.001, dsmax = 0.05) ;
	normC = norminf,
	# detection of codim 2 bifurcations with bisection
	detectCodim2Bifurcation = 2,
	# tell to start the Hopf problem using eigen elements: compute left eigenvector
	startWithEigen = true,
	# we update the Hopf problem at every continuation step
	updateMinAugEveryStep = 1,
	# compute both sides of the initial condition
	bothside = true,
	)
2 Likes