Rotate and Analyze

The attached FRED file has an embedded script called “rotateAndAnalyze” that demonstrates how to rotate a source over a range of angles and perform an analysis at each step in the rotation.  In this configuration, the asymmetric source is rotated about the z-axis as it is focused onto the detector.  The number of steps in the rotation is specified by the user on line 18 and the maximum rotation angle is specified on line 19.  Notice that the Analysis Results Nodes are used to store the results of each analysis on the object tree in the Analysis Results folder.

The user should be aware that these analysis results nodes are stored in memory and can pile up if the script is repeatedly run (potential memory management issue).  Two commands exist for removing ARN’s from the object tree, ARNDelete and ARNDeleteAllNodes.  Alternatively, the ARNs could be written to disk as an FGD file using the command ARNWriteToFile.  These FGD files can then be brought back into any FRED document by right mouse clicking on the Analysis Results folder and selecting the option “Create New ARN from File”.

Download the FRED file: sourceRotateAndAnalyze.frd