
if test -f "../modar" ; then
  ln -sf ../modar modar
fi
if test -f "../../modar" ; then
  ln -sf ../../modar modar 
fi

./modar -nobak step1_build_solute.inp
./modar -nobak step2_gen_solvent_box.inp type=octa a=48
./modar -nobak step3_add_ions.inp method=mc ionc=0.1
./modar -nobak step4_merge_all.inp
./modar -nobak step5_do_minimization.inp
./modar -nobak step6_heatup.inp ttar=300 tinit=50 nstep=2500 rand=false
./modar -nobak step7_equil_nvt.inp nstep=2500
./modar -nobak step8_equil_npt.inp nstep=5000
./modar -nobak step9_equil_npt_more.inp nstep=10000 #please set nstep to 2500000 for practice
./modar -nobak rdf.inp
awk '{ if($2>0) print $1,-0.6*log($2) }' rdf_K_CL.txt > pmf_K_CL.txt
