FunctionFind the largest real and imaginary parts occurring in a vector.
Syntax C/C++#include <VFmath.h>
fComplex VCF_maxReIm( cfVector X, ui size );
C++ VecObj#include <OptiVec.h>
complex<T> vector<complex<T>>::maxReIm();
Pascal/Delphiuses VCFstd;
procedure VCF_maxReIm( var Max:fComplex; X:cfVector; size:UIntSize );
DescriptionThe vector X is separately searched for its largest real and imaginary parts. These are packed together and either returned as an fComplex (in C/C++) or stored in Max (in Pascal/Delphi):
Max.Re: largest real part encountered,
Max.Im: largest imaginary part encountered.
Error handlingnone
Return valueC/C++:
struct or class instance of type fComplex (dComplex, eComplex, resp.), in which the maxima of the real and imaginary parts of X are packed together.
since Pascal does not allow complex return values, the result is stored in the variable Max.
See alsoVCF_minReIm,   VCF_absmaxReIm,   VCF_absmax,   VCF_absmaxind

VectorLib Table of Contents  OptiVec home