M3D File Format

The Input file to the Mat3d toolkit is easily readable and customizable. The cif2mat convertor converts the CIF file into an ASCII file with the format:

   # start of structure 1
   {
     [anchor: <true|false>]
     [link i start]
     [link j member]
     [rotate: pivot information]
     [reflector start]
     [reflector geometry]
     [reflector end]
      < geometry>
         ...
      < geometry>
   } 
         ...

   # start of structure n
   {
     [anchor: <true|false>]
     [link k start]
     [link m member]
     [rotate: pivot information]
     [reflector start]
     [reflector geometry]
     [reflector end]
      < geometry>
         ...
      < geometry>
  }

It follows a simple format convention,

In the following sample M3D file, all 4 structures are made up of a single box geometry. Structure 1 is anchored, therefore not moveable via translation or rotation command. Structure 2 is start of a linkage that composed of structure 2 and structure 3. By specifying 'link 1 member' as part of structure 3, structure 3 will also move in accordance with structure 2.

Sample M3D file:

#
# structure 1 start -----------------
{
  anchor: true
  1.0 1.0 50.0 0 0.0 25.0
}
# structure 1 end -----------------

# structure 2 start -----------------
{
  anchor: false
  link 1 start
  rotate: +x 0.00 25.00 2.00

  reflect start
  18.0 42.0 2.0 0.0 47.0 4.0
  reflect end

  18.0 42.0 2.0 0.0 47.0 4.0
}
# structure 2 end -----------------

# structure 3 start -----------------
{
  anchor: false
  link 1 member
  link 2 start
  rotate: +x 0.00 70.00 2.00
  
  reflect start
  18.0 28.0 2.0 0.0 85.0 4.0
  reflect end
  
  18.0 28.0 2.0 0.0 85.0 4.0
}
# structure 3 end -----------------

# structure 4 start -----------------
{
  anchor: false
  link 3 start
  rotate: +y 0.00 30.00 2.00
  20.0 10.0 2.0 40.0 00.0 2.0
}
# structure 4 end -----------------

plot corresponding to the above
sample file


modified on September 9, 1999