CppADCodeGen  2.4.3
A C++ Algorithmic Differentiation Package with Source Code Generation
language_c_float.hpp
1 #ifndef CPPAD_CG_LANGUAGE_C_FLOAT_INCLUDED
2 #define CPPAD_CG_LANGUAGE_C_FLOAT_INCLUDED
3 /* --------------------------------------------------------------------------
4  * CppADCodeGen: C++ Algorithmic Differentiation with Source Code Generation:
5  * Copyright (C) 2015 Ciengis
6  *
7  * CppADCodeGen is distributed under multiple licenses:
8  *
9  * - Eclipse Public License Version 1.0 (EPL1), and
10  * - GNU General Public License Version 3 (GPL3).
11  *
12  * EPL1 terms and conditions can be found in the file "epl-v10.txt", while
13  * terms and conditions for the GPL3 can be found in the file "gpl3.txt".
14  * ----------------------------------------------------------------------------
15  * Author: Joao Leal
16  */
17 
18 namespace CppAD {
19 namespace cg {
20 
26 template<>
27 inline const std::string& LanguageC<float>::absFuncName() {
28  static const std::string name("fabsf"); // C99
29  return name;
30 }
31 
32 template<>
33 inline const std::string& LanguageC<float>::acosFuncName() {
34  static const std::string name("acosf"); // C99
35  return name;
36 }
37 
38 template<>
39 inline const std::string& LanguageC<float>::asinFuncName() {
40  static const std::string name("asinf"); // C99
41  return name;
42 }
43 
44 template<>
45 inline const std::string& LanguageC<float>::atanFuncName() {
46  static const std::string name("atanf"); // C99
47  return name;
48 }
49 
50 template<>
51 inline const std::string& LanguageC<float>::coshFuncName() {
52  static const std::string name("coshf"); // C99
53  return name;
54 }
55 
56 template<>
57 inline const std::string& LanguageC<float>::cosFuncName() {
58  static const std::string name("cosf"); // C99
59  return name;
60 }
61 
62 template<>
63 inline const std::string& LanguageC<float>::expFuncName() {
64  static const std::string name("expf"); // C99
65  return name;
66 }
67 
68 template<>
69 inline const std::string& LanguageC<float>::logFuncName() {
70  static const std::string name("logf"); // C99
71  return name;
72 }
73 
74 template<>
75 inline const std::string& LanguageC<float>::sinhFuncName() {
76  static const std::string name("sinhf"); // C99
77  return name;
78 }
79 
80 template<>
81 inline const std::string& LanguageC<float>::sinFuncName() {
82  static const std::string name("sinf"); // C99
83  return name;
84 }
85 
86 template<>
87 inline const std::string& LanguageC<float>::sqrtFuncName() {
88  static const std::string name("sqrtf"); // C99
89  return name;
90 }
91 
92 template<>
93 inline const std::string& LanguageC<float>::tanhFuncName() {
94  static const std::string name("tanhf"); // C99
95  return name;
96 }
97 
98 template<>
99 inline const std::string& LanguageC<float>::tanFuncName() {
100  static const std::string name("tanf"); // C99
101  return name;
102 }
103 
104 #if CPPAD_USE_CPLUSPLUS_2011
105 template<>
106 inline const std::string& LanguageC<float>::erfFuncName() {
107  static const std::string name("erff"); // C99
108  return name;
109 }
110 
111 template<>
112 inline const std::string& LanguageC<float>::asinhFuncName() {
113  static const std::string name("asinhf"); // C99
114  return name;
115 }
116 
117 template<>
118 inline const std::string& LanguageC<float>::acoshFuncName() {
119  static const std::string name("acoshf"); // C99
120  return name;
121 }
122 
123 template<>
124 inline const std::string& LanguageC<float>::atanhFuncName() {
125  static const std::string name("atanhf"); // C99
126  return name;
127 }
128 
129 template<>
130 inline const std::string& LanguageC<float>::expm1FuncName() {
131  static const std::string name("expm1f"); // C99
132  return name;
133 }
134 
135 template<>
136 inline const std::string& LanguageC<float>::log1pFuncName() {
137  static const std::string name("log1pf"); // C99
138  return name;
139 }
140 
141 #endif
142 
143 template<>
144 inline const std::string& LanguageC<float>::getPrintfBaseFormat() {
145  static const std::string format("%f");
146  return format;
147 }
148 
149 } // END cg namespace
150 } // END CppAD namespace
151 
152 #endif
CppAD
Definition: abstract_atomic_fun.hpp:19