Blaze  3.6
Imag.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_FUNCTORS_IMAG_H_
36 #define _BLAZE_MATH_FUNCTORS_IMAG_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
59 #include <blaze/system/Inline.h>
60 
61 
62 namespace blaze {
63 
64 //=================================================================================================
65 //
66 // CLASS DEFINITION
67 //
68 //=================================================================================================
69 
70 //*************************************************************************************************
74 struct Imag
75 {
76  //**********************************************************************************************
82  template< typename T >
83  BLAZE_ALWAYS_INLINE BLAZE_DEVICE_CALLABLE decltype(auto) operator()( const T& a ) const
84  {
85  return imag( a );
86  }
87  //**********************************************************************************************
88 };
89 //*************************************************************************************************
90 
91 
92 
93 
94 //=================================================================================================
95 //
96 // YIELDSUNIFORM SPECIALIZATIONS
97 //
98 //=================================================================================================
99 
100 //*************************************************************************************************
102 template< typename T >
103 struct YieldsUniform<Imag,T>
104  : public IsUniform<T>
105 {};
107 //*************************************************************************************************
108 
109 
110 
111 
112 //=================================================================================================
113 //
114 // YIELDSSYMMETRIC SPECIALIZATIONS
115 //
116 //=================================================================================================
117 
118 //*************************************************************************************************
120 template< typename MT >
121 struct YieldsSymmetric<Imag,MT>
122  : public IsSymmetric<MT>
123 {};
125 //*************************************************************************************************
126 
127 
128 
129 
130 //=================================================================================================
131 //
132 // YIELDSLOWER SPECIALIZATIONS
133 //
134 //=================================================================================================
135 
136 //*************************************************************************************************
138 template< typename MT >
139 struct YieldsLower<Imag,MT>
140  : public IsLower<MT>
141 {};
143 //*************************************************************************************************
144 
145 
146 
147 
148 //=================================================================================================
149 //
150 // YIELDSSTRICTLYLOWER SPECIALIZATIONS
151 //
152 //=================================================================================================
153 
154 //*************************************************************************************************
156 template< typename MT >
157 struct YieldsStrictlyLower<Imag,MT>
158  : public IsStrictlyLower<MT>
159 {};
161 //*************************************************************************************************
162 
163 
164 
165 
166 //=================================================================================================
167 //
168 // YIELDSUPPER SPECIALIZATIONS
169 //
170 //=================================================================================================
171 
172 //*************************************************************************************************
174 template< typename MT >
175 struct YieldsUpper<Imag,MT>
176  : public IsUpper<MT>
177 {};
179 //*************************************************************************************************
180 
181 
182 
183 
184 //=================================================================================================
185 //
186 // YIELDSSTRICTLYUPPER SPECIALIZATIONS
187 //
188 //=================================================================================================
189 
190 //*************************************************************************************************
192 template< typename MT >
193 struct YieldsStrictlyUpper<Imag,MT>
194  : public IsStrictlyUpper<MT>
195 {};
197 //*************************************************************************************************
198 
199 
200 
201 
202 //=================================================================================================
203 //
204 // YIELDSZERO SPECIALIZATIONS
205 //
206 //=================================================================================================
207 
208 //*************************************************************************************************
210 template< typename T >
211 struct YieldsZero<Imag,T>
212  : public IsZero<T>
213 {};
215 //*************************************************************************************************
216 
217 } // namespace blaze
218 
219 #endif
Header file for the imaginary shim.
Header file for the YieldsStrictlyLower type trait.
Header file for the YieldsZero type trait.
Header file for the IsUniform type trait.
Header file for the IsStrictlyUpper type trait.
Header file for the IsSymmetric type trait.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:58
#define BLAZE_ALWAYS_INLINE
Platform dependent setup of an enforced inline keyword.
Definition: Inline.h:85
Generic wrapper for the imag() function.
Definition: Imag.h:74
Header file for the YieldsStrictlyUpper type trait.
Header file for the IsLower type trait.
Header file for the IsStrictlyLower type trait.
Header file for the YieldsUniform type trait.
Header file for the YieldsSymmetric type trait.
Header file for the YieldsUpper type trait.
Header file for the IsZero type trait.
Header file for the YieldsLower type trait.
Macro for CUDA compatibility.
#define BLAZE_DEVICE_CALLABLE
Conditional macro that sets host and device attributes when compiled with CUDA.
Definition: HostDevice.h:94
decltype(auto) imag(const DenseMatrix< MT, SO > &dm)
Returns a matrix containing the imaginary part of each single element of dm.
Definition: DMatMapExpr.h:1417
Header file for the IsUpper type trait.
System settings for the inline keywords.