NeoPZ
tinyfadlog.h
Go to the documentation of this file.
1 // Emacs will be in -*- Mode: c++ -*-
2 //
3 // ********** DO NOT REMOVE THIS BANNER **********
4 //
5 // SUMMARY: Tools for Automatic Differentiaton (order 1)
6 // RELEASE: 0.1
7 // USAGE : You may copy freely these files and use it for
8 // teaching or research. These or part of these may
9 // not be sold or used for a commercial purpose with-
10 // out our consent : fax (33)1 44 27 72 00
11 //
12 // AUTHOR : Nicolas Di cesare
13 // ORG :
14 // E-MAIL : Nicolas.Dicesare@ann.jussieu.fr
15 //
16 // ORIG-DATE: September 97
17 // LAST-MOD : 28/07/98
18 // ********************************************************
19 // FILE : tinyfadlog.h
20 // ********************************************************
21 #ifndef _tinyfadlog_h_
22 #define _tinyfadlog_h_
23 
24 
25 
26 template <int Num, class T> inline
27 bool operator != (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
28  return x.val() != y.val();
29 }
30 
31 template <int Num, class T> inline
32 bool operator != (const T& x, const TinyFad<Num,T>& y) {
33  return x != y.val();
34 }
35 
36 template <int Num, class T> inline
37 bool operator != (const TinyFad<Num,T>& x, const T& y) {
38  return x.val() != y;
39 }
40 
41 
42 template <int Num, class T> inline
43 bool operator == (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
44  return x.val() == y.val();
45 }
46 
47 template <int Num, class T> inline
48 bool operator == (const T& x, const TinyFad<Num,T>& y) {
49  return x == y.val();
50 }
51 
52 template <int Num, class T> inline
53 bool operator == (const TinyFad<Num,T>& x, const T& y) {
54  return x.val() == y;
55 }
56 
57 template <int Num, class T> inline
58 bool operator > (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
59  return x.val() > y.val();
60 }
61 
62 template <int Num, class T> inline
63 bool operator > (const T& x, const TinyFad<Num,T>& y) {
64  return x > y.val();
65 }
66 
67 template <int Num, class T> inline
68 bool operator > (const TinyFad<Num,T>& x, const T& y) {
69  return x.val() > y;
70 }
71 
72 
73 template <int Num, class T> inline
74 bool operator < (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
75  return x.val() < y.val();
76 }
77 
78 template <int Num, class T> inline
79 bool operator < (const T& x, const TinyFad<Num,T>& y) {
80  return x < y.val();
81 }
82 
83 template <int Num, class T> inline
84 bool operator < (const TinyFad<Num,T>& x, const T& y) {
85  return x.val() < y;
86 }
87 
88 template <int Num, class T> inline
89 bool operator >= (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
90  return x.val() >= y.val();
91 }
92 
93 template <int Num, class T> inline
94 bool operator >= (const T& x, const TinyFad<Num,T>& y) {
95  return x >= y.val();
96 }
97 
98 template <int Num, class T> inline
99 bool operator >= (const TinyFad<Num,T>& x, const T& y) {
100  return x.val() >= y;
101 }
102 
103 
104 template <int Num, class T> inline
105 bool operator <= (const TinyFad<Num,T>& x, const TinyFad<Num,T>& y) {
106  return x.val() <= y.val();
107 }
108 
109 template <int Num, class T> inline
110 bool operator <= (const T& x, const TinyFad<Num,T>& y) {
111  return x <= y.val();
112 }
113 
114 template <int Num, class T> inline
115 bool operator <= (const TinyFad<Num,T>& x, const T& y) {
116  return x.val() <= y;
117 }
118 
119 
120 #endif
bool operator!=(const TinyFad< Num, T > &x, const TinyFad< Num, T > &y)
Definition: tinyfadlog.h:27
bool operator>=(const TinyFad< Num, T > &x, const TinyFad< Num, T > &y)
Definition: tinyfadlog.h:89
bool operator==(const TinyFad< Num, T > &x, const TinyFad< Num, T > &y)
Definition: tinyfadlog.h:43
const T & val() const
Definition: tinyfad.h:72
bool operator>(const TinyFad< Num, T > &x, const TinyFad< Num, T > &y)
Definition: tinyfadlog.h:58