Documentation

This is machine translation

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

poimesh

Make regular mesh on rectangular geometry

poimesh is not recommended. To solve Poisson's equations, use solvepde. For details, see Solve Problems Using PDEModel Objects.

Syntax

[p,e,t] = poimesh(g,nx,ny)
[p,e,t] = poimesh(g,n)
[p,e,t] = poimesh(g)

Description

[p,e,t] = poimesh(g,nx,ny) constructs a regular mesh on the rectangular geometry specified by g, by dividing the "x edge" into nx pieces and the "y edge" into ny pieces, and placing (nx+1)*(ny+1) points at the intersections.

The "x edge" is the one that makes the smallest angle with the x-axis.

[p,e,t] = poimesh(g,n) uses nx = ny = n, and [p,e,t] = poimesh(g) uses nx = ny = 1.

The triangular mesh is described by the mesh data p, e, and t. For details on the mesh data representation, see initmesh.

For best performance with poisolv, the larger of nx and ny should be a power of 2.

If g does not seem to describe a rectangle, p is zero on return.

Introduced before R2006a

Was this topic helpful?