Box Trim Macro

Use the Box Trim utility to trim the model, or selected subset, along the global axis to fit the selected 3D box.

For example, a full car model can be trimmed along the Y=0 axis to obtain the left or right side of the car. A fixed boundary condition is applied at the trimmed edges. It also removes the FE entities outside of the box, and cleans the model so that it is a runnable deck. The axis directions and terminology are based on modeling standards in the automotive industry.

This option is available in the LS-DYNA, Nastran, Abaqus, OptiStruct and Radioss user profiles.

Different scenarios for using the Box Trim utility include:
  • This tool is useful in applications where some types of analyses can be performed on one-half (or quarter) of the model using symmetry boundary conditions.
  • Trimming a full car model into a quarter or half model for further analysis.
  • Trimming a model to significantly gain computational time.
  • Trimming a model to debug an analysis error in a particular location in order to understand the cause of the error.
The Box Trim utility is very useful when you are doing a system level analysis, and when portions of a full vehicle model include few complete subsystems or partial subsystems.
Note: This macro can only be used for 1st order elements.

Trim Boxes

  1. From the Utility Browser, Geom/Mesh menu, click Box Trim.
    A warning message appears if you in the LS-DYNA or Nastran user profiles. If you are not in either of these profiles, then the Box Trim dialog appears.
  2. Click Yes.
    You are directed to the panel area.
  3. Using the elems selector, select the elements that you want to trim.
  4. When you are finished, click proceed.
    The Box Trim dialog opens.
  5. Edit the options in the dialog.
    Table 1.
    Option Description
    Box trim type Determine how the selected model will be trimmed by selecting one of the following options from the pull-down menu:
    left
    Split the model along global Y=ymiddle and save the model between Y=ymin and Y= ymiddle (ymiddle =(ymin+ymax)/2).


    Figure 1.
    right
    Split the model along global Y=ymiddle and save the model between Y= ymiddle and Y=ymax.


    Figure 2.
    front
    Split the model along global X=value (selected value) and save the model between X=xmin and X=value.


    Figure 3.
    rear
    Split the model along global X=value (selected value) and save the model between X=value and X=xmax.


    Figure 4.
    frontleft
    Split the model along global Y=ymiddle and X=value (selected value) and save the model between Y=ymin and Y=ymiddle, and X=xmin and X=value.


    Figure 5.
    frontright
    Split the model along global Y=0.0 and X=value (selected value) and save the model between Y=0.0 and Y=ymax, and X=xmin and X=value.


    Figure 6.
    rearleft
    Split the model along global Y=0.0 and X=value (selected value), and save the model between Y=ymin and Y=0.0, and X=value and X=xmax.


    Figure 7.
    rearright
    Split the model along global Y=0.0 and X=value (selected value) and save the model between Y=0.0 and Y=ymax, and X=value and X=xmax.


    Figure 8.
    custom
    Define the box by either selecting two corner nodes (Corners) or selecting the center node and dimensions (Distance from center).
    X limit Define the trim location by selecting one of the following options:
    By node
    Directs you to the Node Selection panel where you can select the node for the box trim location.
    By value
    Enter the value for the box trim location.
    Defined by Define the trim location by selecting one of the following options:
    Pick Corner Node
    Directs you to the Node Selection panel where you can select the two corner nodes that define the outer X, Y and Z bounds of the box.
    By Center Node
    Directs you to the Node Selection panel where you can select the center node, and then enter Delta X, Delta Y and Delta Z values which is the distance from the center node to the outer bounds of the box in global X, Y and Z directions.
    Note: This option is only available when you select custom as the Box trim type.
    Create constraints Create Single Point Constraints (SPCs) for all of the nodes along the trimmed edges. When this option is activated, the following options are enabled:
    SPC collector
    Specify a load collector to store the Single point constraint (SPC) created along the trimmed edge.
    For OptiStruct, Nastran, and Abaqus, all of the nodes along the trimming plane will be created as a node set.
    Box collector
    Specify a box collector. A large hexa element that represents the box will be created for visualization in the specified collector.
    Only available in the Radioss user profile.
    Remesh options Enables access to additional options that help clean the trimmed edge elements in order to achieve a better mesh quality.
    Min size Defines the minimum size of remeshed elements on the trimmed edge. Element size can be defined by selecting one of the following options from the pull-down menu and entering a corresponding value in the elem size field.
    relative
    Multiplier of the local element size
    absolute
    Actual element size


    Figure 9. . Min size > 3 (absolute)


    Figure 10. . Min size > 5 (absolute)
    Delete comps with Enables a filter to delete components after the trim. The components that are deleted after the trim can be defined by selecting one of the following options from the pull-down menu and entering a corresponding value.
    num elems
    If the number of elements remaining after the box trim are lesser than specified value, then entire component will be deleted.
    % area
    Specify the percentage of the total area remaining after the trim. If the area after the trim is lesser than the specified value, then the component will be deleted.
    Feature angle= This option is similar to the global feature angle specified in the mesh option. This value is used in element cleanup after the trim.
  6. Click Trim.
    Tip: Click Preview to view the trim before confirming your selections.

How Entities on a Cutting Plane are Treated

The entities on a cutting plane must be treated as follows:
0D Elements
Delete 0D elements that are defined on the nodes that were deleted.
There are some special cases where the entity set and part are referred in it as a pointer. In these cases alone retain them.
1D Elements
Beams, Bars, Springs
Remove the element.
FE Joints
Remove the element.
RBE3
If the dependent node is deleted, remove the element.
If any independent nodes lie on the plane of the box trim, remove the element.
Rigids
If the independent node is deleted, remove the rigids.
If any dependent nodes lie on the trimming line edge, remove the rigids.
In all other cases, retain the rigid.
2D Elements
Trim the element on the cutting plane.
3D Elements
Remove the element on the cutting plane.
Connectors
Remove the connector and it's corresponding FE realized.
Equations
This is mapped to loads in HyperMesh. Delete the equations if one of the nodes are deleted as part of Box trim.

How the Box Trim Macro Executes a Model Cleanup

The model cleanup includes:

  1. Empty deletion
    • Deletes empty components (components with no elements), assemblies, sets, contact surfaces, output blocks, groups, plies, plots, and load steps. The following entities will also be deleted if there is no card image: load collectors, system collectors, vector collectors, and section collectors.
    • Deletes unused materials, properties, sets, beam sections, curves, systems, vectors, laminates, plies, tables, tags, and optimization entities.
  2. Location based deletion
    • Deletes connectors with a FE realization that is located outside of the box and at the box boundary.
    • Deletes all of the morphing entities and blocks that are completely outside of the defined box.
  3. Solver specific
    • *CONTACT – mapped Group
      • Checks if the main or secondary surface is selected in the definition. If either of them are empty, the *CONTACT will be deleted.
    • *CONSTRAINED_EXTRA_NODE - Mapped to ConstrainedExtraNode
      • Checks if the nodes or node sets are defined as the secondary entity. If there are not any nodes or node sets associated, the entity will be deleted.
      • Checks the card image to see if the PSID assigned is blank. If it is blank, the keyword itself will be removed.
    • *CONSTRAINED_RIGD_BODIES, *CONSTRAINED_TIE-BREAK, *CONSTRAINED_LAGRANGE_IN_SOLID, *CONSTRAINED_EULER_IN_EULER, and *ALE_options – Mapped to Group
      • Checks if the secondary or main definition is defined in the Group. If either the secondary or the main definition are empty, then the entity will be deleted.
    • *AIRBAG_options – Mapped to control volume
      • Checks if the entity has a secondary definition. If the definition is empty, then the entity will be deleted.
        Note: This rule does not apply to *AIRBAG_PARTICLE, *AIRBAG_INTERACTION and *AIRBAG_ADVANCED_ALE.
    • *AIRBAG_PARTICLE
      • Checks if the card image is referenced by part set ID or part ID, corresponding to the variables SID1 or SID2. If the card image has no reference, then the entity will be deleted.
    • *AIRBAG_INTERACTION
      • Checks if the variable in the card images AB1 and AB2 are assigned a value. If they are not assigned a value, then the entity will be deleted.
    • *DEFINE_ALEBAG_BAG and *DEFINE_ALEBAG_HOLE
      • Checks these keywords to see if SID_PART or SID_SET are empty. If either of them are empty, then the keyword will be deleted.
    • *AIRBAG_ADVANCED_ALE
      • Checks if all of the variables in Bag_ID 1…. and Bag_ID 8 are empty. If they are empty, then the entity will be deleted.
  4. LS-DYNA specific cleanup
    • Moves all of the leftover control cards to the box trim include, as they are valid definitions.
    • If the following keywords are defined in the model, entire model, and do not require an explicit definition of entities, then they will need to be gathered and moved to the box_trim_include.
      • *CONTACT (If the main or secondary type is assigned a value of 5, corresponding to all.)
      • *LOAD_BLAST
      • *LOAD_BODY
      • *LOAD_BRODE
      • *INITIAL_VELOCITY_options expect Initial_Velocity_Rigidbody. In cases of Initial_Velocity_rigidbody, if the PSID is 0, then it will be ignored. This implies that it is not applicable on any entity, therefore it should not be included back.
      • *RIGIDWALL_ - If the variable NSID is assigned a value of 0, this indicates all of the nodes in the model.
    • Deletes any remaining entities, except for the entities in the box_trim_include.
    • Moves the entities from the box_trim_include to the main file.
  5. Abaqus, Nastran, and OptiStruct specific enhancements and cleanup
    • Creates a node set from the nodes on the trimming plane while trimming.
    • Updates the following contact and contact surface entities:
      • Abaqus: *SURFACE ELEMENT, *SURFACE NODE, *CONTACT PAIR, and *TIE
      • Nastran: BSURF, BCBODY, and BCTABLE
      • OptiStruct: SURF, CONTACT, and TIE
    • Limitation: Abaqus, Nastran, and OptiStruct support direct property assignment, therefore when trimming such models you will be required to assign a property to the elements remeshed at the trimming plane.