Blaze  3.6
Proxy.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_PROXY_PROXY_H_
36 #define _BLAZE_MATH_PROXY_PROXY_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
43 #include <iosfwd>
44 #include <blaze/math/Aliases.h>
45 #include <blaze/math/Exception.h>
53 #include <blaze/math/shims/Abs.h>
54 #include <blaze/math/shims/Acos.h>
55 #include <blaze/math/shims/Acosh.h>
56 #include <blaze/math/shims/Asin.h>
57 #include <blaze/math/shims/Asinh.h>
58 #include <blaze/math/shims/Atan.h>
59 #include <blaze/math/shims/Atan2.h>
60 #include <blaze/math/shims/Atanh.h>
61 #include <blaze/math/shims/Cbrt.h>
62 #include <blaze/math/shims/Ceil.h>
64 #include <blaze/math/shims/Cos.h>
65 #include <blaze/math/shims/Cosh.h>
66 #include <blaze/math/shims/Erf.h>
67 #include <blaze/math/shims/Erfc.h>
68 #include <blaze/math/shims/Exp.h>
69 #include <blaze/math/shims/Exp2.h>
70 #include <blaze/math/shims/Exp10.h>
71 #include <blaze/math/shims/Floor.h>
76 #include <blaze/math/shims/IsNaN.h>
77 #include <blaze/math/shims/IsOne.h>
80 #include <blaze/math/shims/Log.h>
81 #include <blaze/math/shims/Log2.h>
82 #include <blaze/math/shims/Log10.h>
83 #include <blaze/math/shims/Pow.h>
84 #include <blaze/math/shims/Pow2.h>
85 #include <blaze/math/shims/Pow3.h>
86 #include <blaze/math/shims/Pow4.h>
87 #include <blaze/math/shims/Real.h>
88 #include <blaze/math/shims/Round.h>
89 #include <blaze/math/shims/Sign.h>
90 #include <blaze/math/shims/Sin.h>
91 #include <blaze/math/shims/Sinh.h>
92 #include <blaze/math/shims/Sqrt.h>
93 #include <blaze/math/shims/Tan.h>
94 #include <blaze/math/shims/Tanh.h>
95 #include <blaze/math/shims/Trunc.h>
103 #include <blaze/util/DisableIf.h>
104 #include <blaze/util/mpl/If.h>
106 
107 
108 namespace blaze {
109 
110 //=================================================================================================
111 //
112 // CLASS DEFINITION
113 //
114 //=================================================================================================
115 
116 //*************************************************************************************************
148 template< typename PT // Type of the proxy
149  , typename RT = int > // Type of the represented element
150 class Proxy
151  : public If_t< IsVector_v<RT>
152  , If_t< IsDenseVector_v<RT>
153  , DenseVectorProxy<PT,RT>
154  , SparseVectorProxy<PT,RT> >
155  , If_t< IsMatrix_v<RT>
156  , If_t< IsDenseMatrix_v<RT>
157  , DenseMatrixProxy<PT,RT>
158  , SparseMatrixProxy<PT,RT> >
159  , If_t< IsComplex_v<RT>
160  , ComplexProxy<PT,RT>
161  , DefaultProxy<PT,RT> > > >
162 {};
163 //*************************************************************************************************
164 
165 
166 
167 
168 //=================================================================================================
169 //
170 // GLOBAL OPERATORS
171 //
172 //=================================================================================================
173 
174 //*************************************************************************************************
177 template< typename PT1, typename RT1, typename PT2, typename RT2 >
178 decltype(auto) operator+( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
179 
180 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
181 decltype(auto) operator+( const Proxy<PT,RT>& lhs, const T& rhs );
182 
183 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
184 decltype(auto) operator+( const T& lhs, const Proxy<PT,RT>& rhs );
185 
186 template< typename PT1, typename RT1, typename PT2, typename RT2 >
187 decltype(auto) operator-( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
188 
189 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
190 decltype(auto) operator-( const Proxy<PT,RT>& lhs, const T& rhs );
191 
192 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
193 decltype(auto) operator-( const T& lhs, const Proxy<PT,RT>& rhs );
194 
195 template< typename PT1, typename RT1, typename PT2, typename RT2 >
196 decltype(auto) operator*( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
197 
198 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
199 decltype(auto) operator*( const Proxy<PT,RT>& lhs, const T& rhs );
200 
201 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
202 decltype(auto) operator*( const T& lhs, const Proxy<PT,RT>& rhs );
203 
204 template< typename PT1, typename RT1, typename PT2, typename RT2 >
205 decltype(auto) operator/( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
206 
207 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
208 decltype(auto) operator/( const Proxy<PT,RT>& lhs, const T& rhs );
209 
210 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
211 decltype(auto) operator/( const T& lhs, const Proxy<PT,RT>& rhs );
212 
213 template< typename PT1, typename RT1, typename PT2, typename RT2 >
214 bool operator==( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
215 
216 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
217 bool operator==( const Proxy<PT,RT>& lhs, const T& rhs );
218 
219 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
220 bool operator==( const T& lhs, const Proxy<PT,RT>& rhs );
221 
222 template< typename PT1, typename RT1, typename PT2, typename RT2 >
223 bool operator!=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
224 
225 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
226 bool operator!=( const Proxy<PT,RT>& lhs, const T& rhs );
227 
228 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
229 bool operator!=( const T& lhs, const Proxy<PT,RT>& rhs );
230 
231 template< typename PT1, typename RT1, typename PT2, typename RT2 >
232 bool operator<( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
233 
234 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
235 bool operator<( const Proxy<PT,RT>& lhs, const T& rhs );
236 
237 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
238 bool operator<( const T& lhs, const Proxy<PT,RT>& rhs );
239 
240 template< typename PT1, typename RT1, typename PT2, typename RT2 >
241 bool operator>( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
242 
243 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
244 bool operator>( const Proxy<PT,RT>& lhs, const T& rhs );
245 
246 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
247 bool operator>( const T& lhs, const Proxy<PT,RT>& rhs );
248 
249 template< typename PT1, typename RT1, typename PT2, typename RT2 >
250 bool operator<=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
251 
252 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
253 bool operator<=( const Proxy<PT,RT>& lhs, const T& rhs );
254 
255 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
256 bool operator<=( const T& lhs, const Proxy<PT,RT>& rhs );
257 
258 template< typename PT1, typename RT1, typename PT2, typename RT2 >
259 bool operator>=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
260 
261 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
262 bool operator>=( const Proxy<PT,RT>& lhs, const T& rhs );
263 
264 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
265 bool operator>=( const T& lhs, const Proxy<PT,RT>& rhs );
266 
267 template< typename PT, typename RT >
268 std::ostream& operator<<( std::ostream& os, const Proxy<PT,RT>& proxy );
270 //*************************************************************************************************
271 
272 
273 //*************************************************************************************************
281 template< typename PT1, typename RT1, typename PT2, typename RT2 >
282 inline decltype(auto) operator+( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
283 {
284  return (~lhs).get() + (~rhs).get();
285 }
286 //*************************************************************************************************
287 
288 
289 //*************************************************************************************************
297 template< typename PT, typename RT, typename T, typename >
298 inline decltype(auto) operator+( const Proxy<PT,RT>& lhs, const T& rhs )
299 {
300  return (~lhs).get() + rhs;
301 }
302 //*************************************************************************************************
303 
304 
305 //*************************************************************************************************
313 template< typename T, typename PT, typename RT, typename >
314 inline decltype(auto) operator+( const T& lhs, const Proxy<PT,RT>& rhs )
315 {
316  return lhs + (~rhs).get();
317 }
318 //*************************************************************************************************
319 
320 
321 //*************************************************************************************************
329 template< typename PT1, typename RT1, typename PT2, typename RT2 >
330 inline decltype(auto) operator-( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
331 {
332  return (~lhs).get() - (~rhs).get();
333 }
334 //*************************************************************************************************
335 
336 
337 //*************************************************************************************************
345 template< typename PT, typename RT, typename T, typename >
346 inline decltype(auto) operator-( const Proxy<PT,RT>& lhs, const T& rhs )
347 {
348  return (~lhs).get() - rhs;
349 }
350 //*************************************************************************************************
351 
352 
353 //*************************************************************************************************
361 template< typename T, typename PT, typename RT, typename >
362 inline decltype(auto) operator-( const T& lhs, const Proxy<PT,RT>& rhs )
363 {
364  return lhs - (~rhs).get();
365 }
366 //*************************************************************************************************
367 
368 
369 //*************************************************************************************************
377 template< typename PT1, typename RT1, typename PT2, typename RT2 >
378 inline decltype(auto) operator*( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
379 {
380  return (~lhs).get() * (~rhs).get();
381 }
382 //*************************************************************************************************
383 
384 
385 //*************************************************************************************************
393 template< typename PT, typename RT, typename T, typename >
394 inline decltype(auto) operator*( const Proxy<PT,RT>& lhs, const T& rhs )
395 {
396  return (~lhs).get() * rhs;
397 }
398 //*************************************************************************************************
399 
400 
401 //*************************************************************************************************
409 template< typename T, typename PT, typename RT, typename >
410 inline decltype(auto) operator*( const T& lhs, const Proxy<PT,RT>& rhs )
411 {
412  return lhs * (~rhs).get();
413 }
414 //*************************************************************************************************
415 
416 
417 //*************************************************************************************************
425 template< typename PT1, typename RT1, typename PT2, typename RT2 >
426 inline decltype(auto) operator/( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
427 {
428  return (~lhs).get() / (~rhs).get();
429 }
430 //*************************************************************************************************
431 
432 
433 //*************************************************************************************************
441 template< typename PT, typename RT, typename T, typename >
442 inline decltype(auto) operator/( const Proxy<PT,RT>& lhs, const T& rhs )
443 {
444  return (~lhs).get() / rhs;
445 }
446 //*************************************************************************************************
447 
448 
449 //*************************************************************************************************
457 template< typename T, typename PT, typename RT, typename >
458 inline decltype(auto) operator/( const T& lhs, const Proxy<PT,RT>& rhs )
459 {
460  return lhs / (~rhs).get();
461 }
462 //*************************************************************************************************
463 
464 
465 //*************************************************************************************************
473 template< typename PT1, typename RT1, typename PT2, typename RT2 >
474 inline bool operator==( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
475 {
476  return ( (~lhs).get() == (~rhs).get() );
477 }
478 //*************************************************************************************************
479 
480 
481 //*************************************************************************************************
489 template< typename PT, typename RT, typename T, typename >
490 inline bool operator==( const Proxy<PT,RT>& lhs, const T& rhs )
491 {
492  return ( (~lhs).get() == rhs );
493 }
494 //*************************************************************************************************
495 
496 
497 //*************************************************************************************************
505 template< typename T, typename PT, typename RT, typename >
506 inline bool operator==( const T& lhs, const Proxy<PT,RT>& rhs )
507 {
508  return ( lhs == (~rhs).get() );
509 }
510 //*************************************************************************************************
511 
512 
513 //*************************************************************************************************
521 template< typename PT1, typename RT1, typename PT2, typename RT2 >
522 inline bool operator!=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
523 {
524  return ( (~lhs).get() != (~rhs).get() );
525 }
526 //*************************************************************************************************
527 
528 
529 //*************************************************************************************************
537 template< typename PT, typename RT, typename T, typename >
538 inline bool operator!=( const Proxy<PT,RT>& lhs, const T& rhs )
539 {
540  return ( (~lhs).get() != rhs );
541 }
542 //*************************************************************************************************
543 
544 
545 //*************************************************************************************************
553 template< typename T, typename PT, typename RT, typename >
554 inline bool operator!=( const T& lhs, const Proxy<PT,RT>& rhs )
555 {
556  return ( lhs != (~rhs).get() );
557 }
558 //*************************************************************************************************
559 
560 
561 //*************************************************************************************************
569 template< typename PT1, typename RT1, typename PT2, typename RT2 >
570 inline bool operator<( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
571 {
572  return ( (~lhs).get() < (~rhs).get() );
573 }
574 //*************************************************************************************************
575 
576 
577 //*************************************************************************************************
585 template< typename PT, typename RT, typename T, typename >
586 inline bool operator<( const Proxy<PT,RT>& lhs, const T& rhs )
587 {
588  return ( (~lhs).get() < rhs );
589 }
590 //*************************************************************************************************
591 
592 
593 //*************************************************************************************************
601 template< typename T, typename PT, typename RT, typename >
602 inline bool operator<( const T& lhs, const Proxy<PT,RT>& rhs )
603 {
604  return ( lhs < rhs.get() );
605 }
606 //*************************************************************************************************
607 
608 
609 //*************************************************************************************************
617 template< typename PT1, typename RT1, typename PT2, typename RT2 >
618 inline bool operator>( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
619 {
620  return ( (~lhs).get() > (~rhs).get() );
621 }
622 //*************************************************************************************************
623 
624 
625 //*************************************************************************************************
633 template< typename PT, typename RT, typename T, typename >
634 inline bool operator>( const Proxy<PT,RT>& lhs, const T& rhs )
635 {
636  return ( (~lhs).get() > rhs );
637 }
638 //*************************************************************************************************
639 
640 
641 //*************************************************************************************************
649 template< typename T, typename PT, typename RT, typename >
650 inline bool operator>( const T& lhs, const Proxy<PT,RT>& rhs )
651 {
652  return ( lhs > (~rhs).get() );
653 }
654 //*************************************************************************************************
655 
656 
657 //*************************************************************************************************
665 template< typename PT1, typename RT1, typename PT2, typename RT2 >
666 inline bool operator<=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
667 {
668  return ( (~lhs).get() <= (~rhs).get() );
669 }
670 //*************************************************************************************************
671 
672 
673 //*************************************************************************************************
681 template< typename PT, typename RT, typename T, typename >
682 inline bool operator<=( const Proxy<PT,RT>& lhs, const T& rhs )
683 {
684  return ( (~lhs).get() <= rhs );
685 }
686 //*************************************************************************************************
687 
688 
689 //*************************************************************************************************
697 template< typename T, typename PT, typename RT, typename >
698 inline bool operator<=( const T& lhs, const Proxy<PT,RT>& rhs )
699 {
700  return ( lhs <= (~rhs).get() );
701 }
702 //*************************************************************************************************
703 
704 
705 //*************************************************************************************************
713 template< typename PT1, typename RT1, typename PT2, typename RT2 >
714 inline bool operator>=( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
715 {
716  return ( (~lhs).get() >= (~rhs).get() );
717 }
718 //*************************************************************************************************
719 
720 
721 //*************************************************************************************************
729 template< typename PT, typename RT, typename T, typename >
730 inline bool operator>=( const Proxy<PT,RT>& lhs, const T& rhs )
731 {
732  return ( (~lhs).get() >= rhs );
733 }
734 //*************************************************************************************************
735 
736 
737 //*************************************************************************************************
745 template< typename T, typename PT, typename RT, typename >
746 inline bool operator>=( const T& lhs, const Proxy<PT,RT>& rhs )
747 {
748  return ( lhs >= (~rhs).get() );
749 }
750 //*************************************************************************************************
751 
752 
753 //*************************************************************************************************
761 template< typename PT, typename RT >
762 inline std::ostream& operator<<( std::ostream& os, const Proxy<PT,RT>& proxy )
763 {
764  return os << (~proxy).get();
765 }
766 //*************************************************************************************************
767 
768 
769 
770 
771 //=================================================================================================
772 //
773 // GLOBAL FUNCTIONS
774 //
775 //=================================================================================================
776 
777 //*************************************************************************************************
780 template< typename PT, typename RT >
781 decltype(auto) abs( const Proxy<PT,RT>& proxy );
782 
783 template< typename PT, typename RT >
784 decltype(auto) sign( const Proxy<PT,RT>& proxy );
785 
786 template< typename PT, typename RT >
787 decltype(auto) floor( const Proxy<PT,RT>& proxy );
788 
789 template< typename PT, typename RT >
790 decltype(auto) ceil( const Proxy<PT,RT>& proxy );
791 
792 template< typename PT, typename RT >
793 decltype(auto) trunc( const Proxy<PT,RT>& proxy );
794 
795 template< typename PT, typename RT >
796 decltype(auto) round( const Proxy<PT,RT>& proxy );
797 
798 template< typename PT, typename RT >
799 decltype(auto) conj( const Proxy<PT,RT>& proxy );
800 
801 template< typename PT, typename RT >
802 decltype(auto) trans( const Proxy<PT,RT>& proxy );
803 
804 template< typename PT, typename RT >
805 decltype(auto) ctrans( const Proxy<PT,RT>& proxy );
806 
807 template< typename PT, typename RT >
808 decltype(auto) real( const Proxy<PT,RT>& proxy );
809 
810 template< typename PT, typename RT >
811 decltype(auto) imag( const Proxy<PT,RT>& proxy );
812 
813 template< typename PT, typename RT >
814 decltype(auto) sqrt( const Proxy<PT,RT>& proxy );
815 
816 template< typename PT, typename RT >
817 decltype(auto) invsqrt( const Proxy<PT,RT>& proxy );
818 
819 template< typename PT, typename RT >
820 decltype(auto) cbrt( const Proxy<PT,RT>& proxy );
821 
822 template< typename PT, typename RT >
823 decltype(auto) invcbrt( const Proxy<PT,RT>& proxy );
824 
825 template< typename PT1, typename RT1, typename PT2, typename RT2 >
826 decltype(auto) hypot( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
827 
828 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
829 decltype(auto) hypot( const Proxy<PT,RT>& lhs, const T& rhs );
830 
831 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
832 decltype(auto) hypot( const T& lhs, const Proxy<PT,RT>& rhs );
833 
834 template< typename PT, typename RT, typename ET >
835 decltype(auto) pow( const Proxy<PT,RT>& proxy, const ET& exp );
836 
837 template< typename PT, typename RT >
838 decltype(auto) pow2( const Proxy<PT,RT>& proxy );
839 
840 template< typename PT, typename RT >
841 decltype(auto) pow3( const Proxy<PT,RT>& proxy );
842 
843 template< typename PT, typename RT >
844 decltype(auto) pow4( const Proxy<PT,RT>& proxy );
845 
846 template< typename PT, typename RT >
847 decltype(auto) exp( const Proxy<PT,RT>& proxy );
848 
849 template< typename PT, typename RT >
850 decltype(auto) exp2( const Proxy<PT,RT>& proxy );
851 
852 template< typename PT, typename RT >
853 decltype(auto) exp10( const Proxy<PT,RT>& proxy );
854 
855 template< typename PT, typename RT >
856 decltype(auto) log( const Proxy<PT,RT>& proxy );
857 
858 template< typename PT, typename RT >
859 decltype(auto) log2( const Proxy<PT,RT>& proxy );
860 
861 template< typename PT, typename RT >
862 decltype(auto) log10( const Proxy<PT,RT>& proxy );
863 
864 template< typename PT, typename RT >
865 decltype(auto) sin( const Proxy<PT,RT>& proxy );
866 
867 template< typename PT, typename RT >
868 decltype(auto) asin( const Proxy<PT,RT>& proxy );
869 
870 template< typename PT, typename RT >
871 decltype(auto) sinh( const Proxy<PT,RT>& proxy );
872 
873 template< typename PT, typename RT >
874 decltype(auto) asinh( const Proxy<PT,RT>& proxy );
875 
876 template< typename PT, typename RT >
877 decltype(auto) cos( const Proxy<PT,RT>& proxy );
878 
879 template< typename PT, typename RT >
880 decltype(auto) acos( const Proxy<PT,RT>& proxy );
881 
882 template< typename PT, typename RT >
883 decltype(auto) cosh( const Proxy<PT,RT>& proxy );
884 
885 template< typename PT, typename RT >
886 decltype(auto) acosh( const Proxy<PT,RT>& proxy );
887 
888 template< typename PT, typename RT >
889 decltype(auto) tan( const Proxy<PT,RT>& proxy );
890 
891 template< typename PT, typename RT >
892 decltype(auto) atan( const Proxy<PT,RT>& proxy );
893 
894 template< typename PT, typename RT >
895 decltype(auto) tanh( const Proxy<PT,RT>& proxy );
896 
897 template< typename PT, typename RT >
898 decltype(auto) atanh( const Proxy<PT,RT>& proxy );
899 
900 template< typename PT1, typename RT1, typename PT2, typename RT2 >
901 decltype(auto) atan2( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
902 
903 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
904 decltype(auto) atan2( const Proxy<PT,RT>& lhs, const T& rhs );
905 
906 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
907 decltype(auto) atan2( const T& lhs, const Proxy<PT,RT>& rhs );
908 
909 template< typename PT, typename RT >
910 decltype(auto) erf( const Proxy<PT,RT>& proxy );
911 
912 template< typename PT, typename RT >
913 decltype(auto) erfc( const Proxy<PT,RT>& proxy );
914 
915 template< typename PT1, typename RT1, typename PT2, typename RT2 >
916 decltype(auto) min( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
917 
918 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
919 decltype(auto) min( const Proxy<PT,RT>& lhs, const T& rhs );
920 
921 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
922 decltype(auto) min( const T& lhs, const Proxy<PT,RT>& rhs );
923 
924 template< typename PT1, typename RT1, typename PT2, typename RT2 >
925 decltype(auto) max( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
926 
927 template< typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
928 decltype(auto) max( const Proxy<PT,RT>& lhs, const T& rhs );
929 
930 template< typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
931 decltype(auto) max( const T& lhs, const Proxy<PT,RT>& rhs );
932 
933 template< typename PT, typename RT >
934 void transpose( const Proxy<PT,RT>& proxy );
935 
936 template< typename PT, typename RT >
937 void ctranspose( const Proxy<PT,RT>& proxy );
938 
939 template< typename PT, typename RT >
940 void invert( const Proxy<PT,RT>& proxy );
941 
942 template< InversionFlag IF, typename PT, typename RT >
943 void invert( const Proxy<PT,RT>& proxy );
944 
945 template< bool RF, typename PT, typename RT >
946 bool isReal( const Proxy<PT,RT>& proxy );
947 
948 template< bool RF, typename PT, typename RT >
949 bool isZero( const Proxy<PT,RT>& proxy );
950 
951 template< bool RF, typename PT, typename RT >
952 bool isOne( const Proxy<PT,RT>& proxy );
953 
954 template< typename PT, typename RT >
955 bool isnan( const Proxy<PT,RT>& proxy );
956 
957 template< bool RF, typename PT1, typename RT1, typename PT2, typename RT2 >
958 bool equal( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs );
959 
960 template< bool RF, typename PT, typename RT, typename T, typename = DisableIf_t< IsProxy_v<T> > >
961 bool equal( const Proxy<PT,RT>& lhs, const T& rhs );
962 
963 template< bool RF, typename T, typename PT, typename RT, typename = DisableIf_t< IsProxy_v<T> > >
964 bool equal( const T& lhs, const Proxy<PT,RT>& rhs );
966 //*************************************************************************************************
967 
968 
969 //*************************************************************************************************
980 template< typename PT, typename RT >
981 inline decltype(auto) abs( const Proxy<PT,RT>& proxy )
982 {
983  using blaze::abs;
984 
985  return abs( (~proxy).get() );
986 }
987 //*************************************************************************************************
988 
989 
990 //*************************************************************************************************
1001 template< typename PT, typename RT >
1002 inline decltype(auto) sign( const Proxy<PT,RT>& proxy )
1003 {
1004  using blaze::sign;
1005 
1006  return sign( (~proxy).get() );
1007 }
1008 //*************************************************************************************************
1009 
1010 
1011 //*************************************************************************************************
1022 template< typename PT, typename RT >
1023 inline decltype(auto) floor( const Proxy<PT,RT>& proxy )
1024 {
1025  using blaze::floor;
1026 
1027  return floor( (~proxy).get() );
1028 }
1029 //*************************************************************************************************
1030 
1031 
1032 //*************************************************************************************************
1043 template< typename PT, typename RT >
1044 inline decltype(auto) ceil( const Proxy<PT,RT>& proxy )
1045 {
1046  using blaze::ceil;
1047 
1048  return ceil( (~proxy).get() );
1049 }
1050 //*************************************************************************************************
1051 
1052 
1053 //*************************************************************************************************
1064 template< typename PT, typename RT >
1065 inline decltype(auto) trunc( const Proxy<PT,RT>& proxy )
1066 {
1067  using blaze::trunc;
1068 
1069  return trunc( (~proxy).get() );
1070 }
1071 //*************************************************************************************************
1072 
1073 
1074 //*************************************************************************************************
1085 template< typename PT, typename RT >
1086 inline decltype(auto) round( const Proxy<PT,RT>& proxy )
1087 {
1088  using blaze::round;
1089 
1090  return round( (~proxy).get() );
1091 }
1092 //*************************************************************************************************
1093 
1094 
1095 //*************************************************************************************************
1106 template< typename PT, typename RT >
1107 inline decltype(auto) conj( const Proxy<PT,RT>& proxy )
1108 {
1109  using blaze::conj;
1110 
1111  return conj( (~proxy).get() );
1112 }
1113 //*************************************************************************************************
1114 
1115 
1116 //*************************************************************************************************
1126 template< typename PT, typename RT >
1127 inline decltype(auto) trans( const Proxy<PT,RT>& proxy )
1128 {
1129  using blaze::trans;
1130 
1131  return trans( (~proxy).get() );
1132 }
1133 //*************************************************************************************************
1134 
1135 
1136 //*************************************************************************************************
1146 template< typename PT, typename RT >
1147 inline decltype(auto) ctrans( const Proxy<PT,RT>& proxy )
1148 {
1149  using blaze::ctrans;
1150 
1151  return ctrans( (~proxy).get() );
1152 }
1153 //*************************************************************************************************
1154 
1155 
1156 //*************************************************************************************************
1167 template< typename PT, typename RT >
1168 inline decltype(auto) real( const Proxy<PT,RT>& proxy )
1169 {
1170  using blaze::real;
1171 
1172  return real( (~proxy).get() );
1173 }
1174 //*************************************************************************************************
1175 
1176 
1177 //*************************************************************************************************
1188 template< typename PT, typename RT >
1189 inline decltype(auto) imag( const Proxy<PT,RT>& proxy )
1190 {
1191  using blaze::imag;
1192 
1193  return imag( (~proxy).get() );
1194 }
1195 //*************************************************************************************************
1196 
1197 
1198 //*************************************************************************************************
1209 template< typename PT, typename RT >
1210 inline decltype(auto) sqrt( const Proxy<PT,RT>& proxy )
1211 {
1212  using blaze::sqrt;
1213 
1214  return sqrt( (~proxy).get() );
1215 }
1216 //*************************************************************************************************
1217 
1218 
1219 //*************************************************************************************************
1230 template< typename PT, typename RT >
1231 inline decltype(auto) invsqrt( const Proxy<PT,RT>& proxy )
1232 {
1233  using blaze::invsqrt;
1234 
1235  return invsqrt( (~proxy).get() );
1236 }
1237 //*************************************************************************************************
1238 
1239 
1240 //*************************************************************************************************
1251 template< typename PT, typename RT >
1252 inline decltype(auto) cbrt( const Proxy<PT,RT>& proxy )
1253 {
1254  using blaze::cbrt;
1255 
1256  return cbrt( (~proxy).get() );
1257 }
1258 //*************************************************************************************************
1259 
1260 
1261 //*************************************************************************************************
1272 template< typename PT, typename RT >
1273 inline decltype(auto) invcbrt( const Proxy<PT,RT>& proxy )
1274 {
1275  using blaze::invcbrt;
1276 
1277  return invcbrt( (~proxy).get() );
1278 }
1279 //*************************************************************************************************
1280 
1281 
1282 //*************************************************************************************************
1294 template< typename PT1, typename RT1, typename PT2, typename RT2 >
1295 inline decltype(auto) hypot( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
1296 {
1297  using blaze::hypot;
1298 
1299  return hypot( (~lhs).get(), (~rhs).get() );
1300 }
1301 //*************************************************************************************************
1302 
1303 
1304 //*************************************************************************************************
1317 template< typename PT, typename RT, typename T, typename >
1318 inline decltype(auto) hypot( const Proxy<PT,RT>& lhs, const T& rhs )
1319 {
1320  using blaze::hypot;
1321 
1322  return hypot( (~lhs).get(), rhs );
1323 }
1324 //*************************************************************************************************
1325 
1326 
1327 //*************************************************************************************************
1340 template< typename T, typename PT, typename RT, typename >
1341 inline decltype(auto) hypot( const T& lhs, const Proxy<PT,RT>& rhs )
1342 {
1343  using blaze::hypot;
1344 
1345  return hypot( lhs, (~rhs).get() );
1346 }
1347 //*************************************************************************************************
1348 
1349 
1350 //*************************************************************************************************
1362 template< typename PT, typename RT, typename ET >
1363 inline decltype(auto) pow( const Proxy<PT,RT>& proxy, const ET& exp )
1364 {
1365  using blaze::pow;
1366 
1367  return pow( (~proxy).get(), exp );
1368 }
1369 //*************************************************************************************************
1370 
1371 
1372 //*************************************************************************************************
1383 template< typename PT, typename RT, typename ET >
1384 inline decltype(auto) pow2( const Proxy<PT,RT>& proxy )
1385 {
1386  using blaze::pow2;
1387 
1388  return pow2( (~proxy).get() );
1389 }
1390 //*************************************************************************************************
1391 
1392 
1393 //*************************************************************************************************
1404 template< typename PT, typename RT, typename ET >
1405 inline decltype(auto) pow3( const Proxy<PT,RT>& proxy )
1406 {
1407  using blaze::pow3;
1408 
1409  return pow3( (~proxy).get() );
1410 }
1411 //*************************************************************************************************
1412 
1413 
1414 //*************************************************************************************************
1425 template< typename PT, typename RT, typename ET >
1426 inline decltype(auto) pow4( const Proxy<PT,RT>& proxy )
1427 {
1428  using blaze::pow4;
1429 
1430  return pow4( (~proxy).get() );
1431 }
1432 //*************************************************************************************************
1433 
1434 
1435 //*************************************************************************************************
1446 template< typename PT, typename RT >
1447 inline decltype(auto) exp( const Proxy<PT,RT>& proxy )
1448 {
1449  using blaze::exp;
1450 
1451  return exp( (~proxy).get() );
1452 }
1453 //*************************************************************************************************
1454 
1455 
1456 //*************************************************************************************************
1467 template< typename PT, typename RT >
1468 inline decltype(auto) exp2( const Proxy<PT,RT>& proxy )
1469 {
1470  using blaze::exp2;
1471 
1472  return exp2( (~proxy).get() );
1473 }
1474 //*************************************************************************************************
1475 
1476 
1477 //*************************************************************************************************
1488 template< typename PT, typename RT >
1489 inline decltype(auto) exp10( const Proxy<PT,RT>& proxy )
1490 {
1491  using blaze::exp10;
1492 
1493  return exp10( (~proxy).get() );
1494 }
1495 //*************************************************************************************************
1496 
1497 
1498 //*************************************************************************************************
1509 template< typename PT, typename RT >
1510 inline decltype(auto) log( const Proxy<PT,RT>& proxy )
1511 {
1512  using blaze::log;
1513 
1514  return log( (~proxy).get() );
1515 }
1516 //*************************************************************************************************
1517 
1518 
1519 //*************************************************************************************************
1530 template< typename PT, typename RT >
1531 inline decltype(auto) log2( const Proxy<PT,RT>& proxy )
1532 {
1533  using blaze::log2;
1534 
1535  return log2( (~proxy).get() );
1536 }
1537 //*************************************************************************************************
1538 
1539 
1540 //*************************************************************************************************
1551 template< typename PT, typename RT >
1552 inline decltype(auto) log10( const Proxy<PT,RT>& proxy )
1553 {
1554  using blaze::log10;
1555 
1556  return log10( (~proxy).get() );
1557 }
1558 //*************************************************************************************************
1559 
1560 
1561 //*************************************************************************************************
1572 template< typename PT, typename RT >
1573 inline decltype(auto) sin( const Proxy<PT,RT>& proxy )
1574 {
1575  using blaze::sin;
1576 
1577  return sin( (~proxy).get() );
1578 }
1579 //*************************************************************************************************
1580 
1581 
1582 //*************************************************************************************************
1593 template< typename PT, typename RT >
1594 inline decltype(auto) asin( const Proxy<PT,RT>& proxy )
1595 {
1596  using blaze::asin;
1597 
1598  return asin( (~proxy).get() );
1599 }
1600 //*************************************************************************************************
1601 
1602 
1603 //*************************************************************************************************
1614 template< typename PT, typename RT >
1615 inline decltype(auto) sinh( const Proxy<PT,RT>& proxy )
1616 {
1617  using blaze::sinh;
1618 
1619  return sinh( (~proxy).get() );
1620 }
1621 //*************************************************************************************************
1622 
1623 
1624 //*************************************************************************************************
1635 template< typename PT, typename RT >
1636 inline decltype(auto) asinh( const Proxy<PT,RT>& proxy )
1637 {
1638  using blaze::asinh;
1639 
1640  return asinh( (~proxy).get() );
1641 }
1642 //*************************************************************************************************
1643 
1644 
1645 //*************************************************************************************************
1656 template< typename PT, typename RT >
1657 inline decltype(auto) cos( const Proxy<PT,RT>& proxy )
1658 {
1659  using blaze::cos;
1660 
1661  return cos( (~proxy).get() );
1662 }
1663 //*************************************************************************************************
1664 
1665 
1666 //*************************************************************************************************
1677 template< typename PT, typename RT >
1678 inline decltype(auto) acos( const Proxy<PT,RT>& proxy )
1679 {
1680  using blaze::acos;
1681 
1682  return acos( (~proxy).get() );
1683 }
1684 //*************************************************************************************************
1685 
1686 
1687 //*************************************************************************************************
1698 template< typename PT, typename RT >
1699 inline decltype(auto) cosh( const Proxy<PT,RT>& proxy )
1700 {
1701  using blaze::cosh;
1702 
1703  return cosh( (~proxy).get() );
1704 }
1705 //*************************************************************************************************
1706 
1707 
1708 //*************************************************************************************************
1719 template< typename PT, typename RT >
1720 inline decltype(auto) acosh( const Proxy<PT,RT>& proxy )
1721 {
1722  using blaze::acosh;
1723 
1724  return acosh( (~proxy).get() );
1725 }
1726 //*************************************************************************************************
1727 
1728 
1729 //*************************************************************************************************
1740 template< typename PT, typename RT >
1741 inline decltype(auto) tan( const Proxy<PT,RT>& proxy )
1742 {
1743  using blaze::tan;
1744 
1745  return tan( (~proxy).get() );
1746 }
1747 //*************************************************************************************************
1748 
1749 
1750 //*************************************************************************************************
1761 template< typename PT, typename RT >
1762 inline decltype(auto) atan( const Proxy<PT,RT>& proxy )
1763 {
1764  using blaze::atan;
1765 
1766  return atan( (~proxy).get() );
1767 }
1768 //*************************************************************************************************
1769 
1770 
1771 //*************************************************************************************************
1782 template< typename PT, typename RT >
1783 inline decltype(auto) tanh( const Proxy<PT,RT>& proxy )
1784 {
1785  using blaze::tanh;
1786 
1787  return tanh( (~proxy).get() );
1788 }
1789 //*************************************************************************************************
1790 
1791 
1792 //*************************************************************************************************
1803 template< typename PT, typename RT >
1804 inline decltype(auto) atanh( const Proxy<PT,RT>& proxy )
1805 {
1806  using blaze::atanh;
1807 
1808  return atanh( (~proxy).get() );
1809 }
1810 //*************************************************************************************************
1811 
1812 
1813 //*************************************************************************************************
1826 template< typename PT1, typename RT1, typename PT2, typename RT2 >
1827 inline decltype(auto) atan2( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
1828 {
1829  return atan2( (~lhs).get(), (~rhs).get() );
1830 }
1831 //*************************************************************************************************
1832 
1833 
1834 //*************************************************************************************************
1847 template< typename PT, typename RT, typename T, typename >
1848 inline decltype(auto) atan2( const Proxy<PT,RT>& lhs, const T& rhs )
1849 {
1850  return atan2( (~lhs).get(), rhs );
1851 }
1852 //*************************************************************************************************
1853 
1854 
1855 //*************************************************************************************************
1868 template< typename T, typename PT, typename RT, typename >
1869 inline decltype(auto) atan2( const T& lhs, const Proxy<PT,RT>& rhs )
1870 {
1871  return atan2( lhs, (~rhs).get() );
1872 }
1873 //*************************************************************************************************
1874 
1875 
1876 //*************************************************************************************************
1887 template< typename PT, typename RT >
1888 inline decltype(auto) erf( const Proxy<PT,RT>& proxy )
1889 {
1890  using blaze::erf;
1891 
1892  return erf( (~proxy).get() );
1893 }
1894 //*************************************************************************************************
1895 
1896 
1897 //*************************************************************************************************
1909 template< typename PT, typename RT >
1910 inline decltype(auto) erfc( const Proxy<PT,RT>& proxy )
1911 {
1912  using blaze::erfc;
1913 
1914  return erfc( (~proxy).get() );
1915 }
1916 //*************************************************************************************************
1917 
1918 
1919 //*************************************************************************************************
1927 template< typename PT1, typename RT1, typename PT2, typename RT2 >
1928 inline decltype(auto) min( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
1929 {
1930  using blaze::min;
1931 
1932  return min( (~lhs).get(), (~rhs).get() );
1933 }
1934 //*************************************************************************************************
1935 
1936 
1937 //*************************************************************************************************
1945 template< typename PT, typename RT, typename T, typename >
1946 inline decltype(auto) min( const Proxy<PT,RT>& lhs, const T& rhs )
1947 {
1948  using blaze::min;
1949 
1950  return min( (~lhs).get(), rhs );
1951 }
1952 //*************************************************************************************************
1953 
1954 
1955 //*************************************************************************************************
1963 template< typename T, typename PT, typename RT, typename >
1964 inline decltype(auto) min( const T& lhs, const Proxy<PT,RT>& rhs )
1965 {
1966  using blaze::min;
1967 
1968  return min( lhs, (~rhs).get() );
1969 }
1970 //*************************************************************************************************
1971 
1972 
1973 //*************************************************************************************************
1981 template< typename PT1, typename RT1, typename PT2, typename RT2 >
1982 inline decltype(auto) max( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
1983 {
1984  using blaze::max;
1985 
1986  return max( (~lhs).get(), (~rhs).get() );
1987 }
1988 //*************************************************************************************************
1989 
1990 
1991 //*************************************************************************************************
1999 template< typename PT, typename RT, typename T, typename >
2000 inline decltype(auto) max( const Proxy<PT,RT>& lhs, const T& rhs )
2001 {
2002  using blaze::max;
2003 
2004  return max( (~lhs).get(), rhs );
2005 }
2006 //*************************************************************************************************
2007 
2008 
2009 //*************************************************************************************************
2017 template< typename T, typename PT, typename RT, typename >
2018 inline decltype(auto) max( const T& lhs, const Proxy<PT,RT>& rhs )
2019 {
2020  using blaze::max;
2021 
2022  return max( lhs, (~rhs).get() );
2023 }
2024 //*************************************************************************************************
2025 
2026 
2027 //*************************************************************************************************
2044 template< typename PT, typename RT >
2045 inline void transpose( const Proxy<PT,RT>& proxy )
2046 {
2047  if( (~proxy).isRestricted() ) {
2048  BLAZE_THROW_INVALID_ARGUMENT( "Invalid access to restricted element" );
2049  }
2050 
2051  transpose( (~proxy).get() );
2052 }
2053 //*************************************************************************************************
2054 
2055 
2056 //*************************************************************************************************
2073 template< typename PT, typename RT >
2074 inline void ctranspose( const Proxy<PT,RT>& proxy )
2075 {
2076  if( (~proxy).isRestricted() ) {
2077  BLAZE_THROW_INVALID_ARGUMENT( "Invalid access to restricted element" );
2078  }
2079 
2080  ctranspose( (~proxy).get() );
2081 }
2082 //*************************************************************************************************
2083 
2084 
2085 //*************************************************************************************************
2113 template< typename PT, typename RT >
2114 inline void invert( const Proxy<PT,RT>& proxy )
2115 {
2116  if( (~proxy).isRestricted() ) {
2117  BLAZE_THROW_INVALID_ARGUMENT( "Invalid access to restricted element" );
2118  }
2119 
2120  invert( (~proxy).get() );
2121 }
2122 //*************************************************************************************************
2123 
2124 
2125 //*************************************************************************************************
2162 template< InversionFlag IF, typename PT, typename RT >
2163 inline void invert( const Proxy<PT,RT>& proxy )
2164 {
2165  if( (~proxy).isRestricted() ) {
2166  BLAZE_THROW_INVALID_ARGUMENT( "Invalid access to restricted element" );
2167  }
2168 
2169  invert<IF>( (~proxy).get() );
2170 }
2171 //*************************************************************************************************
2172 
2173 
2174 //*************************************************************************************************
2186 template< bool RF, typename PT, typename RT >
2187 inline bool isReal( const Proxy<PT,RT>& proxy )
2188 {
2189  using blaze::isReal;
2190 
2191  return isReal<RF>( (~proxy).get() );
2192 }
2193 //*************************************************************************************************
2194 
2195 
2196 //*************************************************************************************************
2206 template< bool RF, typename PT, typename RT >
2207 inline bool isZero( const Proxy<PT,RT>& proxy )
2208 {
2209  using blaze::isZero;
2210 
2211  return isZero<RF>( (~proxy).get() );
2212 }
2213 //*************************************************************************************************
2214 
2215 
2216 //*************************************************************************************************
2226 template< bool RF, typename PT, typename RT >
2227 inline bool isOne( const Proxy<PT,RT>& proxy )
2228 {
2229  using blaze::isOne;
2230 
2231  return isOne<RF>( (~proxy).get() );
2232 }
2233 //*************************************************************************************************
2234 
2235 
2236 //*************************************************************************************************
2246 template< typename PT, typename RT >
2247 inline bool isnan( const Proxy<PT,RT>& proxy )
2248 {
2249  using blaze::isnan;
2250 
2251  return isnan( (~proxy).get() );
2252 }
2253 //*************************************************************************************************
2254 
2255 
2256 //*************************************************************************************************
2264 template< bool RF, typename PT1, typename RT1, typename PT2, typename RT2 >
2265 inline bool equal( const Proxy<PT1,RT1>& lhs, const Proxy<PT2,RT2>& rhs )
2266 {
2267  return equal<RF>( (~lhs).get(), (~rhs).get() );
2268 }
2269 //*************************************************************************************************
2270 
2271 
2272 //*************************************************************************************************
2280 template< bool RF, typename PT, typename RT, typename T, typename >
2281 inline bool equal( const Proxy<PT,RT>& lhs, const T& rhs )
2282 {
2283  return equal<RF>( (~lhs).get(), rhs );
2284 }
2285 //*************************************************************************************************
2286 
2287 
2288 //*************************************************************************************************
2296 template< bool RF, typename T, typename PT, typename RT, typename >
2297 inline bool equal( const T& lhs, const Proxy<PT,RT>& rhs )
2298 {
2299  return equal<RF>( lhs, (~rhs).get() );
2300 }
2301 //*************************************************************************************************
2302 
2303 } // namespace blaze
2304 
2305 #endif
bool isReal(const DiagonalProxy< MT > &proxy)
Returns whether the matrix element represents a real number.
Definition: DiagonalProxy.h:657
Header file for the isnan shim.
Header file for the sign shim.
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exception.This macro encapsulates the default way o...
Definition: Exception.h:235
decltype(auto) acosh(const DenseMatrix< MT, SO > &dm)
Computes the inverse hyperbolic cosine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2014
Header file for auxiliary alias declarations.
Headerfile for the generic min algorithm.
decltype(auto) exp10(const DenseMatrix< MT, SO > &dm)
Computes for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1688
Header file for the acos shim.
Header file for the asin shim.
Header file for the cosh shim.
Header file for the SparseVectorProxy class.
decltype(auto) hypot(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise hypotenous for the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1235
typename If< Condition, T1, T2 >::Type If_t
Auxiliary alias template for the If class template.The If_t alias template provides a convenient shor...
Definition: If.h:109
Header file for the imaginary shim.
Proxy base class.The Proxy class is a base class for all proxy classes within the Blaze library that ...
Definition: Forward.h:51
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 isZero shim.
Header file for the tan shim.
constexpr bool operator<(const NegativeAccuracy< A > &lhs, const T &rhs)
Less-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:332
Header file for the dense matrix inversion flags.
Header file for the DefaultProxy class.
decltype(auto) ceil(const DenseMatrix< MT, SO > &dm)
Applies the ceil() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1240
decltype(auto) pow(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise exponential value for the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1271
Header file for the DenseMatrixProxy class.
void ctranspose(Matrix< MT, SO > &matrix)
In-place conjugate transpose of the given matrix.
Definition: Matrix.h:851
Header file for the abs shim.
Header file for the pow shim.
Header file for the invert shim.
decltype(auto) sign(const DenseMatrix< MT, SO > &dm)
Applies the sign() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1184
decltype(auto) pow4(const Proxy< PT, RT > &proxy)
Computing the quadruple value of the represented element.
Definition: Proxy.h:1426
Header file for the exp2 shim.
decltype(auto) acos(const DenseMatrix< MT, SO > &dm)
Computes the inverse cosine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1955
Header file for the DenseVectorProxy class.
decltype(auto) erf(const DenseMatrix< MT, SO > &dm)
Computes the error function for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2160
Header file for the IsMatrix type trait.
Header file for the log10 shim.
bool isZero(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is 0.
Definition: DiagonalProxy.h:677
void invert(const HermitianProxy< MT > &proxy)
In-place inversion of the represented element.
Definition: HermitianProxy.h:779
Header file for the sqrt shim.
Headerfile for the generic max algorithm.
Header file for the DisableIf class template.
Header file for the floor shim.
decltype(auto) cos(const DenseMatrix< MT, SO > &dm)
Computes the cosine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1924
Namespace of the Blaze C++ math library.
Definition: Blaze.h:58
decltype(auto) ctrans(const DenseMatrix< MT, SO > &dm)
Returns the conjugate transpose matrix of dm.
Definition: DMatMapExpr.h:1361
Header file for the cos shim.
Header file for the If class template.
Header file for the log2 shim.
decltype(auto) exp2(const DenseMatrix< MT, SO > &dm)
Computes for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1660
Header file for the ComplexProxy class.
decltype(auto) sinh(const DenseMatrix< MT, SO > &dm)
Computes the hyperbolic sine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1868
decltype(auto) asin(const DenseMatrix< MT, SO > &dm)
Computes the inverse sine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1840
decltype(auto) cosh(const DenseMatrix< MT, SO > &dm)
Computes the hyperbolic cosine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1983
decltype(auto) min(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise minimum of the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1162
decltype(auto) cbrt(const DenseMatrix< MT, SO > &dm)
Computes the cubic root of each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1510
Header file for the erf shim.
constexpr bool operator>(const NegativeAccuracy< A > &lhs, const T &rhs)
Greater-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:370
constexpr bool operator>=(const NegativeAccuracy< A > &, const T &rhs)
Greater-or-equal-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:446
decltype(auto) trunc(const DenseMatrix< MT, SO > &dm)
Applies the trunc() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1268
constexpr bool operator==(const NegativeAccuracy< A > &lhs, const T &rhs)
Equality comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:253
Header file for the trunc shim.
decltype(auto) atan(const DenseMatrix< MT, SO > &dm)
Computes the inverse tangent for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2070
Header file for the pow2 shim.
Header file for the sin shim.
decltype(auto) asinh(const DenseMatrix< MT, SO > &dm)
Computes the inverse hyperbolic sine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1896
Header file for the invsqrt shim.
bool isnan(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is not a number.
Definition: DiagonalProxy.h:717
Header file for the SparseMatrixProxy class.
constexpr bool IsProxy_v
Auxiliary variable template for the IsProxy type trait.The IsProxy_v variable template provides a con...
Definition: IsProxy.h:143
Header file for the exception macros of the math module.
decltype(auto) max(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise maximum of the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1198
decltype(auto) atan2(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the multi-valued inverse tangent of the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1307
constexpr bool operator!=(const NegativeAccuracy< A > &lhs, const T &rhs)
Inequality comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:293
Header file for the erfc shim.
Header file for the IsVector type trait.
Header file for the IsDenseMatrix type trait.
decltype(auto) exp(const DenseMatrix< MT, SO > &dm)
Computes for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1632
Header file for the pow3 shim.
decltype(auto) abs(const DenseMatrix< MT, SO > &dm)
Applies the abs() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1156
decltype(auto) pow3(const Proxy< PT, RT > &proxy)
Computing the cube value of the represented element.
Definition: Proxy.h:1405
Header file for the isOne shim.
decltype(auto) log(const DenseMatrix< MT, SO > &dm)
Computes the natural logarithm for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1719
Header file for the conjugate shim.
Header file for the log shim.
decltype(auto) floor(const DenseMatrix< MT, SO > &dm)
Applies the floor() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1212
decltype(auto) round(const DenseMatrix< MT, SO > &dm)
Applies the round() function to each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1296
decltype(auto) tanh(const DenseMatrix< MT, SO > &dm)
Computes the hyperbolic tangent for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2101
Header file for the pow4 shim.
Header file for the acosh shim.
Header file for the cbrt shim.
decltype(auto) invcbrt(const DenseMatrix< MT, SO > &dm)
Computes the inverse cubic root of each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1541
Header file for the atanh shim.
decltype(auto) atanh(const DenseMatrix< MT, SO > &dm)
Computes the inverse hyperbolic tangent for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2132
decltype(auto) pow2(const Proxy< PT, RT > &proxy)
Computing the square value of the represented element.
Definition: Proxy.h:1384
Header file for the round shim.
decltype(auto) operator<<(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Left-shift operator for the elementwise left-shift of a dense matrix.
Definition: DMatDMatMapExpr.h:1349
Header file for the invcbrt shim.
Header file for the IsProxy type trait.
bool isOne(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is 1.
Definition: DiagonalProxy.h:697
Header file for the exp10 shim.
Header file for the asinh shim.
constexpr bool operator<=(const NegativeAccuracy< A > &, const T &rhs)
Less-or-equal-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:408
Header file for the tanh shim.
Header file for the IsDenseVector type trait.
decltype(auto) trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:765
decltype(auto) sin(const DenseMatrix< MT, SO > &dm)
Computes the sine for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1809
decltype(auto) erfc(const DenseMatrix< MT, SO > &dm)
Computes the complementary error function for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2188
decltype(auto) sqrt(const DenseMatrix< MT, SO > &dm)
Computes the square root of each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1448
decltype(auto) tan(const DenseMatrix< MT, SO > &dm)
Computes the tangent for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:2042
Header file for the IsComplex type trait.
decltype(auto) log10(const DenseMatrix< MT, SO > &dm)
Computes the common logarithm for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1781
Header file for the atan2 shim.
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
typename DisableIf< Condition, T >::Type DisableIf_t
Auxiliary type for the DisableIf class template.The DisableIf_t alias declaration provides a convenie...
Definition: DisableIf.h:138
Header file for the exp shim.
Header file for the real shim.
decltype(auto) conj(const DenseMatrix< MT, SO > &dm)
Returns a matrix containing the complex conjugate of each single element of dm.
Definition: DMatMapExpr.h:1324
Header file for the sinh shim.
decltype(auto) log2(const DenseMatrix< MT, SO > &dm)
Computes the binary logarithm for each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1750
decltype(auto) invsqrt(const DenseMatrix< MT, SO > &dm)
Computes the inverse square root of each single element of the dense matrix dm.
Definition: DMatMapExpr.h:1479
Header file for the isReal shim.
InversionFlag
Inversion flag.The InversionFlag type enumeration represents the different types of matrix inversion ...
Definition: InversionFlag.h:101
Header file for the atan shim.
bool equal(const SharedValue< T1 > &lhs, const SharedValue< T2 > &rhs)
Equality check for a two shared values.
Definition: SharedValue.h:342
Header file for the ceil shim.
void transpose(Matrix< MT, SO > &matrix)
In-place transpose of the given matrix.
Definition: Matrix.h:825
constexpr Type & get(StaticVector< Type, N, TF > &v) noexcept
Tuple-like index-based access the contents of a static vector.
Definition: StaticVector.h:2704