# Clamp a plate Use this when a plate or a beam bends under a load and is held along its sides: the plate equation $\nabla^4 u = f$, which takes two conditions on each face. ## Steps 1. Write the equation with the Laplacian applied twice: `pm.laplacian(pm.laplacian(u))`. 2. Write the two conditions of a clamped side, the value and the slope, as a list: `[sp.Eq(u, 0), sp.Eq(pm.normal_derivative(u), 0)]`. 3. Pass the list as `boundary=`. Alone it holds on every face. In a mapping from faces to lists each face takes its own pair. ## Example A square plate under an even load, clamped along all four sides: ```python import sympy as sp import pdemagic as pm x, y = sp.symbols("x y", real=True) u = sp.Function("u")(x, y) plate = pm.Box({x: (0, 1), y: (0, 1)}) clamped = [sp.Eq(u, 0), sp.Eq(pm.normal_derivative(u), 0)] bending = pm.solve( pm.Problem(sp.Eq(pm.laplacian(pm.laplacian(u)), 1), domain=plate, boundary=clamped) ) bending.plot() assert bending.plan.method.kind == "collocation_split" # The deflection in the middle, which the books give as 0.00126532. assert abs(bending(0.5, 0.5) - 1.2653190875e-3) < 1e-11 ``` ## Notes Other sides take other pairs: | A side that is | Its two conditions | |---|---| | clamped | `sp.Eq(u, 0)`, `sp.Eq(pm.normal_derivative(u), 0)` | | simply supported | `sp.Eq(u, 0)`, `sp.Eq(pm.laplacian(u), 0)` | | sliding | `sp.Eq(pm.normal_derivative(u), 0)`, `sp.Eq(pm.normal_derivative(pm.laplacian(u)), 0)` | | free, on a beam | `sp.Eq(w.diff(x, 2), 0)`, `sp.Eq(w.diff(x, 3), 0)` | - For sides that differ, give a mapping: `{(x, 0): clamped, (x, 1): supported, ...}` with a list for each face. - The equation may be $a\,\nabla^4 u + b\,\nabla^2 u + c\,u = f$ with numbers $a$, $b$ and $c$: a plate under tension, or on an elastic foundation. - A free edge of a plate in two dimensions is not taken, and neither is the plate equation in time. In three dimensions the equation is solved on grids up to about 24 points along each axis. - On a shape in the plane a plate that rests on its edge is solved as a system of two equations of second order: see [Systems of equations](../topics/systems.md). - [Beams and plates](../topics/plates.md) explains the conditions. The gallery has [a clamped plate](../gallery/clamped-plate.md) and [a cantilever](../gallery/cantilever.md), and the method has a page of its own: [the plate equation](../methods/plate-equation.md).