Please enable JavaScript to view this site.

Knowledge Base

Navigation: Scripting Language > Manipulating variables

meshgrid4d

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

Create a 4D meshgrid in any direction.

 

Supported Product: FDTD, MODE, DEVICE, INTERCONNECT

 

Syntax

Description

out = meshgrid4d(dim, x1, x2, x3, x4);

The 4D meshgrid function.

dim specifies the dimension along which to create the grid

x1,x2,x3,x4 are the position vectors in each direction

 

Examples

Create a 4D frequency vector from a set of position vectors.

 

x=linspace(-10,10,20);

y=linspace(-10,10,21);

z=linspace(-10,10,22);

f=linspace(0,100,23);

 

F=meshgrid4d(4,x,y,z,f); # create meshgrid in 4th (frequency) dimension

?size(F);         # size should be equal to the size of each position vector

result: 

20 21 22 23 

 

See Also

Manipulating variables, meshgridx, meshgridy, meshgrid3dy, meshgrid3dz

Copyright Lumerical Inc. | Privacy | Site Map