Automated Scripting Procedure

The script to automate the model assembly process can be found here.

The simulation specific output scripts are Febio, SOFA, and Abaqus.

Running the Script
  1. First create the Connectivity File xml document. (see below)
  2. Them from the terminal type salome StlToMed.py args:ConnectivityFile.

  3. When that script finishes, use the simulation specific script from the terminal to produce the desired output file with salome MedToXXX.py args:ConnectivityFile.

Creating the Connectivity File

To create the connectivity file the user should already have all of the stls that will be used as the starting geometry. Each part is added to the assembly as an XML element. Within this part element several child element are needed: file, material, Tie, and Contact.

The Tie and Contact elements should have the elements that they are paired with as subelements.

The Tie and Contact constraints which will be used to create the defined groups are defined by geometric principles relating the two tissues. The currently defined principles are:

These should allow you to create any surface that is necessary, but may take some adjustment. Here is an example xml.

<Assembly>
    <Bone>
        <file>Multis/Bone.stl</file>
        <material>rigid</material>
        <Contact>
        </Contact>
        <Tie>
            <Muscle type="proximity" multiplier="1.5"/>/>
        </Tie>
    </Bone>
    <Muscle>
        <file>Multis/Muscle.stl</file>
        <material>elastic</material>
        <Tie>
            <Fat type="contains" contains="outer" multiplier="1"/>
            <Bone multiplier="0.75"/>
        </Tie>
    </Muscle>
    <Fat>
        <file>Multis/Fat.stl</file>
        <material>elastic</material>
        <Tie>
            <Muscle type="contains" contains="inner"/>
            <Skin type="contains" contains="outer"  multiplier="1"/>
        </Tie>
    </Fat>
    <Skin>
        <file>Multis/Skin.stl</file>
        <material>elastic</material>
        <Contact>
            <Probe type="normals" multiplier="15"/>
        </Contact>
        <Tie>
            <Fat  type="contains" contains="inner"/>
        </Tie>
    </Skin>
    <Probe>
        <file>Multis/Probe.stl</file>
        <material>rigid</material>
        <Contact>
            <Skin  type="normals" multiplier="15"/>
        </Contact>
    </Probe>
</Assembly>

Specifications/MeshGeneration/ScriptingProcedure (last edited 2018-03-08 21:10:30 by landisb)