Difference between revisions of "FEA Mesh Generation Commands"

From OSUPDOCS
Jump to navigation Jump to search
Line 9: Line 9:
In <tt>XML</tt> input files, all [[Mesh Generation Commands]] must be within a single Mesh block:
In <tt>XML</tt> input files, all [[Mesh Generation Commands]] must be within a single Mesh block:


&lt;Mesh&gt;
<pre>
    (mesh generation commands)
&lt;Mesh&gt;
&lt;/Mesh&gt;
  &lt;<a href="#Keypoints"><code>Keypoints</code></a>&gt;
    &lt;pt x='0' y='0' id='lowerleft'/&gt;
    &lt;pt x='0' y='10' id='upperleft'/&gt;
    &lt;pt x='50' y='0' id='lowerright'/&gt;
    &lt;pt x='50' y='10' id='upperright'/&gt;
  &lt;/Keypoints&gt;
 
  &lt;<a href="#Paths"><code>Path</code></a> id="bottom" intervals='6' ratio='1'&gt;
    &lt;keypt id='lowerleft'/&gt;
    &lt;keypt id='lowerright'/&gt;
  &lt;/Path&gt;
  &lt;Path id="right" intervals='3'&gt;
    &lt;keypt id='lowerright'/&gt;
    &lt;keypt id='upperright'/&gt;
  &lt;/Path&gt;
  &lt;Path id="top" intervals='6'&gt;
    &lt;keypt id='upperright'/&gt;
    &lt;keypt id='upperleft'/&gt;
  &lt;/Path&gt;
  &lt;Path id="left" intervals='3'&gt;
    &lt;keypt id='upperleft'/&gt;
    &lt;keypt id='lowerleft'/&gt;
  &lt;/Path&gt;
 
  &lt;<a href="#Areas"><code>Area</code></a> mat="1" thick="10" type="4" flip="0" angle="0"&gt;
    &lt;path id="bottom"/&gt;
    &lt;path id="right"/&gt;
    &lt;path id="top"/&gt;
    &lt;path id="left"/&gt;
  &lt;/Area&gt;
&lt;/Mesh&gt;
 
&lt;!-- image and shape methods to set element properties --&gt;
 
&lt;BMP name="MatImage.bmp" width="50" angles="MatAngles.bmp"&gt;
  &lt;Origin x="0" y="0"/&gt;
  &lt;Intensity mat="2" imin="76" imax="255"&gt;
    &lt;Thickness units="mm"&gt;1&lt;/Thickness&gt;
  &lt;/Intensity&gt;
  &lt;Intensity mat="3" imin="1" imax="75"&gt;
    &lt;Thickness units="mm"&gt;1&lt;/Thickness&gt;
  &lt;/Intensity&gt;
  &lt;Intensity imin="0" imax="255" minAngle="0.000000" maxAngle="90.000000"/&gt;
&lt;/BMP&gt;
 
&lt;Body mat='1' angle='0' thick='1'&gt;
  &lt;Oval units='mm' xmin='10' xmax='40' ymin='10' ymax='40'/&gt;
  &lt;Rect units='mm' xmin='10' xmax='40' ymin='10' ymax='40'/&gt;   
&lt;/Body&gt;
 
&lt;Hole&gt;
  &lt;Rect xmin='20' xmax='30' ymin='20' ymax='30'/&gt;   
&lt;/Hole&gt;
</pre>
 
==== Keypoints ====
 
The <tt>&lt;Keypoints&gt;</tt> section must come first. It can define any number of key points. Each subordinate <tt>&lt;pt&gt;</tt> command defines a key point, provides its <tt>x</tt> and <tt>y</tt> coordinates and gives it an <tt>id</tt>. The <tt>id</tt>'s can be text or numbers and must all be unique among key points.
<


== Mesh Generation Commands ==
== Mesh Generation Commands ==

Revision as of 15:58, 28 August 2013

The best way to generate an FEA mesh is to use Keypoint, Path, and Area commands, with an optional BMP, Region, and Hole commands to assign material properties from a digitized image of the object and from shape commands.

Scripted Input Files

In scripted input files, you build the mesh by using multiple Mesh Generation Commands. These commands are usually grouped together, but may be at various locations in the input file.

XML Input Files

In XML input files, all Mesh Generation Commands must be within a single Mesh block:

<Mesh>
  <<a href="#Keypoints"><code>Keypoints</code></a>>
    <pt x='0' y='0' id='lowerleft'/>
    <pt x='0' y='10' id='upperleft'/>
    <pt x='50' y='0' id='lowerright'/>
    <pt x='50' y='10' id='upperright'/>
  </Keypoints>

  <<a href="#Paths"><code>Path</code></a> id="bottom" intervals='6' ratio='1'>
    <keypt id='lowerleft'/>
    <keypt id='lowerright'/>
  </Path>
  <Path id="right" intervals='3'>
    <keypt id='lowerright'/>
    <keypt id='upperright'/>
  </Path>
  <Path id="top" intervals='6'>
    <keypt id='upperright'/>
    <keypt id='upperleft'/>
  </Path>
  <Path id="left" intervals='3'>
    <keypt id='upperleft'/>
    <keypt id='lowerleft'/>
  </Path>

  <<a href="#Areas"><code>Area</code></a> mat="1" thick="10" type="4" flip="0" angle="0">
    <path id="bottom"/>
    <path id="right"/>
    <path id="top"/>
    <path id="left"/>
  </Area>
</Mesh>

<!-- image and shape methods to set element properties -->

<BMP name="MatImage.bmp" width="50" angles="MatAngles.bmp">
  <Origin x="0" y="0"/>
  <Intensity mat="2" imin="76" imax="255">
    <Thickness units="mm">1</Thickness>
  </Intensity>
  <Intensity mat="3" imin="1" imax="75">
    <Thickness units="mm">1</Thickness>
  </Intensity>
  <Intensity imin="0" imax="255" minAngle="0.000000" maxAngle="90.000000"/>
</BMP>

<Body mat='1' angle='0' thick='1'>
   <Oval units='mm' xmin='10' xmax='40' ymin='10' ymax='40'/>
   <Rect units='mm' xmin='10' xmax='40' ymin='10' ymax='40'/>     
</Body>

<Hole>
   <Rect xmin='20' xmax='30' ymin='20' ymax='30'/>     
</Hole>

Keypoints

The <Keypoints> section must come first. It can define any number of key points. Each subordinate <pt> command defines a key point, provides its x and y coordinates and gives it an id. The id's can be text or numbers and must all be unique among key points. <

Mesh Generation Commands