CMU-MS-DAS-Modern-Programming-Mini / ClassAssignmentNo3

Creative Commons Zero v1.0 Universal
0 stars 0 forks source link

Small Variation in correct value for calc_fock_matrix #5

Open epiechow opened 3 years ago

epiechow commented 3 years ago

Hello,

When I test my "calc_fock_matrix" I am getting very slightly off values for what I should be getting.

For Fuv[2, 5] I am getting -1.6751501447185013 when I should be getting -1.6751501447185015 (off at the last digit by two). Is this an acceptable level to be off by, so I can change the value it is being tested against, or do I need to fix my code to be exactly correct?

Thank you!

shots47s commented 3 years ago

look at pytest.approx

epiechow commented 3 years ago

pytest.approx works, thank you!