Data Retrieval Utility Routines

Toolpath-mesh intersection utility routines are used to activate the toolpath-mesh intersection module and to access data computed by the module. The data retrieval utility routines are invoked at the beginning of an increment after the call to a compute routine from user subroutines UEPACTIVATIONSETUP and UMDFLUXSETUP and from within the element loop from user subroutines UEPACTIVATIONVOL, UEPACTIVATIONFACET, and UMDFLUX.

This page discusses:

PtkGetScanPatternData

Retrieve scan pattern properties.

Utility routine interface

#include <PtkUtilitySubs.hdr>
#include <aba_ptk_enums.inc>

       character *80 cEigLibID, cPtkID
       dimension patternData(iPtkRealScanPatternData_Size)

       call ptkGetScanPatternData (cPtkID, rPatternData)

Variables to be provided to the utility routine

cPtkID

Name of the scan strategy defined in PtkSetMeshAndScanstrategies.

rPatternData

Real array of size iPtkRealScanPatternData_Size.

patternData(iPtkRealScanPatternData_sliceTime) Time to complete activation of element in a slice.

PtkGetNumIntersectedElements

Retrieve the number of elements that are intersected by a toolpath or a scan pattern.

Utility routine interface

#include <PtkUtilitySubs.hdr>
#include <aba_ptk_enums.inc>

       character *80 cPtkID
       pointer(ptr_elemListHandler, elemListHandler)
       ptr_elemListHandler =
     *           PtkGetNumIntersectedElements(cPtkID,nIntersectedElems)

Variables to be provided to the utility routine

cPtkID

Tag name of an event series defined in PtkSetEventSeriesProperties or name of a scan strategy defined in PtkSetMeshAndScanstrategies.

Variables returned from the utility routine

ptr_elemListHandler
A pointer to the list of element labels.
nIntersectedElems
Number of intersected elements.

PtkGetIntersectedElements

Retrieve list of labels of elements that are intersected by a toolpath.

Utility routine interface

#include <PtkUtilitySubs.hdr>
#include <aba_ptk_enums.inc>

       character*80 cEventSeries
       PtkGetIntersectedElements (elemListHandler, jIntersectedElems)

Variables to be provided to the utility routine

elemListHandler

A pointer to the list of element labels retrieved by a previous call to PtkGetNumIntersectedElements.

Variables returned from the utility routine

jIntersectedElems
List of element labels that are intersected by the toolpath. Integer array of size nIntersectedElems.

PtkGetDataAccess

Retrieve number of records of geometric intersections for a given element.

Utility routine interface

#include <PtkUtilitySubs.hdr>
#include <aba_ptk_enums.inc>

       pointer(ptr_iEventRecordHandler,iEventRecordHandler)
       character*80 cPtkID
       ptr_iEventRecordHandler=PtkGetDataAccess(cPtkID,
     *                                   noel, nRecords, nRecordLength,
     *                                   nFieldLength, jPtkShape, jPtkAlgo)

Variables to be provided to the utility routine

cPtkID

Tag name of an event series defined in PtkSetEventSeriesProperties or name of a scan strategy defined in PtkSetMeshAndScanstrategies.

Noel

Element label.

Variables returned from the utility routine

ptr_iEventRecordHandler
Pointer to the record of geometric intersections.
nRecords
Number of geometric intersections within the element.
nRecordLength
Length of the geometric intersection records.
nFieldLength
Length of the field records.
jPtkShape
Shape of the toolpath (iPtkEventSeriesShape_Point, iPtkEventSeriesShape_InfiniteLine, iPtkEventSeriesShape_Box, or iPtkEventSeriesShape_ScanPattern).
jPtkAlgo
Algorithm used in geometric intersection of the mesh with the toolpath (iPtkEventSeriesAlgorithm_SubElement, iPtkEventSeriesAlgorithm_SubSegment, or iPtkEventSeriesAlgorithm_Undefined).

PtkGetData

Retrieve records of geometric intersections for a given element.

Utility routine interface

#include <PtkUtilitySubs.hdr>
#include <aba_ptk_enums.inc>

       call PtkGetData(iEventRecordHandler, Record, Field)

Variables to be provided to the utility routine

iEventRecordHandler

Pointer to the record of geometric intersections retrieved by calling PtkGetDataAccess.

Variables returned from the utility routine

Record
Real array of size nRecordLength. See Table 1 for a description of the record contents.
Field
Real array of size nFieldLength. Field from the event series definition associated with intersecting segments, subsegments, or subelements. For subsegments, the associated field is found by multiplying the field of the main segment by the weight assigned with the subsegment.

Description of Intersection Records

Quantities computed by the toolpath-mesh intersection method are stored in records. A record represents quantities from one intersection. For point and infinite line toolpaths, one intersection represents the intersection between one segment and a given element. For a box toolpath, one record represents the intersection between one subsegment and an element or one subelement that is inside the path..

The array Record returned by the routine PtkGetData contains records of intersections for a given element. Quantities stored in the array Record are listed in the tables below. To obtain quantities for the ith intersection, the index of the Record array must be offset by (i-1) x record size. Record sizes for different toolpaths are also listed in the tables below. All parameters are defined in the header file aba_ptk_enums.inc.

Table 1. Intersection record for point toolpath. Size of one record is nPtkPointEventRecord_Size.
Record array Quantities
Record(iPtkPointEventRecord_CoordStart1) x-coordinate of the start point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_CoordStart2) y-coordinate of the start point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_CoordStart3) z-coordinate of the start point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_CoordEnd1) x-coordinate of the end point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_CoordEnd2) y-coordinate of the end point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_CoordEnd3) z-coordinate of the end point of intersection with respect to the element reference coordinate.
Record(iPtkPointEventRecord_timeStart) Start times of intersection.
Record(iPtkPointEventRecord_timeEnd) End times of intersection.
Table 2. Intersection record for infinite line toolpath. Size of one record is nPtkInfiniteLineEventRecord_Size.
Record array Quantities
Record(iPtkInfiniteLineEventRecord_VolFraction) Volume fraction vf.
Record(iPtkInfiniteLineEventRecord_ExposedArea) Area A of intersection.
Record(iPtkInfiniteLineEventRecord_EACenter1) x-coordinate of the center Xa of the intersection.
Record(iPtkInfiniteLineEventRecord_EACenter2) y-coordinate of the center Xa of the intersection.
Record(iPtkInfiniteLineEventRecord_EACenter3) z-coordinate of the center Xa of the intersection.
Record(iPtkInfiniteLineEventRecord_ExposedATime) Time at which toolpath passes through the center of the intersection.
Record(iPtkInfiniteLineEventRecord_AreaFracF1 : iPtkInfiniteLineEventRecord_AreaFracF6) Ratio of part of area of an element facet (for facets 1 to 6) below z-plane to the total area of the facet.
Record(iPtkInfiniteLineEventRecord_AreaFracAddedF1 : iPtkInfiniteLineEventRecord_AreaFracAddedF6) Side facet (for facets 1 to 6) area between two z-planes.

Record(iPtkInfiniteLineEventRecord_F1CenterAdded1)

Record(iPtkInfiniteLineEventRecord_F1CenterAdded2)

Record(iPtkInfiniteLineEventRecord_F1CenterAdded3)

Record(iPtkInfiniteLineEventRecord_F6CenterAdded3)

Center of the facet area between two z-planes with respect to the element reference coordinate system.

Record(iPtkInfiniteLineEventRecord_AreaFracDt1)

Record(iPtkInfiniteLineEventRecord_AreaFracDt6)

Time duration between the toolpath crossing the center of the facet fraction to the end of the increment.
Table 3. Intersection record for box toolpath using the subsegment approach. Size of one record is nPtkBoxSubSegmentEventRecord_Size.
Record array Quantities

Record(iPtkBoxSubSegmentEventRecord_CoordStart1)

Record(iPtkBoxSubSegmentEventRecord_CoordStart2)

Record(iPtkBoxSubSegmentEventRecord_CoordStart3)

Record(iPtkBoxSubSegmentEventRecord_CoordEnd1)

Record(iPtkBoxSubSegmentEventRecord_CoordEnd2)

Record(iPtkBoxSubSegmentEventRecord_CoordEnd3)

Start and end coordinates of intersection with respect to the element reference coordinate system.

Record(iPtkBoxSubSegmentEventRecord_timeStart)

Record(iPtkBoxSubSegmentEventRecord_timeEnd)

Start and end times of intersection.
Table 4. Intersection record for box toolpath using the subelement approach. Size of one record is nPtkBoxSubElemEventRecord_Size.
Record array Quantities
Record(iPtkBoxSubElemEventRecord_subVol) Volume of a subelement.
Record(iPtkBoxSubElemEventRecord_elemVol) Volume of the parent element.
Record(iPtkBoxSubElemEventRecord_subCsiCenter1) x-coordinate of the subelement in element reference coordinate system.
Record(iPtkBoxSubElemEventRecord_subCsiCenter2) y-coordinate of the subelement in element reference coordinate system.
Record(iPtkBoxSubElemEventRecord_subCsiCenter3) z-coordinate of the subelement in element reference coordinate system.
Record(iPtkBoxSubElemEventRecord_timeStart) Times when the front of the box passes through the center of the subelement.
Record(iPtkBoxSubElemEventRecord_timeEnd) Times when the rear of the box passes through the center of the subelement.
Table 5. Intersection record for scan pattern. Size of one record is nPtkScanPatternRecord_Size.
Record array Quantities
Record(iPtkScanPatternRecord_VolFraction) Volume fraction vf.
Record(iPtkScanPatternRecord_RegionID) ID of scanning region containing the center of the slice. Integer IDs are assigned to scanning regions internally starting from the 1st region.
Record(iPtkScanPatternRecord_IslandID) ID of patch containing the center of the slice. Integer IDs are assigned to patches internally starting from the 1st patch.
Record(iPtkScanPatternRecord_Orient11 : iPtkScanPatternRecord_Orient33) Three orthonormal vectors (nine real values) defining the local orientation of the strain patch that contains the center of the slice.
Record(iPtkScanPatternRecord_Eig11 : iPtkScanPatternRecord_Eig23) Six components of eigenstrain (11-22-33-12-13-23) with respect to the local orientation.