The class “Result” is described in Chapter I.4. This section describes the methods of the generic “DataBase” class that deal with “Result” objects. The “Result” methods are:
“getResultLoadCaseNames” is a method without argument that returns an Array containing the names of all the load cases for which Results are stored in the DataBase.
“getResultSubCaseNames” is a method without argument that returns an Array containing the names of all the subcases for which Results are stored in the DataBase.
“getResultTypeNames” is a method without argument that returns an Array containing all the Result identifiers for Results stored in the DataBase.
“checkResultExists” is used to check whether a certain Result is present in the DataBase. The method returns a Boolean value and has three String arguments corresponding to the load case name, the subcase name, and the Result name.
“getResultSize” returns the size of a Result object stored in the DataBase. The method returns an integer value and has three String arguments corresponding to the load case name, the subcase name, and the Result name. If the corresponding Result is not found, “-1” is returned.
“getResultLcInfos” returns the integer and real ids associated with a Result object stored in the DataBase. The method has three String arguments corresponding to the load case name, the subcase name, and the Result name. Integer and real ids are returned in an Array of 4 elements. If specified Result is not found in the DataBase, method returns nil.
“addResult” is used to add a Result to the DataBase. The arguments are three String objects corresponding to the key (load case name, subcase name and Result type name), and the Result object. If a Result with the same key is already present in the DataBase, it is deleted and replaced by the new one.
“generateCoordResults” has three String arguments and builds a Result corresponding to Coordinates of elements and nodes. The arguments correspond to the key to which the Result object is associated in the DataBase. (load case name, subcase name, and Result name respectively.) If the String arguments are omitted, it is assumed that “”, “” and “Coordinates” for the Result key.
“generateElemAxesResults” has two or three arguments. The two first arguments are the load case name and subcase name to which the produced Results will be associated. These arguments are mandatory. The method produces several vectorial Results:
“Axis 1” corresponding to the first element axis.
“Axis 2” corresponding to the second element axis.
“Axis 3” corresponding to the third element axis.
“Normals” corresponding to the normals to 2D elements.
“Axis” corresponding to the first element axis of 1D elements.
“Coordinates” corresponding to the coordinate Results generated by “generateCoordResults” method.
By default, components are expressed in element axes, except for the “Coordinates” Result which follow the conventions of “generateCoordResults” method. The third argument allows to modify this default behavior by expressing the components in another coordinate system specified by a String or an integer argument. This argument is optional. The use of this option leads to a very significant increase of the computation time of the method.
Note also that the vectorial values are associated with element centers, and element corners. For the “Coordinates” Result, values are also associated with nodes.
“buildLoadCasesCombili” allows the definition of Result by linear combination of other Results. The selection of the new Result and elementary Results is done by load case names. The first argument is a String containing the new load case name of the Results being created. The second argument contains an Array of real numbers corresponding to the factors of the linear combination. The third argument is an Array of Strings containing the name of load cases to which elementary Results are associated. The lengths of the two Array arguments must match.
“renameResults” is used to modify the key by which Results stored in the DataBase can be accessed. The method has two arguments:
An Array of three String objects corresponding to the identification of the Results that must be renamed. If one of the String is void or replaced by nil, then all the Results matching the non void Strings are renamed. Of course, at least one of the three Strings must be non-void.
An Array of three Strings containing the new key identifiers. Strings must be void or nil at the same time as the Strings of “From” argument.
“copyResults” has the same arguments as “renameResults”, and performs nearly the same operation. The difference is that the Result stored in the DataBase is now duplicated, and not simply renamed.
“removeResults” is used to delete Results from the DataBase. This method has two String arguments corresponding to the method of selection of Results and to an identifier respectively. The “Method” argument has three possible values: “CaseId”, “SubCaseId” or “ResId”. It specifies whether the Results to be deleted are identified by their load case name, their subcase name or their Result type name. The second String argument corresponds to the identifier of Results to be deleted.
“removeAllResults” erases all Results stored in the DataBase. This method has no argument.
“getResultCopy” returns a Result object containing a copy of a portion of a Result stored in the DataBase. This method has generally six arguments (see below for other possibilities):
A String argument corresponding to the load case name.
A String argument corresponding to the subcase name.
A String argument corresponding to the Result type name.
A String argument corresponding to the method of selection. Possible values of this argument are listed and explained in Table I.4.6 of section I.4.3. This “Method” string argument can be replaced by a Result or ResKeyList object. Then it correspond to the target entities on which the values are extracted. (See remark below.)
A Group argument corresponding to the Target (selection of elements or nodes on which the Results are recovered).
An Array corresponding to the list of layers on which results are to be recovered. This Array can be void. If not void, its elements must be String or integer objects.
Some of the arguments given above are optional. For example, the function can be called with 3 or 4 arguments only.
When the fourth argument is a Result or a ResKeyList object, the function must have exactly four arguments. Then, it returns a new Result obtained by extracting the pairs of key and values on the keys of the Result or ResKeyList argument.
Valid calls to the function are illustrated below:
res=db.getResultCopy(lcName,scName,resName,"ElemCenters",
targetGrp,layersList)
res=db.getResultCopy(lcName,scName,resName,"NodesOnly")
res=db.getResultCopy(lcName,scName,resName,layersList)
res=db.getResultCopy(lcName,scName,resName)
res=db.getResultCopy(LcName,ScName,ResName,targetRes)
res=db.getResultCopy(LcName,ScName,ResName,targetRkl)
res=db.getResultCopy(lcName,scName,resName,"ElemCenters",
targetGrp)
In the third example above, the extraction is done on the list of layers only, no selection is done for the elements or nodes. In the fourth example, a copy of the Result stored in the DataBase is returned without selection on a list of elements, nodes, layers or sub-layers..
When the method has four arguments, the fourth one is interpreted as a selection method if it is a String. As no extraction Group argument is provided, the extraction is done on all nodes or elements. Also, when four arguments are provided, a single layer cannot be specified as a String argument. It should be specified as an Array of Strings. For example:
res=db.getResultCopy(lcName,scName,resName,["Z1"])
is valid, but:
res=db.getResultCopy(lcName,scName,resName,"Z1")
is not.
Methods devoted to the importation of Results from binary Results files are specific to the specific solver that produced the Results. These methods are described in Part III.