Blaze  3.6
Real.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_FUNCTORS_REAL_H_
36 #define _BLAZE_MATH_FUNCTORS_REAL_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
43 #include <blaze/math/shims/Real.h>
64 #include <blaze/system/Inline.h>
66 
67 
68 namespace blaze {
69 
70 //=================================================================================================
71 //
72 // CLASS DEFINITION
73 //
74 //=================================================================================================
75 
76 //*************************************************************************************************
80 struct Real
81 {
82  //**********************************************************************************************
88  template< typename T >
89  BLAZE_ALWAYS_INLINE BLAZE_DEVICE_CALLABLE decltype(auto) operator()( const T& a ) const
90  {
91  return real( a );
92  }
93  //**********************************************************************************************
94 };
95 //*************************************************************************************************
96 
97 
98 
99 
100 //=================================================================================================
101 //
102 // YIELDSUNIFORM SPECIALIZATIONS
103 //
104 //=================================================================================================
105 
106 //*************************************************************************************************
108 template< typename T >
109 struct YieldsUniform<Real,T>
110  : public IsUniform<T>
111 {};
113 //*************************************************************************************************
114 
115 
116 
117 
118 //=================================================================================================
119 //
120 // YIELDSSYMMETRIC SPECIALIZATIONS
121 //
122 //=================================================================================================
123 
124 //*************************************************************************************************
126 template< typename MT >
127 struct YieldsSymmetric<Real,MT>
128  : public BoolConstant< IsSymmetric_v<MT> || IsHermitian_v<MT> >
129 {};
131 //*************************************************************************************************
132 
133 
134 
135 
136 //=================================================================================================
137 //
138 // YIELDSLOWER SPECIALIZATIONS
139 //
140 //=================================================================================================
141 
142 //*************************************************************************************************
144 template< typename MT >
145 struct YieldsLower<Real,MT>
146  : public IsLower<MT>
147 {};
149 //*************************************************************************************************
150 
151 
152 
153 
154 //=================================================================================================
155 //
156 // YIELDSUNILOWER SPECIALIZATIONS
157 //
158 //=================================================================================================
159 
160 //*************************************************************************************************
162 template< typename MT >
163 struct YieldsUniLower<Real,MT>
164  : public IsUniLower<MT>
165 {};
167 //*************************************************************************************************
168 
169 
170 
171 
172 //=================================================================================================
173 //
174 // YIELDSSTRICTLYLOWER SPECIALIZATIONS
175 //
176 //=================================================================================================
177 
178 //*************************************************************************************************
180 template< typename MT >
181 struct YieldsStrictlyLower<Real,MT>
182  : public IsStrictlyLower<MT>
183 {};
185 //*************************************************************************************************
186 
187 
188 
189 
190 //=================================================================================================
191 //
192 // YIELDSUPPER SPECIALIZATIONS
193 //
194 //=================================================================================================
195 
196 //*************************************************************************************************
198 template< typename MT >
199 struct YieldsUpper<Real,MT>
200  : public IsUpper<MT>
201 {};
203 //*************************************************************************************************
204 
205 
206 
207 
208 //=================================================================================================
209 //
210 // YIELDSUNIUPPER SPECIALIZATIONS
211 //
212 //=================================================================================================
213 
214 //*************************************************************************************************
216 template< typename MT >
217 struct YieldsUniUpper<Real,MT>
218  : public IsUniUpper<MT>
219 {};
221 //*************************************************************************************************
222 
223 
224 
225 
226 //=================================================================================================
227 //
228 // YIELDSSTRICTLYUPPER SPECIALIZATIONS
229 //
230 //=================================================================================================
231 
232 //*************************************************************************************************
234 template< typename MT >
235 struct YieldsStrictlyUpper<Real,MT>
236  : public IsStrictlyUpper<MT>
237 {};
239 //*************************************************************************************************
240 
241 
242 
243 
244 //=================================================================================================
245 //
246 // YIELDSZERO SPECIALIZATIONS
247 //
248 //=================================================================================================
249 
250 //*************************************************************************************************
252 template< typename T >
253 struct YieldsZero<Real,T>
254  : public IsZero<T>
255 {};
257 //*************************************************************************************************
258 
259 } // namespace blaze
260 
261 #endif
Header file for the IsUniUpper type trait.
decltype(auto) real(const DenseMatrix< MT, SO > &dm)
Returns a matrix containing the real part of each single element of dm.
Definition: DMatMapExpr.h:1389
Header file for the YieldsStrictlyLower type trait.
Header file for the YieldsZero type trait.
Header file for the IsUniLower 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
Header file for the YieldsStrictlyUpper type trait.
Header file for the YieldsUniLower 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.
Generic wrapper for the real() function.
Definition: Real.h:80
Header file for the YieldsUpper type trait.
Header file for the IsZero type trait.
Header file for the YieldsLower type trait.
IntegralConstant< bool, B > BoolConstant
Generic wrapper for a compile time constant boolean value.The BoolConstant alias template represents ...
Definition: IntegralConstant.h:110
Macro for CUDA compatibility.
Header file for the IntegralConstant class template.
#define BLAZE_DEVICE_CALLABLE
Conditional macro that sets host and device attributes when compiled with CUDA.
Definition: HostDevice.h:94
Header file for the IsUpper type trait.
Header file for the YieldsUniUpper type trait.
Header file for the real shim.
Header file for the IsHermitian type trait.
System settings for the inline keywords.