Typo in Ex. H.4.2

I believe that instead of the condition to prove being E=-\left|V\right|, it should be E=-\left|E\right| instead.

Hello @EmGiXIII, welcome to the forum!

Yes, I think you’re correct, which would make E an unfortunate choice of notation for the number of edges. I’ll think of how to fix it and will update it soon :slight_smile:

Thank you for spotting this, you have great attention to detail!

Alvaro

1 Like

To evaluate ground state energy Here it is coming as -4. I could not fidured out where it went wrong

my_guess1 = np.array([1,0,1,1,1]) # MODIFY THIS
my_guess2 = np.array([1,0,1,1,0]) # MODIFY THIS

print("The expected energy for", my_guess1, "is", energy(my_guess1), ".")
print("The expected energy for", my_guess2, "is", energy(my_guess2), ".")

Hello @SUDHIR_KUMAR_SAHOO ,

my_guess1 gives an energy of -2, so it’s not the correct ground state! The my_guess2 is correct. There are two valid ground states, and you must find both.

Hope this helps!

Alvaro

1 Like

I have already done that thanks