# Griffiths intro to electrodynamics Laplace's equation (boundary conditions only!)

## Homework Statement

A surface at z = 0 is held at potential V (x, y) = V0 cos(qx) sin(qy). Find the
potential in the region z > 0.

## Homework Equations

Laplace's equation in Cartesian coordinates

## The Attempt at a Solution

I wrote at least a page of my past 2 attempts at a solution. For some reason I was logged out during writing it and when I logged back in, everything was gone....

Anyway to summarize: (note I need only boundaries, I can do the math)

Attempt 1: Make a geometry and assume boundary conditions. That is, find the potential inside this geometry that extends only to points above the origin and with it carries the solution to z > 0

Attempt 2: Solve it directly from laplace's equation.

I think I knw V(x) and V(y) at the surface potential from the problem set up, so all I have to do is find V(z) from laplace's equation.

X(x) = Cos(qx)
Y(y) = sin(qy)
Z(z) = ???

Plugging these in I get:

Z(z) = e^(-qz) or e^(qz)

But these must have some coefficients and I suppose I can work backwards and find the boundary conditions that satisfy general solutions to each 2nd order Diff Eq with these potentials. Then find the coefficients from Fourier's trick.

I have been working on this for days....Any help would be greatly greatly and I mean greatly appreciated!

Thank you!

Attempt 2:

## Answers and Replies

I'm working on the same problem. Was there also a dielectric problem in this set? I made a post about it.

Also, we are given V(x,0) and V(y,0) are these the same as X(x) and Y(y). And where did you plug in to get Z(z)? I'll see what I can get, just reply or private message me if you did the dielectric one or if you make progress on this one, please.

gabbagabbahey
Homework Helper
Gold Member
I think I knw V(x) and V(y) at the surface potential from the problem set up, so all I have to do is find V(z) from laplace's equation.

X(x) = Cos(qx)
Y(y) = sin(qy)
Z(z) = ???

No, you know $V(x,y,z=0)=X(x)Y(y)Z(z=0)=V_0 \cos(qx) \sin(qy)$. That doesn't necessarily mean that $X(x)= \cos(qx)$, $Y(y)=\sin(qy)$ and $Z(z)=1$. As a simple counterexample, $X(x)= 2\cos(qx)$, $Y(y)=3\sin(qy)$ and $Z(z)=\frac{1}{6}$ also satisfy your boundary condition.

What was your general solution for $V(x,y,z)$? What do you get when you plug $z=0$ into that solution and set it equal to your boundary condition?

Thank you for responding!

I haven't found the general solution to V(x,y,z). The method I've been using and am familiar with is from Griffith's. First he identifies the boundary conditions, then writes the general solution in terms of a summation from those boundary conditions. I'm just not sure what the boundary conditions would be in this particular case in finding the potential z > 0.

I know that the general solution to each ordinary differential equation from separation of variables is:

X(x) = Asin(kx) + Bcos(kx)
Y(y) = Csin(ly) + Dcos(ly)
Z(z) = esqrt(k2+l2+e-sqrt(k2+l2

But setting up the boundary conditions or knowing what they are is the hardest part in this example. I tried the problem a few different ways, but am I correct in assuming that whatever boundary condition I pick, for example:

V = 0 when y = 0

It also has to satisfy my surface potential V(x,y) = V0cos(qx)sin(qy)?

But if this is the case then

V = 0 when x = 0 won't work since V(0, y) = v0sin(qy)

Edit:

Is it possible to assume that I can define a point z = a, infinitely far from the origin such that the potential vanishes there? So maybe a boundary condition could be:

V = 0 when z = a

Then I would have to change my constants around a bit, yielding:

Z(z) = Fsin(lz) + Gcos(lz)

But the only problem is, V does not equal 0 when z = 0, so this is rather messy and doesn't provide a clean solution. The constant G won't go to zero.

Ah I have no idea.

Last edited:
gabbagabbahey
Homework Helper
Gold Member
I haven't found the general solution to V(x,y,z)...

I know that the general solution to each ordinary differential equation from separation of variables is:

X(x) = Asin(kx) + Bcos(kx)
Y(y) = Csin(ly) + Dcos(ly)
Z(z) = esqrt(k2+l2+e-sqrt(k2+l2

First, I'm sure you meant to write

$$Z(z)=Fe^{\sqrt{k^2+\ell^2}z}+Ge^{-\sqrt{k^2+\ell^2}z}$$

Right?

Well, this is the general solution,

$$V(x,y,z)=X(x)Y(y)Z(z)=\sum_{l,k}( A_{l,k}\sin(kx) + B_{l,k}\cos(kx))(C_{l,k}\sin(ly) + D_{l,k}\cos(ly))(F_{l,k}e^{\sqrt{k^2+\ell^2}z}+G_{l,k}e^{-\sqrt{k^2+\ell^2}z})$$

But setting up the boundary conditions or knowing what they are is the hardest part in this example...
It also has to satisfy my surface potential V(x,y) = V0cos(qx)sin(qy)?

Yes, this BC is given to you.

Is it possible to assume that I can define a point z = a, infinitely far from the origin such that the potential vanishes there? So maybe a boundary condition could be:

V = 0 when z = a

Well, on physical grounds, you would expect the potential to vanish infinitely far from the sources, so

$$\lim_{z\to\infty}V(x,y,z)=0$$

seems like a reasonable expectation.

Then I would have to change my constants around a bit, yielding:

Z(z) = Fsin(lz) + Gcos(lz)

No you wouldn't, an increasing exponential will blow up as $z\to\infty$ and a decreasing one will go to zero. If the $F$ in $Z(z)=Fe^{\sqrt{k^2+\ell^2}z}+Ge^{-\sqrt{k^2+\ell^2}z}[/tex] is non-zero then, your potential will become infinitely large as [itex]z\to\infty$. Therefor, in oredr to satisfy your boundary condition, $F$ must be zero.

That leaves you with a potential of the form

$$V(x,y,z)=\sum_{l,k}e^{-\sqrt{k^2+\ell^2}z}( A\sin(kx) + B\cos(kx))(C\sin(ly) + D\cos(ly))$$

What does that make $V(x,y,0)$? Compare that with your other boundary condition and use "Fourier's trick".

Last edited:
NOTE: For some reason, the integral symbols work when I hit "preview changes" but it's coming out scrambled when I save the changes. I wrote it in a messier way what it's supposed to be, please bear with me!

But what could we integrate with respect to our upper and lower bounds?

Our V(x,y, z = 0) = (Asin(kx)+Bcos(kx)(Csin(ly)+Dcos(ly) = V0cos(qx)sin(qy)

The above is a double sum in k and l, but in order to use Fourier's trick, don't we need bounds that represent our surface?

Are we assuming that our surface is finite? If so, how do we define the length of our surface if we don't know what the surface looks like? We only have a condition when z = 0...

I know we will have two integrals, one for dx and another for dy

Would it look something like this:

Sum Cn * $$\int[sin(kx)+cos(kx)]sin(k'x) dx$$ * $$\int[sin(ly)+cos(ly)]sin(l'y)dy$$ = $$\int Vocos(qx)sin(qx)sin(k'x)sin(l'y)dxdy$$

Sum Cn * int[sin(kx)+cos(kx)]sin(k'x) dx * int[sin(ly)+cos(ly)]sin(l'y)dy = intVocos(qx)sin(qx)sin(k'x)sin(l'y) dxdy

I guess the only way this works is if l = l' , k = k' (zero otherwise) but what are the limits of integration? It couldn't be 0 to infinity? I guess I am unsure how I would solve this.

***One thing about the integral and Fourier's trick is that we're picking out a value out of the summation. Since we're even this value in the boundary problem (q), would k = l = q?

Last edited:
gabbagabbahey
Homework Helper
Gold Member
The above is a double sum in k and l, but in order to use Fourier's trick, don't we need bounds that represent our surface?

No, there's no need to integrate over the entire surface. Just use the orthogonality conditions for sines and cosines. For example, eq 3.33 from Griffiths (3rd ed.) implies that

$$\int_{0}^{\pi}\sin(ly)\sin(l'y)dy=\left\{\begin{array}{lr}0, &\text{if}\; l\neq l' \\\frac{\pi}{2}, & \text{if}\; l=l'\end{array}\right.$$

So, if you multiply both sides of your equation for $V(x,y,0)$ by $\sin(l'y)$ and integrate over $y$ from zero to $\pi$, you will end up extracting a single term from the summation. Doing the same thing with $\sin(k'x)$, $\cos(k'x)$ and $\cos(l'y)$ will give you 4 equations and four unknowns which you can then solve. (Keep in mind that the coefficients $A$, $B$,...$G$ will depend on the value of $l$ and $k$)

Alternatively, you can save yourself from some tedious calculations and realize that $V(x,y,z)=V_0\cos(qx)\sin(qy)e^{-\sqrt{2q^2}z}$ will satisfy both of your boundary conditions, as well as Laplace's equation, and hence must be the correct potential according to the uniqueness theorem.

Of course, seeing how much you are struggling with this, I recommend you do the tedious calculations and verify that you get this answer for the sake of practice.

Last edited:
Amazing...I completely understand this now. Thank you so much. I really appreciate your help!

gabbagabbahey
Homework Helper
Gold Member
Actually, I made a significant error: there's no reason to assume that $l$ and $k$ are restricted to integer values. In fact, they can be any real number and still satisfy Laplace's equation, and neither of your boundary conditions tell you that they must be integers. For that reason, the sum in the general solution should be replaced by an integral over all values of $l$ and $k$ (actually, it is sufficient to just consider positive values, since $\cos(-u)=\cos(u)$ and $\sin(-u)=-\sin (u)$):

$$V(x,y,z)=\int_0^{\infty}\int_0^{\infty}( A_{l,k}\sin(kx) + B_{l,k}\cos(kx))(C_{l,k}\sin(ly) + D_{l,k}\cos(ly))(F_{l,k}e^{\sqrt{k^2+\ell^2}z}+G_{ l,k}e^{-\sqrt{k^2+\ell^2}z})dldk$$

However, this doesn't affect the final answer.