psi4 / psi4numpy

Combining Psi4 and Numpy for education and development.
BSD 3-Clause "New" or "Revised" License
337 stars 157 forks source link

MP2 Hessians #69

Closed kcpearce closed 5 years ago

kcpearce commented 5 years ago

Description

Adds MP2 Hessians

What are your new additions? Please provide a brief list.

Any questions for the community?

Status

codecov-io commented 5 years ago

Codecov Report

Merging #69 into master will increase coverage by 0.17%. The diff coverage is 100%.

loriab commented 5 years ago

Cfour would be a good choice. Not going to be accuracy-affecting approximations, easy to get a Cartesian Hessian out of. Known for higher-order derivatives. Let me know if you want a reference run.

dgasmith commented 5 years ago

Cool! Thank you for your continued work on this.

kcpearce commented 5 years ago

@loriab I'm currently having issues getting my version of CFOUR to work. If you get a chance, can you give me a reference run with the following following input/options.

Full disclosure: there could be problems with my input file. I only want the analytic hessian, but can't find the appropriate keyword to get that by itself, so I went with a vib freq calc instead. I also can't find out the highest print level allowed, but I'd like to get as much info in the output as possible.

O
H 1 R 
H 1 R 2 A    

R=1.1
A=104

*CFOUR(CALC=MP2,
BASIS=STO-3G,
VIB=ANALYTIC,
SCF_CONV=12,
PRINT=10)
loriab commented 5 years ago
dgasmith commented 5 years ago

@kcpearce This seems close, what else is needed before it is ready to go?

kcpearce commented 5 years ago

@dgasmith Just need to debug my t2 derivative code. Then it should be straightforward to get the hessians matching. And definitely a little cleaning up before review. Working on it now.

dgasmith commented 5 years ago

Awesome! I think this will make a really nice addition to the Psi4Numpy tutorials.

dgasmith commented 5 years ago

@kcpearce Looks like these are pretty close to ready to go?

kcpearce commented 5 years ago

@dgasmith Doing some further cleaning up of my code, but it's about ready to go! I'll get it pushed for review by the end of today.

kcpearce commented 5 years ago

@dgasmith Quick question: I'm using CFOUR's hessians to test mine, and I know we can use psi4 to interface to cfour for simple things (energies, gradients, etc.), but we can NOT do this for hessians, correct?

loriab commented 5 years ago

You can run hessians through the interface but the results aren’t parsed.

kcpearce commented 5 years ago

@loriab Okay, so I take it that I should just keep them hard coded in for my test at the end of the code?

loriab commented 5 years ago

Yes, hardcoding is the way to go here. Even in an analytic bs findif case, best to have a hard coded reference.

kcpearce commented 5 years ago

I ran pytest locally, and am failing test_SAPT0_ROHF on the final psi4.compare_values call. Any idea as to why?

dgasmith commented 5 years ago

Sorry no idea off the top of my head, how wrong is the answer?

kcpearce commented 5 years ago

Ind200,r: computed value (-0.000251) does not match (0.000000) to 5 digits

dgasmith commented 5 years ago

Ah pretty wrong... @loriab This looks like Psi4 changed the names of its variables?

kcpearce commented 5 years ago

Note: that test failure isn't caught by travis since it's marked as a long test and not run by travis

dgasmith commented 5 years ago

Can you make an issue about this then and we can go ahead and merge your PR when ready.

dgasmith commented 5 years ago

This is an elemental bug that I have just issues a patch for and not your fault. If this is ready to go we can review and merge.

kcpearce commented 5 years ago

Ready for review and merge on my end

kcpearce commented 5 years ago

@dgasmith Good to go on my end!