Please enable JavaScript to view this site.

Knowledge Base

Navigation: Scripting Language > Adding Objects

add2dpoly

We've made some changes. Use 'Ctrl-F5' to clear your browser cache.
Scroll Prev Top Next More

Adds a 2D polygon in the simulation space.

 

Supported Product: FDTD, MODE, DEVICE

 

Syntax

Description

add2dpoly;

Adds a 2D polygon in simulation space.

This function does not return any data.

 

Example

The following script creates a 2D matrix to store the vertices of a polygon and uses it to create a 2D polygon primitive on the XY plane.

vtx = [1,0;2,2;4,2;4,1;3,1]*1e-6;  # microns

add2dpoly;

set("name","2D_polygon");

set("surface normal",3);  #  1 = x (normal), 2 = y (normal), 3 = z (normal)

set("vertices",vtx);

set("z",2e-6);

 

See Also

Adding Objects, add2drect, Structure - 2D polygon, Structure - 2D rectangle

Copyright Lumerical Inc. | Privacy | Site Map