evalhf/hfarray - Maple Programming Help

Online Help

All Products    Maple    MapleSim

Home : Support : Online Help : Programming : Resource Management : evalhf : evalhf/hfarray


handling of hfarrays



evalhf handles only two special structures: arrays and rtables. This help page describes rtables with their datatype option set to  float[8] and complex[8]. The array structure and rtable structure (which is a supertype of Array, Matrix, Vector, and hfarray) are also described in evalhf/array.


When an hfarray is passed to evalhf or to a function being evaluated by evalhf, it is passed by reference. Any changes made to the hfarray during the computation will persist when the computation completes and evalhf returns. Unlike arrays, hfarrays and other rtables with datatype=float[8] or datatype=complex[8] do not need to be qualified with var when call-by-reference is desired.


An evalhf computation can also return an hfarray as a result. Such an hfarray would have been created by a call to the array or hfarray function within evalhf, or could have been passed in.


When an hfarray is passed into, out of, or returned from evalhf, no conversion to or from Maple floats is performed. This means that hfarrays can be used to efficiently store hardware floating-point data between invocations of evalhf.


The functions array(...) and hfarray(...) are valid inside evalhf calls but accept dimension information only. The result of a call to array is an hfarray of the given dimensions initialized to all zeros. The result of a call to hfarray is an hfarray of the given dimensions initialized to all undefined (IEEE Not-a-Number). No indexing or initializing information can be given.


There is no mechanism within evalhf to find the dimension of an hfarray from the object itself. If this information is needed, it must be passed in.


Unlike ordinary arrays, globally defined hfarrays can be accessed from within evalhf.


Indexing operations on hfarrays within evalhf must be fully qualified; the number of indices specified must correspond to the dimension of the array.

See Also