Пример #1
0
long double complex
cacoshl(long double complex z)
{
	long double complex w;

	w = clogl(z + csqrtl(z + 1) * csqrtl(z - 1));
	return (w);
}
Пример #2
0
// FIXME
long double complex casinl(long double complex z) {
  long double complex w;
  long double x, y;

  x = creall(z);
  y = cimagl(z);
  w = CMPLXL(1.0 - (x - y) * (x + y), -2.0 * x * y);
  return clogl(CMPLXL(-y, x) + csqrtl(w));
}
Пример #3
0
long double complex casinl (long double complex Z)
{
  long double complex Res;
  long double x, y;

  x = __real__ Z;
  y = __imag__ Z;

  if (y == 0.0L)
    {
      __real__ Res = asinl (x);
      __imag__ Res = 0.0L;
    }
  else  /* -I * clog(I * Z + csqrt(1.0 - Z * Z))) */
    {
      long double complex ZZ;
                                 
      /* Z * Z = ((x - y) * (x + y)) + (2.0 * x * y) * I */
      /* calculate 1 - Z * Z */
      __real__ ZZ = 1.0L - (x - y) * (x + y);
      __imag__ ZZ = -2.0L * x * y;
      ZZ = csqrtl (ZZ);


      /* add  I * Z  to ZZ */

      __real__ ZZ -= y;
      __imag__ ZZ += x;

      ZZ = clogl (ZZ);

      /* mult by -I */
      __real__ Res = __imag__ ZZ;
      __imag__ Res = - __real__ ZZ;  
    }
  return (Res);
}
Пример #4
0
 TEST_TRACE(C99 7.3.6.5)
 d = csinh(d);
 f = csinhf(f);
 ld = csinhl(ld);
 TEST_TRACE(C99 7.3.6.6)
 d = ctanh(d);
 f = ctanhf(f);
 ld = ctanhl(ld);
 TEST_TRACE(C99 7.3.7.1)
 d = cexp(d);
 f = cexpf(f);
 ld = cexpl(ld);
 TEST_TRACE(C99 7.3.7.2)
 d = clog(d);
 f = clogf(f);
 ld = clogl(ld);
 TEST_TRACE(C99 7.3.8.1)
 d = cabs(d);
 f = cabsf(f);
 ld = cabsl(ld);
 TEST_TRACE(C99 7.3.8.2)
 d = cpow(d, d);
 f = cpowf(f, f);
 ld = cpowl(ld, ld);
 TEST_TRACE(C99 7.3.8.3)
 d = csqrt(d);
 f = csqrtf(f);
 ld = csqrtl(ld);
 TEST_TRACE(C99 7.3.9.1)
 d = carg(d);
 f = cargf(f);
Пример #5
0
long double complex
cpowl (long double complex base, long double complex power)
{
  return cexpl (power * clogl (base));
}
Пример #6
0
complex long double
catanhl (complex long double z)
{
  return clogl ((1.0L+z)/(1.0L-z))/2.0L;
}
Пример #7
0
complex long double
cacoshl (complex long double z)
{
  return clogl (z + csqrtl (z-1.0L) * csqrtl (z+1.0L));
}
Пример #8
0
complex long double
casinhl (complex long double z)
{
  return clogl (z + csqrtl (z*z+1.0L));
}
Пример #9
0
complex long double
catanl (complex long double z)
{
  return I*clogl ((I+z)/(I-z))/2.0L;
}
Пример #10
0
complex long double
cacosl (complex long double z)
{
  return -I*clogl (z + I*csqrtl (1.0L-z*z));
}
Пример #11
0
complex long double
casinl (complex long double z)
{
  return -I*clogl (I*z + csqrtl (1.0L-z*z));
}