Skip to content
Permalink
Browse files

Write energies, occupation numbers and molecular orbitals in double p…

…recision to a Molden file
  • Loading branch information...
tovrstra committed Jan 30, 2019
1 parent a8dfdd7 commit 1860f873aa1a7485d7c79c6a8ffb3d166d23ac4c
Showing with 7 additions and 7 deletions.
  1. +7 −7 psi4/src/psi4/libmints/writer.cc
@@ -201,14 +201,14 @@ void MoldenWriter::write(const std::string &filename, std::shared_ptr<Matrix> Ca
int n = mos[i].second.second;

printer->Printf(" Sym= %s\n", ct.gamma(h).symbol());
printer->Printf(" Ene= %20.10f\n", Ea->get(h, n));
printer->Printf(" Ene= %24.17e\n", Ea->get(h, n));
printer->Printf(" Spin= Alpha\n");
if (Ca == Cb && Ea == Eb && SameOcc)
printer->Printf(" Occup= %7.4lf\n", OccA->get(h, n) + OccB->get(h, n));
printer->Printf(" Occup= %24.17e\n", OccA->get(h, n) + OccB->get(h, n));
else
printer->Printf(" Occup= %7.4lf\n", OccA->get(h, n));
printer->Printf(" Occup= %24.17e\n", OccA->get(h, n));
for (int so = 0; so < wavefunction_->nso(); ++so)
printer->Printf("%3d %20.12lf\n", so + 1, Ca_ao_mo->get(h, so, n));
printer->Printf("%3d %24.17e\n", so + 1, Ca_ao_mo->get(h, so, n));
}

// do beta's
@@ -226,11 +226,11 @@ void MoldenWriter::write(const std::string &filename, std::shared_ptr<Matrix> Ca
int n = mos[i].second.second;

printer->Printf(" Sym= %s\n", ct.gamma(h).symbol());
printer->Printf(" Ene= %20.10lf\n", Eb->get(h, n));
printer->Printf(" Ene= %24.17e\n", Eb->get(h, n));
printer->Printf(" Spin= Beta\n");
printer->Printf(" Occup= %7.4lf\n", OccB->get(h, n));
printer->Printf(" Occup= %24.17e\n", OccB->get(h, n));
for (int so = 0; so < wavefunction_->nso(); ++so)
printer->Printf("%3d %20.12lf\n", so + 1, Cb_ao_mo->get(h, so, n));
printer->Printf("%3d %24.17e\n", so + 1, Cb_ao_mo->get(h, so, n));
}
}
}

0 comments on commit 1860f87

Please sign in to comment.
You can’t perform that action at this time.