V(x)=-Fx
differentiating V(x) gives us E(x) where E is the field intensity
E(x)=-F
then the force acting on the body P = q*E(x) .... where q =charge
P=-Fq=ma ... where a = acceleration
Integrating the acceleration gives the speed
v=-Fq/m t + c1 ... where c1 is integration constant
Integrating the speed gives the position
v=-Fq/2m t^2 + c1t * + c2... where c2 is integration constant
So A= -Fq/2m
B=c1
C=c2
and for the action to be minimum B=0 C=0 .... done