include("../ho_basis.jl") include("../EC.jl") Λ = 0 m = 1.0 # Distinguishable particles: V12 = bound and V13 & V23 = resonant Va_of_r(r) = -2 * exp(-r^2/4) Vb_of_r(r) = -exp(-r^2 / 3) + exp(-r^2 / 10) E_max = 40 μω_global = 0.4 * exp(-2im * pi / 9) # due to Jacobi coordinates μ1ω1 = μω_global * 1/2 μ2ω2 = μω_global * 2 μ1 = m * 1/2 μ2 = m * 2/3 println("No of threads = ", Threads.nthreads()) basis = ho_basis_2B(E_max, Λ) println("Basis size = ", basis.dim) @time "T1" T1 = get_sp_T_matrix(basis.n1s, basis.l1s, [basis.n2s, basis.l2s]; μω_gen=μ1ω1, μ=μ1) @time "T2" T2 = get_sp_T_matrix(basis.n2s, basis.l2s, [basis.n1s, basis.l1s]; μω_gen=μ2ω2, μ=μ2) @time "Va" Va = get_jacobi_V1_matrix(Va_of_r, basis, μ1ω1) @time "Vb" Vb = get_jacobi_V2_matrix(Vb_of_r, basis, μω_global) @time "Ha" Ha = T1 + T2 + Va @time "Eigenvalues" target_evals, _ = eigs(Ha, nev=5, ncv=50, which=:SR, maxiter=5000, tol=1e-5, ritzvec=false, check=1) display(target_evals) training_c = [-0.5, -0.65, -0.8, -1, -1.2] extrapolating_c = [0.8, 0.6, 0.4, 0.2, 0.1, 0.0, -0.1, -0.2, -0.3] ref_E = -0.5173809356244544 EC = affine_EC(Ha, Vb) train!(EC, training_c; ref_eval=ref_E, CAEC=true) # try CAEC=false !!! extrapolate!(EC, extrapolating_c) exportCSV(EC, "temp/dis_HO_B2R.csv") plot(EC, "temp/dis_HO_B2R.pdf")