aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/testsuite/special_functions/13_ellint_3/pr66689.cc
blob: e261003592d41b7e1281ea249307c76026f809f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// { dg-do run { target c++11 } }
// { dg-require-c-std "" }
// { dg-options "-D__STDCPP_WANT_MATH_SPEC_FUNCS__" }
// { dg-add-options ieee }

#include <cmath>
#include <testsuite_hooks.h>

void
test01()
{
  const double pi = 3.141592654;

  double Pi1 = std::ellint_3(0.75, 0.0, pi / 2.0);
  VERIFY(std::abs(Pi1 - 1.91099) < 0.00001);

  double Pi2 = std::ellint_3(0.75, 0.5, pi / 2.0);
  VERIFY(std::abs(Pi2 - 2.80011) < 0.00001);
}

int
main()
{
  test01();
  return 0;
}