# Completing the Square

1. Oct 21, 2013

### denjay

1. The problem statement, all variables and given/known data

Consider a charged particle of mass m in a harmonic potential and in the presence also of an
external electric ﬁeld E = E$\hat{i}$. The potential for this problem is simply

V(x) = 1/2 mw$^{2}$x$^{2}$ - qεx

where q is the charge of the particle.

1) Show that a simple change of variables turns this problem into one of a particle under
only a harmonic oscillator potential. (Hint: Complete the square.)

2. Relevant equations

(ax-b)$^{2}$ = a$^{2}$x$^{2}$ - 2abx + b$^{2}$

3. The attempt at a solution

So I know the way to simplify the potential is by completing the square. I only know the way of completing the square when a quadratic equation is equal to 0 but in this case it's a function. So with that formula for (ax-b)$^{2}$ I believe 1/2 mw$^{2}$ is a$^{2}$ and -2ab is -qε but I'm unsure.

So what I got was that b = qε/(2mw$^{2}$) so the equation is

V(x) = 1/2 mw$^{2}$x$^{2}$ - qεx + q$^{2}$ε$^{2}$/2m$w^{2}$ - q$^{2}$ε$^{2}$/2m$w^{2}$ = ($\sqrt{1/2 mw^{2}}x$ - qε/$\sqrt{2mw^2}$)^2 - q$^{2}$ε$^{2}$/2m$w^{2}$

Last edited: Oct 21, 2013
2. Oct 21, 2013

### LCKurtz

You don't have to have an equation. Here's an example, complete the square on: $2x^2-12x$. You factor out the $2$ getting $2(x^2-6x)$. Now inside the parentheses you need a $9$ so add it and subtract it: $2(x^2-6x + 9 - 9)$ which is the same as $2(x-3)^2 - 18$. Try something like that.

3. Oct 21, 2013

### denjay

Cool yeah, I did it the way you suggested and got the same answer as I did in my original post. Thanks!