Skip to content
Projects

Legacy cell Poisson

The equations of patchwork.solvers.poisson, declared on the code that implements them and checked by the tests.

solve_poisson

functionsource

Solve -laplace(phi) = rhs on the composite 2D mesh.

balance
∑faces f of iκf (ϕi−ϕj(f))=∣Ki∣ fi\sum_{\text{faces } f \text{ of } i} \kappa_f\,(\phi_i - \phi_{j(f)}) = |K_i|\, f_i
conductance
κf=ℓoverlap12(ha+hb) (between leaf cells),κf=ℓfreeh/2 (to the boundary value)\kappa_f = \frac{\ell_\mathrm{overlap}}{\frac12 (h_a + h_b)} \ \text{(between leaf cells)}, \qquad \kappa_f = \frac{\ell_\mathrm{free}}{h/2} \ \text{(to the boundary value)}
covered
ϕc=1r2∑f⊂cϕf\phi_c = \frac{1}{r^2} \sum_{f \subset c} \phi_f
Assumes
  • 2D, one constant Dirichlet value on the whole boundary (the rectangle's faces and the inner edges)
  • the solve is replicated on every rank
  • the legacy solve: CellOperator has variable coefficients, other conditions and 1D