numerix_doc 0.4
|
00001 00002 #include <numerix/integer.hpp> 00003 #include <numerix/rational.hpp> 00004 #include <numerix/floating.hpp> 00005 #include <basix/double.hpp> 00006 #include <numerix/complex.hpp> 00007 #include <numerix/complex_double.hpp> 00008 #include <numerix/ball.hpp> 00009 #include <numerix/ball_complex.hpp> 00010 #include <basix/glue.hpp> 00011 00012 #define double_literal(x) as_double (as_string (x)) 00013 00014 namespace mmx { 00015 static mmx_ball(mmx_floating, mmx_floating) 00016 GLUE_1 (const mmx_floating &arg_1) { 00017 return make_mmx_ball (arg_1); 00018 } 00019 00020 static mmx_ball(mmx_floating, mmx_floating) 00021 GLUE_2 (const mmx_floating &arg_1, const mmx_floating &arg_2) { 00022 return make_mmx_ball (arg_1, arg_2); 00023 } 00024 00025 static mmx_ball(mmx_floating, mmx_floating) 00026 GLUE_3 (const mmx_floating &arg_1) { 00027 return make_mmx_ball (arg_1); 00028 } 00029 00030 static mmx_floating 00031 GLUE_4 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00032 return center (arg_1); 00033 } 00034 00035 static mmx_floating 00036 GLUE_5 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00037 return mmx_radius (arg_1); 00038 } 00039 00040 static mmx_ball(mmx_floating, mmx_floating) 00041 GLUE_6 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00042 return sharpen (arg_1); 00043 } 00044 00045 static mmx_ball(mmx_floating, mmx_floating) 00046 GLUE_7 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00047 return blur (arg_1, arg_2); 00048 } 00049 00050 static bool 00051 GLUE_8 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00052 return included (arg_1, arg_2); 00053 } 00054 00055 static mmx_ball(mmx_floating, mmx_floating) 00056 GLUE_9 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00057 return -arg_1; 00058 } 00059 00060 static mmx_ball(mmx_floating, mmx_floating) 00061 GLUE_10 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00062 return square (arg_1); 00063 } 00064 00065 static mmx_ball(mmx_floating, mmx_floating) 00066 GLUE_11 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00067 return arg_1 + arg_2; 00068 } 00069 00070 static mmx_ball(mmx_floating, mmx_floating) 00071 GLUE_12 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00072 return arg_1 - arg_2; 00073 } 00074 00075 static mmx_ball(mmx_floating, mmx_floating) 00076 GLUE_13 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00077 return arg_1 * arg_2; 00078 } 00079 00080 static mmx_ball(mmx_floating, mmx_floating) 00081 GLUE_14 (const mmx_floating &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00082 return arg_1 + arg_2; 00083 } 00084 00085 static mmx_ball(mmx_floating, mmx_floating) 00086 GLUE_15 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_floating &arg_2) { 00087 return arg_1 + arg_2; 00088 } 00089 00090 static mmx_ball(mmx_floating, mmx_floating) 00091 GLUE_16 (const mmx_floating &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00092 return arg_1 - arg_2; 00093 } 00094 00095 static mmx_ball(mmx_floating, mmx_floating) 00096 GLUE_17 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_floating &arg_2) { 00097 return arg_1 - arg_2; 00098 } 00099 00100 static mmx_ball(mmx_floating, mmx_floating) 00101 GLUE_18 (const mmx_floating &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00102 return arg_1 * arg_2; 00103 } 00104 00105 static mmx_ball(mmx_floating, mmx_floating) 00106 GLUE_19 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_floating &arg_2) { 00107 return arg_1 * arg_2; 00108 } 00109 00110 static mmx_ball(mmx_floating, mmx_floating) 00111 GLUE_20 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00112 return arg_1 / arg_2; 00113 } 00114 00115 static mmx_ball(mmx_floating, mmx_floating) 00116 GLUE_21 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_floating &arg_2) { 00117 return arg_1 / arg_2; 00118 } 00119 00120 static mmx_ball(mmx_floating, mmx_floating) 00121 GLUE_22 (const mmx_floating &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00122 return arg_1 / arg_2; 00123 } 00124 00125 static bool 00126 GLUE_23 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00127 return is_finite (arg_1); 00128 } 00129 00130 static bool 00131 GLUE_24 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00132 return is_infinite (arg_1); 00133 } 00134 00135 static bool 00136 GLUE_25 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00137 return is_nan (arg_1); 00138 } 00139 00140 static mmx_ball(mmx_floating, mmx_floating) 00141 GLUE_26 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00142 return times_infinity (arg_1); 00143 } 00144 00145 static int 00146 GLUE_27 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00147 return precision (arg_1); 00148 } 00149 00150 static int 00151 GLUE_28 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00152 return exponent (arg_1); 00153 } 00154 00155 static double 00156 GLUE_29 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00157 return magnitude (arg_1); 00158 } 00159 00160 static mmx_ball(mmx_floating, mmx_floating) 00161 GLUE_30 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const int &arg_2) { 00162 return incexp2 (arg_1, arg_2); 00163 } 00164 00165 static mmx_ball(mmx_floating, mmx_floating) 00166 GLUE_31 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const int &arg_2) { 00167 return decexp2 (arg_1, arg_2); 00168 } 00169 00170 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00171 GLUE_32 (const complex<mmx_floating> &arg_1) { 00172 return make_mmx_ball (arg_1); 00173 } 00174 00175 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00176 GLUE_33 (const complex<mmx_floating> &arg_1, const mmx_floating &arg_2) { 00177 return make_mmx_ball (arg_1, arg_2); 00178 } 00179 00180 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00181 GLUE_34 (const complex<mmx_floating> &arg_1) { 00182 return make_mmx_ball (arg_1); 00183 } 00184 00185 static complex<mmx_floating> 00186 GLUE_35 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00187 return center (arg_1); 00188 } 00189 00190 static mmx_floating 00191 GLUE_36 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00192 return mmx_radius (arg_1); 00193 } 00194 00195 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00196 GLUE_37 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00197 return sharpen (arg_1); 00198 } 00199 00200 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00201 GLUE_38 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00202 return blur (arg_1, arg_2); 00203 } 00204 00205 static bool 00206 GLUE_39 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00207 return included (arg_1, arg_2); 00208 } 00209 00210 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00211 GLUE_40 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00212 return -arg_1; 00213 } 00214 00215 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00216 GLUE_41 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00217 return square (arg_1); 00218 } 00219 00220 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00221 GLUE_42 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00222 return arg_1 + arg_2; 00223 } 00224 00225 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00226 GLUE_43 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00227 return arg_1 - arg_2; 00228 } 00229 00230 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00231 GLUE_44 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00232 return arg_1 * arg_2; 00233 } 00234 00235 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00236 GLUE_45 (const complex<mmx_floating> &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00237 return arg_1 + arg_2; 00238 } 00239 00240 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00241 GLUE_46 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const complex<mmx_floating> &arg_2) { 00242 return arg_1 + arg_2; 00243 } 00244 00245 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00246 GLUE_47 (const complex<mmx_floating> &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00247 return arg_1 - arg_2; 00248 } 00249 00250 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00251 GLUE_48 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const complex<mmx_floating> &arg_2) { 00252 return arg_1 - arg_2; 00253 } 00254 00255 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00256 GLUE_49 (const complex<mmx_floating> &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00257 return arg_1 * arg_2; 00258 } 00259 00260 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00261 GLUE_50 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const complex<mmx_floating> &arg_2) { 00262 return arg_1 * arg_2; 00263 } 00264 00265 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00266 GLUE_51 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00267 return arg_1 / arg_2; 00268 } 00269 00270 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00271 GLUE_52 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const complex<mmx_floating> &arg_2) { 00272 return arg_1 / arg_2; 00273 } 00274 00275 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00276 GLUE_53 (const complex<mmx_floating> &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00277 return arg_1 / arg_2; 00278 } 00279 00280 static mmx_ball(mmx_floating, mmx_floating) 00281 GLUE_54 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00282 return sqrt (arg_1); 00283 } 00284 00285 static mmx_ball(mmx_floating, mmx_floating) 00286 GLUE_55 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00287 return exp (arg_1); 00288 } 00289 00290 static mmx_ball(mmx_floating, mmx_floating) 00291 GLUE_56 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00292 return log (arg_1); 00293 } 00294 00295 static mmx_ball(mmx_floating, mmx_floating) 00296 GLUE_57 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00297 return pow (arg_1, arg_2); 00298 } 00299 00300 static mmx_ball(mmx_floating, mmx_floating) 00301 GLUE_58 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00302 return cos (arg_1); 00303 } 00304 00305 static mmx_ball(mmx_floating, mmx_floating) 00306 GLUE_59 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00307 return sin (arg_1); 00308 } 00309 00310 static mmx_ball(mmx_floating, mmx_floating) 00311 GLUE_60 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00312 return tan (arg_1); 00313 } 00314 00315 static mmx_ball(mmx_floating, mmx_floating) 00316 GLUE_61 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00317 return acos (arg_1); 00318 } 00319 00320 static mmx_ball(mmx_floating, mmx_floating) 00321 GLUE_62 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00322 return asin (arg_1); 00323 } 00324 00325 static mmx_ball(mmx_floating, mmx_floating) 00326 GLUE_63 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00327 return atan (arg_1); 00328 } 00329 00330 static bool 00331 GLUE_64 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00332 return arg_1 < arg_2; 00333 } 00334 00335 static bool 00336 GLUE_65 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00337 return arg_1 > arg_2; 00338 } 00339 00340 static bool 00341 GLUE_66 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00342 return arg_1 <= arg_2; 00343 } 00344 00345 static bool 00346 GLUE_67 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00347 return arg_1 >= arg_2; 00348 } 00349 00350 static mmx_ball(mmx_floating, mmx_floating) 00351 GLUE_68 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00352 return abs (arg_1); 00353 } 00354 00355 static mmx_ball(mmx_floating, mmx_floating) 00356 GLUE_69 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00357 return min (arg_1, arg_2); 00358 } 00359 00360 static mmx_ball(mmx_floating, mmx_floating) 00361 GLUE_70 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00362 return max (arg_1, arg_2); 00363 } 00364 00365 static mmx_ball(mmx_floating, mmx_floating) 00366 GLUE_71 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00367 return floor (arg_1); 00368 } 00369 00370 static mmx_ball(mmx_floating, mmx_floating) 00371 GLUE_72 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00372 return ceil (arg_1); 00373 } 00374 00375 static mmx_ball(mmx_floating, mmx_floating) 00376 GLUE_73 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00377 return trunc (arg_1); 00378 } 00379 00380 static mmx_ball(mmx_floating, mmx_floating) 00381 GLUE_74 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00382 return round (arg_1); 00383 } 00384 00385 static mmx_ball(mmx_floating, mmx_floating) 00386 GLUE_75 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00387 return Re (arg_1); 00388 } 00389 00390 static mmx_ball(mmx_floating, mmx_floating) 00391 GLUE_76 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00392 return Im (arg_1); 00393 } 00394 00395 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00396 GLUE_77 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00397 return conj (arg_1); 00398 } 00399 00400 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00401 GLUE_78 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00402 return times_i (arg_1); 00403 } 00404 00405 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00406 GLUE_79 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00407 return over_i (arg_1); 00408 } 00409 00410 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00411 GLUE_80 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00412 return gaussian (arg_1); 00413 } 00414 00415 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00416 GLUE_81 (const mmx_ball(mmx_floating, mmx_floating) &arg_1, const mmx_ball(mmx_floating, mmx_floating) &arg_2) { 00417 return gaussian (arg_1, arg_2); 00418 } 00419 00420 static mmx_ball(mmx_floating, mmx_floating) 00421 GLUE_82 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00422 return abs (arg_1); 00423 } 00424 00425 static mmx_ball(mmx_floating, mmx_floating) 00426 GLUE_83 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00427 return arg (arg_1); 00428 } 00429 00430 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00431 GLUE_84 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00432 return sqrt (arg_1); 00433 } 00434 00435 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00436 GLUE_85 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00437 return exp (arg_1); 00438 } 00439 00440 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00441 GLUE_86 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00442 return log (arg_1); 00443 } 00444 00445 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00446 GLUE_87 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_2) { 00447 return pow (arg_1, arg_2); 00448 } 00449 00450 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00451 GLUE_88 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00452 return cos (arg_1); 00453 } 00454 00455 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00456 GLUE_89 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00457 return sin (arg_1); 00458 } 00459 00460 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00461 GLUE_90 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00462 return tan (arg_1); 00463 } 00464 00465 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00466 GLUE_91 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00467 return acos (arg_1); 00468 } 00469 00470 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00471 GLUE_92 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00472 return asin (arg_1); 00473 } 00474 00475 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00476 GLUE_93 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00477 return atan (arg_1); 00478 } 00479 00480 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00481 GLUE_94 (const mmx_ball(mmx_floating, mmx_floating) &arg_1) { 00482 return as<mmx_ball(mmx_floating, complex<mmx_floating> ) > (arg_1); 00483 } 00484 00485 static bool 00486 GLUE_95 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00487 return is_finite (arg_1); 00488 } 00489 00490 static bool 00491 GLUE_96 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00492 return is_infinite (arg_1); 00493 } 00494 00495 static bool 00496 GLUE_97 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00497 return is_nan (arg_1); 00498 } 00499 00500 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00501 GLUE_98 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00502 return times_infinity (arg_1); 00503 } 00504 00505 static int 00506 GLUE_99 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00507 return precision (arg_1); 00508 } 00509 00510 static int 00511 GLUE_100 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00512 return exponent (arg_1); 00513 } 00514 00515 static double 00516 GLUE_101 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1) { 00517 return magnitude (arg_1); 00518 } 00519 00520 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00521 GLUE_102 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const int &arg_2) { 00522 return incexp2 (arg_1, arg_2); 00523 } 00524 00525 static mmx_ball(mmx_floating, complex<mmx_floating> ) 00526 GLUE_103 (const mmx_ball(mmx_floating, complex<mmx_floating> ) &arg_1, const int &arg_2) { 00527 return decexp2 (arg_1, arg_2); 00528 } 00529 00530 void 00531 glue_ball_floating () { 00532 static bool done = false; 00533 if (done) return; 00534 done = true; 00535 call_glue (string ("glue_complex_floating")); 00536 call_glue (string ("glue_ball_double")); 00537 define_type<mmx_ball(mmx_floating, mmx_floating) > (gen (lit ("Ball"), lit ("Floating"), lit ("Floating"))); 00538 define_type<mmx_ball(mmx_floating, complex<mmx_floating> ) > (gen (lit ("Ball"), lit ("Floating"), gen (lit ("Complex"), lit ("Floating")))); 00539 define ("ball", GLUE_1); 00540 define ("ball", GLUE_2); 00541 define_converter ("upgrade", GLUE_3, PENALTY_INCLUSION); 00542 define ("center", GLUE_4); 00543 define ("radius", GLUE_5); 00544 define ("sharpen", GLUE_6); 00545 define ("blur", GLUE_7); 00546 define ("included?", GLUE_8); 00547 define ("-", GLUE_9); 00548 define ("square", GLUE_10); 00549 define ("+", GLUE_11); 00550 define ("-", GLUE_12); 00551 define ("*", GLUE_13); 00552 define ("+", GLUE_14); 00553 define ("+", GLUE_15); 00554 define ("-", GLUE_16); 00555 define ("-", GLUE_17); 00556 define ("*", GLUE_18); 00557 define ("*", GLUE_19); 00558 define ("/", GLUE_20); 00559 define ("/", GLUE_21); 00560 define ("/", GLUE_22); 00561 define ("finite?", GLUE_23); 00562 define ("infinite?", GLUE_24); 00563 define ("nan?", GLUE_25); 00564 define ("times_infinity", GLUE_26); 00565 define ("precision", GLUE_27); 00566 define ("exponent", GLUE_28); 00567 define ("magnitude", GLUE_29); 00568 define ("increase_exponent", GLUE_30); 00569 define ("decrease_exponent", GLUE_31); 00570 define ("ball", GLUE_32); 00571 define ("ball", GLUE_33); 00572 define_converter ("upgrade", GLUE_34, PENALTY_INCLUSION); 00573 define ("center", GLUE_35); 00574 define ("radius", GLUE_36); 00575 define ("sharpen", GLUE_37); 00576 define ("blur", GLUE_38); 00577 define ("included?", GLUE_39); 00578 define ("-", GLUE_40); 00579 define ("square", GLUE_41); 00580 define ("+", GLUE_42); 00581 define ("-", GLUE_43); 00582 define ("*", GLUE_44); 00583 define ("+", GLUE_45); 00584 define ("+", GLUE_46); 00585 define ("-", GLUE_47); 00586 define ("-", GLUE_48); 00587 define ("*", GLUE_49); 00588 define ("*", GLUE_50); 00589 define ("/", GLUE_51); 00590 define ("/", GLUE_52); 00591 define ("/", GLUE_53); 00592 define ("sqrt", GLUE_54); 00593 define ("exp", GLUE_55); 00594 define ("log", GLUE_56); 00595 define ("^", GLUE_57); 00596 define ("cos", GLUE_58); 00597 define ("sin", GLUE_59); 00598 define ("tan", GLUE_60); 00599 define ("arccos", GLUE_61); 00600 define ("arcsin", GLUE_62); 00601 define ("arctan", GLUE_63); 00602 define ("<", GLUE_64); 00603 define (">", GLUE_65); 00604 define ("<=", GLUE_66); 00605 define (">=", GLUE_67); 00606 define ("abs", GLUE_68); 00607 define ("min", GLUE_69); 00608 define ("max", GLUE_70); 00609 define ("floor", GLUE_71); 00610 define ("ceil", GLUE_72); 00611 define ("trunc", GLUE_73); 00612 define ("round", GLUE_74); 00613 define ("Re", GLUE_75); 00614 define ("Im", GLUE_76); 00615 define ("conj", GLUE_77); 00616 define ("times_i", GLUE_78); 00617 define ("over_i", GLUE_79); 00618 define ("complex", GLUE_80); 00619 define ("complex", GLUE_81); 00620 define ("abs", GLUE_82); 00621 define ("arg", GLUE_83); 00622 define ("sqrt", GLUE_84); 00623 define ("exp", GLUE_85); 00624 define ("log", GLUE_86); 00625 define ("^", GLUE_87); 00626 define ("cos", GLUE_88); 00627 define ("sin", GLUE_89); 00628 define ("tan", GLUE_90); 00629 define ("arccos", GLUE_91); 00630 define ("arcsin", GLUE_92); 00631 define ("arctan", GLUE_93); 00632 define_converter (":>", GLUE_94, PENALTY_HOMOMORPHISM); 00633 define ("finite?", GLUE_95); 00634 define ("infinite?", GLUE_96); 00635 define ("nan?", GLUE_97); 00636 define ("times_infinity", GLUE_98); 00637 define ("precision", GLUE_99); 00638 define ("exponent", GLUE_100); 00639 define ("magnitude", GLUE_101); 00640 define ("increase_exponent", GLUE_102); 00641 define ("decrease_exponent", GLUE_103); 00642 } 00643 }