# Electrostatic Separation of Variables in a Square Pipe

1. Oct 30, 2012

### Shmi

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

I'm solving a problem where a conducting pipe with a square cross section is being analyzed to find the potential everywhere in space. The pipe lays along the z-axis, so we're really concerned with the x-y plane. My issue isn't so much the general solution via separation of variables as much as it is finding appropriate boundary conditions to start solving for coefficients.

Imagine a square (as in looking at the pipe face on in the x-y plane) with an infinitesimal separation on two sides separating the square into two symmetric sides. One side is grounded and the other side at some fixed voltage ($V_0$ for instance). The pipe has side length $a$. This is the set-up.

2. Relevant equations

As I understand, assume the potential is separable and then one reasons that the laplacian terms in each direction are constant. Choose constants of alternate sign to get a nice solution with trigonometric and exponential solutions (as Griffiths does in generality).

Generally, for a separable potential in Cartesian coordinates, my potential in the most general form ought to look like:

$$V(x,y) = (A \; e^{kx} + B \; e^{-kx}) (C \; \cos{ky} + D \; \sin{ky})$$

Where k is that constant solution to the laplacian terms.

3. The attempt at a solution

My intuition is to pick a random corner of the pipe to set an origin on and begin trying to describe boundary conditions:

Suppose I choose the bottom left grounded corner for the origin with the infinitesimal gap a distance $a/2$ above the x-axis where the top half is our constant voltage half.

1. $V(0<x< a, 0) = 0$
2. $V(0, 0 < y < \frac{a}{2}) =0$
3. $V(a, 0 < y < \frac{a}{2}) = 0$
That ought to describe my grounded bottom half.

This ought to be my upper half held at a constant potential.
4. $V(0<x< a, a) = V_0$
5. $V(0, \frac{a}{2} < y < a) = V_0$
6. $V(a, \frac{a}{2} < y < a) = V_0$
7. And of course, V goes to zero for x,y at positive or negative infinity

For very large x, namely the last condition, I can get that A should be zero:

$$V(x,y) = Be^{-kx} ( C \cos{ky} + D \sin{ky})$$

Condition 1 also seems to suggest that at the origin, C should be zero (for y=0 I ought to get 0)

$$V(x,y) = Be^{-kx} ( D \sin{ky})$$

And now, for k to be zero at the origin and $y = a/2$, k has to be some integer multiple of pi.

$$k = \frac{n \pi}{\frac{a}{2}} = \frac{2 n \pi}{a}$$

Plugging in k and absorbing B into D, I finally have:

$$V(x,y) = \exp{\bigg(-\frac{2 n \pi}{a} x\bigg)} ( D \sin{\frac{2 n \pi}{a} y})$$

If this approach is right, I know how to find D (via a little Fourier witchcraft). But my problem is that I seem to have a lot of unused boundary conditions and I'm not entirely convinced that this solution, even with clever choice of coefficients will solve this potential. But both of these problems have to do with my lack of intuition regarding separation of variables. Is my choice of origin OK? Are my steps correct? Am I moving in the right direction?

2. Oct 30, 2012

### haruspex

You mean an infinite sum of such terms, right? What about the same with x and y swapped?