This is a question about contraposition i.e.
if P implies Q then it is logically equivalent to not Q implies not P (~Q implies ~P)
What is wrong with the following taken from Graph Theory?
Let G be a (finite and simple) graph with n ≥ 3 vertices. We denote by deg v the degree of a vertex v in G, i.e. the number of incident edges in G to v. Then, Ore's theorem states that if
deg v + deg w ≥ n for every pair of distinct non-adjacent vertices v and w of G
then G is Hamiltonian.
If P = deg v + deg w ≥ n for every pair of distinct non-adjacent vertices v and w of G
and
Q = G is Hamiltonian.
Is it a valid statement to say, using ~Q implies ~P, that
Not Hamiltonian implies that deg v + deg w < n for every pair of distinct non-adjacent vertices v and w of G
This argument suggests a way of working out if a graph is not Hamiltonian! What is wrong with the argument?