core/vnl/vnl_complexify.h
Go to the documentation of this file.
00001 // This is core/vnl/vnl_complexify.h
00002 #ifndef vnl_complexify_h_
00003 #define vnl_complexify_h_
00004 //:
00005 //  \file
00006 //  \brief Functions to create complex vectors and matrices from real ones
00007 //  \author fsm
00008 //
00009 // \verbatim
00010 // Modifications
00011 // Peter Vanroose - 2 July 2002 - part of vnl_complex_ops.h moved here
00012 // \endverbatim
00013 
00014 #include <vcl_complex.h>
00015 #include <vnl/vnl_vector.h>
00016 #include <vnl/vnl_matrix.h>
00017 
00018 //: Overwrite complex array C (of length n) with pairs from real arrays R and I.
00019 template <class T> void
00020   vnl_complexify(T const* R, T const* I, vcl_complex<T>* C, unsigned n);
00021 //: Overwrite complex array C (sz n) with complexified version of real array R.
00022 template <class T> void
00023   vnl_complexify(T const* R,             vcl_complex<T>* C, unsigned n);
00024 
00025 //: Return complexified version of real vector R.
00026 // \relatesalso vnl_vector
00027 template <class T> vnl_vector<vcl_complex<T> >
00028   vnl_complexify(vnl_vector<T> const& R);
00029 //: Return complex vector R+j*I from two real vectors R and I.
00030 // \relatesalso vnl_vector
00031 template <class T> vnl_vector<vcl_complex<T> >
00032   vnl_complexify(vnl_vector<T> const& R, vnl_vector<T> const& I);
00033 //: Return complexified version of real matrix R.
00034 // \relatesalso vnl_matrix
00035 template <class T> vnl_matrix<vcl_complex<T> >
00036   vnl_complexify(vnl_matrix<T> const& R);
00037 //: Return complex matrix R+j*I from two real matrices R and I.
00038 // \relatesalso vnl_matrix
00039 template <class T> vnl_matrix<vcl_complex<T> >
00040   vnl_complexify(vnl_matrix<T> const& R, vnl_matrix<T> const& I);
00041 
00042 #endif // vnl_complexify_h_