Home
last modified time | relevance | path

Searched refs:copysign (Results 1 – 25 of 176) sorted by relevance

12345678

/third_party/python/Lib/test/decimaltestdata/
Dcopysign.decTest2 -- copysign.decTest -- quiet copy with sign from rhs --
29 cpsx001 copysign +7.50 11 -> 7.50
30 cpsx002 copysign '1.50' '7.33' -> 1.50
31 cpsx003 copysign '-1.50' '7.33' -> 1.50
32 cpsx004 copysign '1.50' '-7.33' -> -1.50
33 cpsx005 copysign '-1.50' '-7.33' -> -1.50
36 cpsx011 copysign Infinity 11 -> Infinity
37 cpsx012 copysign -Infinity 11 -> Infinity
40 cpsx021 copysign NaN 11 -> NaN
41 cpsx022 copysign -NaN 11 -> NaN
[all …]
DddCopySign.decTest31 ddcps001 copysign +7.50 11 -> 7.50
34 ddcps011 copysign Infinity 11 -> Infinity
35 ddcps012 copysign -Infinity 11 -> Infinity
38 ddcps021 copysign NaN 11 -> NaN
39 ddcps022 copysign -NaN 11 -> NaN
40 ddcps023 copysign sNaN 11 -> sNaN
41 ddcps024 copysign -sNaN 11 -> sNaN
44 ddcps031 copysign NaN10 11 -> NaN10
45 ddcps032 copysign -NaN10 11 -> NaN10
46 ddcps033 copysign sNaN10 11 -> sNaN10
[all …]
DdqCopySign.decTest31 dqcps001 copysign +7.50 11 -> 7.50
34 dqcps011 copysign Infinity 11 -> Infinity
35 dqcps012 copysign -Infinity 11 -> Infinity
38 dqcps021 copysign NaN 11 -> NaN
39 dqcps022 copysign -NaN 11 -> NaN
40 dqcps023 copysign sNaN 11 -> sNaN
41 dqcps024 copysign -sNaN 11 -> sNaN
44 dqcps031 copysign NaN10 11 -> NaN10
45 dqcps032 copysign -NaN10 11 -> NaN10
46 dqcps033 copysign sNaN10 11 -> sNaN10
[all …]
DddCanonical.decTest242 ddcan280 copysign #77ffff3fcff3fcff -1 -> #f7ffff3fcff3fcff
243 ddcan281 copysign #77fcff3fdff3fcff 1 -> #77fcff3fdff3fcff
245 ddcan282 copysign #7c03ff3fcff3fcff -1 -> #fc03ff3fcff3fcff
246 ddcan283 copysign #7c00ff3fcff3ffff 1 -> #7c00ff3fcff3ffff
247 ddcan284 copysign #7d00ff3fcff3fcff -1 -> #fd00ff3fcff3fcff
248 ddcan285 copysign #7c04ff3fcff3fcff 1 -> #7c04ff3fcff3fcff
250 ddcan286 copysign #7e00ff3fcffffcff -1 -> #fe00ff3fcffffcff
251 ddcan287 copysign #7e40ff3fcff3fcff 1 -> #7e40ff3fcff3fcff
253 ddcan288 copysign #7a00000000000000 -1 -> #fa00000000000000
254 ddcan289 copysign #7800200000000000 1 -> #7800200000000000
DdqCanonical.decTest267 dqcan280 copysign #6e080ff3fcff3fcfffffff3fcfffffff -1 -> #ee080ff3fcff3fcfffffff3fcfffffff
268 dqcan281 copysign #ee080ff3fcff3ffff3fcff3ffff3fcff 1 -> #6e080ff3fcff3ffff3fcff3ffff3fcff
270 dqcan282 copysign #7c000ff3fcffffffffffffffcff3fcff -1 -> #fc000ff3fcffffffffffffffcff3fcff
271 dqcan283 copysign #7c080ff3fcff3fcff3fcff3fcff3fcff 1 -> #7c080ff3fcff3fcff3fcff3fcff3fcff
273 dqcan284 copysign #7e003ff3fcffffffffffffffcff3fcff -1 -> #fe003ff3fcffffffffffffffcff3fcff
274 dqcan285 copysign #7e100ff3fcff3fcff3fcff3fcff3fcff 1 -> #7e100ff3fcff3fcff3fcff3fcff3fcff
276 dqcan288 copysign #78002000000000000000000000000000 -1 -> #f8002000000000000000000000000000
277 dqcan289 copysign #78000000000010000000000000100000 1 -> #78000000000010000000000000100000
/third_party/boost/libs/math/test/
Dtest_sign.cpp37 (boost::math::copysign)(b, (boost::math::signbit)(b) ? RealType(1.) : RealType(-1.) )); in test_spots()
40 BOOST_CHECK_EQUAL((boost::math::copysign)(b, a), RealType(1)); in test_spots()
41 BOOST_CHECK_EQUAL((boost::math::copysign)(c, a), RealType(1)); in test_spots()
45 BOOST_CHECK_EQUAL((boost::math::copysign)(b, a), RealType(1)); in test_spots()
46 BOOST_CHECK_EQUAL((boost::math::copysign)(c, a), RealType(1)); in test_spots()
50 BOOST_CHECK_EQUAL((boost::math::copysign)(b, a), RealType(-1)); in test_spots()
51 BOOST_CHECK_EQUAL((boost::math::copysign)(c, a), RealType(-1)); in test_spots()
55 BOOST_CHECK_EQUAL((boost::math::copysign)(b, a), RealType(1)); in test_spots()
56 BOOST_CHECK_EQUAL((boost::math::copysign)(c, a), RealType(1)); in test_spots()
60 BOOST_CHECK_EQUAL((boost::math::copysign)(b, a), RealType(-1)); in test_spots()
[all …]
Dtest_cstdfloat.cpp222 BOOST_CHECK_EQUAL(std::copysign(val, s), 3); in test()
223 BOOST_CHECK_EQUAL(std::copysign(val, s * -2), -3); in test()
224 BOOST_CHECK_EQUAL(std::copysign(-2 * val, s), 6); in test()
225 BOOST_CHECK_EQUAL(std::copysign(-2 * val, 2 * s), 6); in test()
227 BOOST_CHECK_EQUAL(std::copysign(val, s), -3); in test()
228 BOOST_CHECK_EQUAL(std::copysign(val, s * -2), 3); in test()
229 BOOST_CHECK_EQUAL(std::copysign(-2 * val, s), -6); in test()
230 BOOST_CHECK_EQUAL(std::copysign(-2 * val, 2 * s), -6); in test()
232 BOOST_CHECK_EQUAL(std::copysign(val, s), -3); in test()
233 BOOST_CHECK_EQUAL(std::copysign(val, s * -2), 3); in test()
[all …]
/third_party/boost/libs/multiprecision/test/
Dtest_fpclassify.cpp321 BOOST_CHECK((::boost::math::signbit)(boost::math::copysign(one, one)) == 0); in test()
322 BOOST_CHECK_EQUAL(boost::math::copysign(one, one), one); in test()
323 BOOST_CHECK((::boost::math::signbit)(boost::math::copysign(one, minus_one)) > 0); in test()
324 BOOST_CHECK_EQUAL(boost::math::copysign(one, minus_one), minus_one); in test()
325 BOOST_CHECK((::boost::math::signbit)(boost::math::copysign(minus_one, one)) == 0); in test()
326 BOOST_CHECK_EQUAL(boost::math::copysign(minus_one, one), one); in test()
327 BOOST_CHECK((::boost::math::signbit)(boost::math::copysign(minus_one, minus_one)) > 0); in test()
328 BOOST_CHECK_EQUAL(boost::math::copysign(minus_one, minus_one), minus_one); in test()
329 BOOST_CHECK((::boost::math::signbit)(boost::math::copysign(one + 1, one + 2)) == 0); in test()
330 BOOST_CHECK_EQUAL(boost::math::copysign(one + 1, one + 2), 2); in test()
[all …]
/third_party/flutter/skia/third_party/externals/sdl/src/libm/
Ds_copysign.c27 libm_hidden_proto(copysign) in libm_hidden_proto() argument
29 double copysign(double x, double y) in libm_hidden_proto()
31 double copysign(x, y) in libm_hidden_proto()
42 libm_hidden_def(copysign)
Ds_scalbn.c28 libm_hidden_proto(copysign)
63 return huge_val * copysign(huge_val, x); /* overflow */
70 return huge_val * copysign(huge_val, x); /* overflow */
72 return tiny * copysign(tiny, x); /* underflow */
/third_party/musl/src/complex/
Dccosh.c66 return CMPLX(h * cos(y), copysign(h, x) * sin(y)); in ccosh()
70 return CMPLX(creal(z), cimag(z) * copysign(1, x)); in ccosh()
88 return CMPLX(y - y, copysign(0, x * (y - y))); in ccosh()
98 return CMPLX(x * x, copysign(0, x) * y); in ccosh()
99 return CMPLX(x * x, copysign(0, (x + x) * y)); in ccosh()
Dcsinh.c66 return CMPLX(copysign(h, x) * cos(y), h * sin(y)); in csinh()
70 return CMPLX(creal(z) * copysign(1, x), cimag(z)); in csinh()
88 return CMPLX(copysign(0, x * (y - y)), y - y); in csinh()
98 return CMPLX(x, copysign(0, y)); in csinh()
Dcsqrt.c69 return CMPLX(fabs(b - b), copysign(a, b)); in csqrt()
71 return CMPLX(a, copysign(b - b, b)); in csqrt()
93 result = CMPLX(fabs(b) / (2 * t), copysign(t, b)); in csqrt()
Dctanh.c100 return CMPLX(x, copysign(0, isinf(y) ? y : sin(y) * cos(y))); in ctanh()
119 return CMPLX(copysign(1, x), 4 * sin(y) * cos(y) * exp_mx * exp_mx); in ctanh()
/third_party/python/Modules/
Dcmathmodule.c162 if (copysign(1., d) == 1.) in special_type()
168 if (copysign(1., d) == 1.) in special_type()
176 if (copysign(1., d) == 1.) in special_type()
231 r.imag = -copysign(log(hypot(z.real/2., z.imag/2.)) + in cmath_acos_impl()
234 r.imag = copysign(log(hypot(z.real/2., z.imag/2.)) + in cmath_acos_impl()
325 r.real = copysign(log(hypot(z.real/2., z.imag/2.)) + in cmath_asinh_impl()
328 r.real = -copysign(log(hypot(z.real/2., z.imag/2.)) + in cmath_asinh_impl()
376 if (copysign(1., z.real) == 1.) in c_atan2()
378 return copysign(0.25*Py_MATH_PI, z.imag); in c_atan2()
381 return copysign(0.75*Py_MATH_PI, z.imag); in c_atan2()
[all …]
D_math.c120 return copysign(w, x); in _Py_asinh()
172 return copysign(t, x); in _Py_atanh()
Dmathmodule.c136 return copysign(1.0, x)*r; in m_sinpi()
307 return copysign(Py_HUGE_VAL, x); in m_tgamma()
607 if (copysign(1., x) == 1.) in m_atan2()
609 return copysign(0.25*Py_MATH_PI, y); in m_atan2()
612 return copysign(0.75*Py_MATH_PI, y); in m_atan2()
615 return copysign(0.5*Py_MATH_PI, y); in m_atan2()
618 if (copysign(1., x) == 1.) in m_atan2()
620 return copysign(0., y); in m_atan2()
623 return copysign(Py_MATH_PI, y); in m_atan2()
706 return copysign(1.0, x) * r; in m_remainder()
[all …]
/third_party/boost/libs/math/doc/fp_utilities/
Dsign.qbk18 T copysign (const T& x, const U& y);
40 ``__sf_result`` copysign (const T& x, const U& y);
44 See [@http://www.open-std.org/JTC1/SC22/WG14/www/docs/n1256.pdf C99 7.12.11.1 The copysign function…
59 copysign(x, signbit(x) ? 1.0 : -1.0);
77 specifies `copysign` functions and function templates for accessing the sign bit.
88 copysign(4.2, 7.9) is 4.2
89 copysign(3.5 -1.4) is -3.5
90 copysign(-4.2, 1.0) is 4.2
91 copysign(-8.6, -3.3) is -8.6
/third_party/boost/libs/math/test/compile_test/
Dsf_sign_incl_test.cpp30 check_result<float>(boost::math::copysign<float>(f, f)); in compile_and_link_test()
31 check_result<double>(boost::math::copysign<double>(d, d)); in compile_and_link_test()
33 check_result<long double>(boost::math::copysign<long double>(l, l)); in compile_and_link_test()
/third_party/skia/third_party/externals/oboe/apps/fxlab/app/src/main/cpp/effects/
DSingleFunctionEffects.h30 x = std::copysign((3 - (2 - 3 * abs) * (2 - 3 * abs)) * third, x); in _overdrive()
32 x = std::copysign(1, x); in _overdrive()
45 x = std::copysign(-std::expm1(-std::abs(x)), x); in _distortion()
/third_party/jerryscript/jerry-libm/
Dscalbn.c69 return huge * copysign (huge, x); in scalbn()
82 return huge * copysign (huge, x); /*overflow */ in scalbn()
86 return tiny * copysign (tiny, x); /*underflow */ in scalbn()
/third_party/python/Python/
Dpymath.c59 copysign(double x, double y) in copysign() function
79 return copysign(y, x); in round()
/third_party/python/Lib/test/
Dtest_math.py415 self.assertEqual(math.copysign(1, 42), 1.0)
416 self.assertEqual(math.copysign(0., 42), 0.0)
417 self.assertEqual(math.copysign(1., -42), -1.0)
418 self.assertEqual(math.copysign(3, 0.), 3.0)
419 self.assertEqual(math.copysign(4., -0.), -4.0)
421 self.assertRaises(TypeError, math.copysign)
423 self.assertEqual(math.copysign(1., 0.), 1.)
424 self.assertEqual(math.copysign(1., -0.), -1.)
425 self.assertEqual(math.copysign(INF, 0.), INF)
426 self.assertEqual(math.copysign(INF, -0.), NINF)
[all …]
/third_party/flutter/skia/modules/skottie/src/effects/
DLinearWipeEffect.cpp54 diag_v = {std::copysign(this->layerSize().width() , cos_), in onMakeMask()
55 std::copysign(this->layerSize().height(), sin_)}; in onMakeMask()
/third_party/skia/modules/skottie/src/effects/
DLinearWipeEffect.cpp75 diag_v = {std::copysign(this->layerSize().width() , cos_), in onMakeMask()
76 std::copysign(this->layerSize().height(), sin_)}; in onMakeMask()

12345678