Optimization
This commit is contained in:
parent
384e64e5d1
commit
ad2b0449ba
4
dirac.jl
4
dirac.jl
|
|
@ -28,8 +28,8 @@ end
|
||||||
the other parameters are the same from dirac!(...)."
|
the other parameters are the same from dirac!(...)."
|
||||||
function boundaryValue(κ, p, E, Φ0, W0, B0, A0, r_max)
|
function boundaryValue(κ, p, E, Φ0, W0, B0, A0, r_max)
|
||||||
prob = ODEProblem(dirac!, [0, 1], (0, r_max))
|
prob = ODEProblem(dirac!, [0, 1], (0, r_max))
|
||||||
sol = solve(prob, RK4(), p=(κ, p, E, Φ0, W0, B0, A0))
|
sol = solve(prob, RK4(), p=(κ, p, E, Φ0, W0, B0, A0), saveat=[r_max], save_idxs=[1])
|
||||||
return sol(r_max)[1]
|
return sol[1, 1]
|
||||||
end
|
end
|
||||||
|
|
||||||
"Find all bound energies between E_min (=0) and E_max (=mass) where
|
"Find all bound energies between E_min (=0) and E_max (=mass) where
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue