Laplace equation solution for electrical potential I'm trying to simulate a lightning in a programming language and I started to read how it can be done, and I found that it could be done by using the Laplacian Growing Model. My experience with mathematics is limited.
I think I understood the algorithm described here in section 4.1. My problem is that I don't know how to solve the Laplacian equation for the lightning model seen at (b) Lightning configuration.
I tried to catch something up from here but that configuration is a rectangle and the lightning configuration seems like a triangle or maybe a circular arc. 
I know my boundary conditions would be the potential at the origin and the potential at the ground but I really don't know how to translate this in mathematical language and how to resolve the laplace for it.
Can you help me with a solution (along with an explanation) or a tutorial "for dummies"?
 A: Hmm.. maybe I am 2 years late to the party, but what the heck.
You can also pose this as a Global Linear Optimization. Setting up a matrix $L_2$ norm minimization problem: $$\min({\bf v})\left\{{\bf C}\|{\bf v}\|_2 + \|{\bf L(v+d)}\|_2\right\}$$ where $\bf C$ contains a binary diagonal matrix mask like the one nomnom called "boundary condition", the $\bf d$ is a vectorization of boundary condition values. So $\bf v+d$ is the result, and the $\bf L$ is a matrix representation of the laplacian operator, typically some suitable discrete filter. First term punishes changes to boundary conditions. Second term punishes laplacian of result from differing from 0.

So why bother doing all this instead of just taking the first numerical scheme we can find? It is because it is very convenient framework if we want to attack bigger and more involving problems. There is no limit as to how many terms we can have and we can have any constraints we like as long as we can express them as matrix operations on the data. Also as there exist so many numerical methods to solve linear optimizations we are not restricted to one specific numerical method but can use the whole arsenal of linear solving techniques.
A: Solving Laplace's equation for a rectangular boundary on which the values are known is easy. When the values are known on the boundary,  this is called "Dirichlet boundary conditions"
Often however,  the values are known on some parts of the boundary but only the derivative is known on other parts. The latter is known as Neumann boundary conditions. If you have both,  it is called mixed boundary conditions. An example of the latter is finding current flow in a printed circuit track that has one voltage on a boundary at one end and another voltage at a boundary at the other end but all we know about the rest of the boundary is that no current flows off the sides. 
When the shapes of the boundaries are arbitrary you are going to need an irregular grid and this is a seriously difficult problem.  
