Please enable JavaScript to view this site.

Knowledge Base

This section describes the data format for importing binary data to define an object. In this binary import, the data should have values of 1 or 0, indicating that the object is or is not present.

 

Solvers

FDTD

FDE

VarFDTD

Associated files

from text file

usr_importbinary_3d.fsp

usr_importbinary_3d.lsf

usr_importbinary_3d.txt

 

from script matrix

usr_importbinary_3d.fsp

usr_importbinary_3d.lsf

See also

Structures

Import object

usr_binary_import_screenshot_zoom50

 

Note: Imported binary object boundaries

The boundary of the import binary object is positioned between the vertices where the material is present and the vertices where the material is not present. The shape of this implied boundary can be complex, and the viewport does not show the full detail.  The boundary can be moved closer to vertices where the material is present by increasing the "binary threshold" property of the import object. To confirm the boundary that will be used in the simulation by the solver, use an index monitor.

 

Example:

The following lines of script will generate a simple binary object and visualize the actual boundary in an index monitor as shown below. You can see that the actual boundary (right) is not represented by the layout editor window (left).

x = [-3e-6;3e-6];

y = [-2e-6;2e-6];

z = [-1e-6;1e-6];

X = meshgrid3dx(x,y,z);

Y = meshgrid3dy(x,y,z);

Z = meshgrid3dz(x,y,z);

 

binary = zeros(2,2,2);

binary(1,1,1) = 1;

binary(2,1,2) = 1;

 

addimport;

importbinary2(binary, x, y, z);

 

addfdtd;

set("x span", 10e-6);

set("y span", 10e-6);

set("z span", 10e-6);

 

addindex;

set("monitor type","3D");

set("x span", x(2)-x(1));

set("y span", y(2)-y(1));

set("z span", z(2)-z(1));

visualize(getresult("monitor","index preview")); 

 

binary_layout_zoom59 binary_index_zoom55

Copyright Lumerical Inc. | Privacy | Site Map