writing 2-rdm
Closed this issue · 4 comments
Hi @SebWouters, There's a request over at the forum for printing out the 2-RDM from psi4. I'm glad to oblige and have located the correct object, but the requester also mentioned being able to write to file through chemps2 --twodmfile=$filename
on the binary. I pulled the current version and tried it out but it doesn't recognize the option, nor can I find it in the code. Thought I'd check with you and see if there was a version issue going on.
http://forum.psicode.org/t/printing-or-disking-out-dmrg-2pdm-in-psi4/272/4?u=loriab
Hi @loriab,
It's the function
void CheMPS2::TwoDM::write2DMAfile(const string filename) const;
which is accessible via
theDMRG->get2DM()->write2DMAfile( filename );
I've deprecated the command line option
--twodmfile
in v1.7 onwards. But you can include it again in the psi4 interface if you like.
Best wishes,
Sebastian
Thanks, Sebastian, I had found the function and started to get it into place in loriab/psi4@aa27768 but the existing psi4 interface doesn't have a TwoDM
object, and I had trouble extracting a SyBookkeeper
to initialize one. That's why I thought it might be a versioning issue. Can I extract a SyBookkeeper
from theDMRG
?
Hi @loriab
From the current API, I wouldn't know why you need the SyBookkeeper or create a TwoDM object yourself?
Just use
theDMRG->get2DM()->write2DMAfile( filename );