This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.


Shorthand command for contour plot

This page describes the legacy workflow. New features might not be compatible with the legacy workflow.


h = pdecont(p,t,u)
h = pdecont(p,t,u,n)
h = pdecont(p,t,u,v)


pdecont(p,t,u) draws 10 level curves of the PDE node or triangle data u. h = pdecont(p,t,u) additionally returns handles to the drawn axes objects.

If u is a column vector, node data is assumed. If u is a row vector, triangle data is assumed.

The geometry of the PDE problem is given by the mesh data p and t. For details on the mesh data representation, see Mesh Data.

pdecont(p,t,u,n) plots using n levels.

pdecont(p,t,u,v) plots using the levels specified by v.

This command is just shorthand for the call


If you want to have more control over your contour plot, use pdeplot instead of pdecont.


collapse all

Plot the contours of the solution to the equation $- \Delta u = 1$ over the geometry defined by the L-shaped membrane. Use Dirichlet boundary conditions $u = 0$ on $\partial \Omega$.

[p,e,t] = initmesh('lshapeg');
[p,e,t] = refinemesh('lshapeg',p,e,t);
u = assempde('lshapeb',p,e,t,1,0,1);

See Also

| |

Introduced before R2006a

Was this topic helpful?