Use the function mphgeom to display the geometry in a MATLAB figure:
where <geomtag> is the tag of the geometry node to display. If the model only contains a single geometry the tag
<geomtag> can be left empty. When specifying a property the geometry tag is required.
Adding a view property will add some view settings from the COMSOL model such as axes labels (units) and grid and supports hiding of geometric entities. Usually it is sufficient to use the
auto value for the view property:
When running mphgeom the geometry node is automatically built. Set the
build property to specify how the geometry node is supposed to be built before displaying it. Enter:
where build is a string with the value:
'off',
'current', or the geometry feature tag
<ftag>, which, respectively, does not build the geometry (
off), builds the geometry up to the current feature (current), or builds the geometry up to the specified geometry feature node (
ftag).
where <wptag> is the tag of the workplane to use. It is also possible to combine the workplane geometry display with the
build property to display the geometry built up to a certain feature.
Use the parent property to specify the axes handle where to display the plot:
Use mphgeom to display a specified geometric entity. To set the geometric entity, enter the
entity property and set the geometric entity index in the
selection property to:
where entity can be either
'point',
'edge',
'boundary', or
'domain', and
<idx> is a positive integer array that contains the list of the geometric entity indices.
where h is a Patch array of the plotted entities.