alternative (commented) problem formulation
orbit variables, but non-orbit constraints; closer in iterations/s to the original; much faster convergence;
This commit is contained in:
parent
3d99c0aff9
commit
05ee9989b3
@ -92,6 +92,8 @@ function init_OrbitData(name::String)
|
||||
|
||||
orbData = OrbitData(name, Uπs, P, orb_spcnstrm, orb_splap, orb_splap², dims);
|
||||
|
||||
# orbData = OrbitData(name, Uπs, P, orb_spcnstrm, splap, splap², dims);
|
||||
|
||||
return m, orbData
|
||||
end
|
||||
|
||||
@ -111,8 +113,11 @@ end
|
||||
|
||||
function addconstraints!(m::JuMP.Model, data::OrbitData, l::Int=length(data.laplacian); var::Symbol = :λ)
|
||||
λ = m[var]
|
||||
# orbits = load(joinpath(data.name, "orbits.jld"), "orbits");
|
||||
# locate(t, orb=orbits) = findfirst(x->t in x, orb)
|
||||
for t in 1:l
|
||||
d, d² = data.laplacian[t], data.laplacianSq[t]
|
||||
# lhs = constrLHS(m, data, locate(t))
|
||||
lhs = constrLHS(m, data, t)
|
||||
if lhs == zero(lhs)
|
||||
if d == 0 && d² == 0
|
||||
|
Loading…
Reference in New Issue
Block a user