An unstrained horizontal spring has a length of 0.32 m and a spring constant of 220 N/m. Two small charged objects are attached to this spring, one at each end. the charges on the objects have equal magnitudes. Because of these charges, the spring stretches 0.020 m, relative to its unstrained length. Determine the magnitude of the charges.
Hooke's law: F=-kx
Spring potential energy; E = 1/2kx^2
Coulomb's law; F=kq1q2/r^2
Voltage; V = kq/r
The Attempt at a Solution
I know energy is conserved so ΔPE + q*ΔV = 0
which gave me 0.5*220*0.02^2 = (8.99*10^9)*q^2*(1/0.34 - 1/0.32)
And q = 5.16 micro Coulombs.
But why do I get a different answer if I say that the forces are equal in equilibrium, i.e.
kx = (8.99*10^9)q^2/r^2