include("../EC.jl") training_c = [2.6, 2.4, 2.2, 2.0, 1.8] extrapolating_c = 0.0 : 0.2 : 1.2 training_ref = -2.22 # complete list not needed because identification is simple extrapolating_ref = [4.076662025307587-0.012709842443350328im, 3.613318119833891-0.007335804709990623im, 3.1453431847006783-0.004030580410326795im, 2.672967129943755-0.00211498327461944im, 2.196542557810288-0.0010719835443437104im, 1.7164583929199813-0.0005455212208182736im, 1.233088227541505-0.0003070320106485624im] include("../p_space_3body_resonance.jl") H0 = H # Vp = perturbation to make the state artificially bound Vp_of_r(r) = -exp(-(r/3)^2) Vp_l(j, k, kp) = Vl_mat_elem(Vp_of_r, j, k, kp; atol=atol, maxevals=maxevals, R_cutoff=R_cutoff) @time "Vp block diagonal part" begin Vpb_blocks = [kron_sum(get_V_matrix((k, kp) -> Vp_l(j1, k, kp), ks, ws), spzeros(length(ks), length(ks))) for (j1, _) in js] Vpb = blockdiag(sparse.(Vpb_blocks)...) end @time "Vp2_HO" Vp2_HO = get_jacobi_V2_matrix(Vp_of_r, basis_ho, μω_global; atol=atol, maxevals=maxevals) @time "Vp2" Vp2 = W_left * Vp2_HO * transpose(W_right) @time "Vp" Vp = Vpb + Vp2 weights = repeat(kron(ws, ws), jmax + 1) EC = affine_EC(H0, Vp, weights) train!(EC, training_c; ref_eval=training_ref, CAEC=true) extrapolate!(EC, extrapolating_c; ref_eval=extrapolating_ref) exportCSV(EC, "temp/Berggren_B2R.csv") plot(EC, "temp/Berggren_B2R.pdf")