MESH2D, MESH3D, MESH4D, ... - Automatic generation of arrays of entities.

Syntax

MESHdimD name (
ENTITY_TYPE ( entity_type )
SIZE1( size1 ) SIZE2 ( size2 ) ...
NO_LINKS( 1 | 2 )
WRAP( 0 | 1 )
DESCRIPTION( "description" )
PARAMS( ref_parameters, ... )
)

Synopsis

This is the same kind of constructs than Mesh1D but with more than one dimension.

Port names and links:

In order to select which port of an entity will be connected to which port of which neighbour entity, the following policy is applied:
The ith SOURCE port of an entity will be connected to the ith DESTINATION port of the closest following entity through the ith dimension.
When no_links=2, the (dim+i)th SOURCE port of an entity will be connected to the (dim+i)th DESTINATION port of the closest preceding entity through the ith dimension.

Example about links:

In the Mesh2D example below.
The 1st SOURCE port (to_right) is connected to the 1st DESTINATION port (from_left) of the closest following entity through the 1st dimension (x). As no_links = 2, the (dim+1 = 3)rd SOURCE port (to_left) is connected to the 3rd DESTINATION port (from_right) of the closest preceding entity through the 1st dimension.
The 2nd SOURCE port (to_bottom) is connected to the 2nd DESTINATION port (from_top) of the closest following entity through the 2nd dimension (y). As no_links = 2, the (dim+2 = 4)th SOURCE port (to_top) is connected to the 4th DESTINATION port (from_bottom) of the closest preceding entity through the 2nd dimension.

ELF Description

The XSPACING, YSPACING, ZSPACING information used to be defined in the edl description. This is no longer supported. This optional information may be provided with the position of the entity in the EL description.

Example with Mesh2D

Naming entities

All generated entities in this example are named :
_0_0_ _1_0_ _2_0_
_0_1_ _1_1_ _2_1_
_0_2_ _1_2_ _2_2_
_0_3_ _1_3_ _2_3_
The first number is the coordinate in the first dimension, the second is the the coordinate is the second dimension, ...

With this EDL description :
ENTITYLIB (
ENTITY sender (
DESCRIPTION ("sender")
PARAMS ( )
PORTS (
PORT ( to_right, t_readLink, SOURCE)
PORT ( to_bottom, t_readLink, SOURCE)
PORT ( to_left, t_readLink, SOURCE)
PORT ( to_top, t_readLink, SOURCE)
PORT ( from_left, t_readLink, DESTINATION)
PORT ( from_top, t_readLink, DESTINATION)
PORT ( from_right, t_readLink, DESTINATION)
PORT ( from_bottom, t_readLink, DESTINATION)
)
)

MESH2D six (
ENTITY_TYPE (sender)
SIZE1 (3)
SIZE2 (4)
NO_LINKS(2)
WRAP(0)
DESCRIPTION("2-dimensional array of sender entities")
PARAMS()
)
)

STRUCTURE(
-- List of entity instances in top-level model
AENTITY sender SEND ( DESCRIPTION("single entity") )
AENTITY six SIX ( DESCRIPTION("first mesh2d entity") )
AENTITY six SIX2 ( DESCRIPTION("second mesh2d entity"))
)

and this ELF code:

SIX : position (10,10) 80 80
SIX2 : position (300,10) 100 60
SEND : position (500,300)

one will obtain the following result:
Mesh2D Example

Example with Mesh4D

With this EDL description :
ENTITYLIB (
ENTITY sender4 (
DESCRIPTION ("sender through 4 dimensions")
PARAMS ( )
PORTS (
PORT ( to_first, t_readLink, SOURCE)
PORT ( to_second, t_readLink, SOURCE)
PORT ( to_third, t_readLink, SOURCE)
PORT ( to_fourth, t_readLink, SOURCE)
PORT ( back_to_first, t_readLink, SOURCE)
PORT ( back_to_second, t_readLink, SOURCE)
PORT ( back_to_third, t_readLink, SOURCE)
PORT ( back_to_fourth, t_readLink, SOURCE)

PORT ( from_first, t_readLink, DESTINATION)
PORT ( from_second, t_readLink, DESTINATION)
PORT ( from_third, t_readLink, DESTINATION)
PORT ( from_fourth, t_readLink, DESTINATION)
PORT ( back_from_first, t_readLink, DESTINATION)
PORT ( back_from_second, t_readLink, DESTINATION)
PORT ( back_from_third, t_readLink, DESTINATION)
PORT ( back_from_fourth, t_readLink, DESTINATION)
)
)

MESH2D four (
ENTITY_TYPE (sender4)
SIZE1 (4)
SIZE2 (3)
SIZE3 (2)
SIZE4 (2)
NO_LINKS(2)
WRAP(0)
DESCRIPTION("see what happens with Mesh4D")
PARAMS()
)
)

STRUCTURE(
-- List of entity instances in top-level model
AENTITY sender4 SEND ( DESCRIPTION("single entity") )
AENTITY four FOUR ( DESCRIPTION("first mesh4d entity") )
)

and this ELF code:

FOUR : position (10,10) 140 140 70
SEND : position (650,400)

one will obtain the following result:
Mesh4D Example
Frederic Mallet
Last modified: Tue Nov 20 15:32:52 GMT 2001