calculated Psi and added results to main.m