Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Cephes/cmath/   (Cephes Mathematical Library ©)  Datei vom 12.5.2026 mit Größe 591 B image not shown  

Quelle  fabs.c

  Sprache: C
 

/* fabs.c
 *
 *  Absolute value
 *
 *
 *
 * SYNOPSIS:
 *
 * double x, y;
 *
 * y = fabs( x );
 *
 *
 *
 * DESCRIPTION:
 * 
 * Returns the absolute value of the argument.
 *
 */



#include "mconf.h"
/* Avoid using UNK if possible.  */
#ifdef UNK
#if BIGENDIAN
#define MIEEE 1
#else
#define IBMPC 1
#endif
#endif

double fabs(x)
double x;
{
union
  {
    double d;
    short i[4];
  } u;

u.d = x;
#ifdef IBMPC
    u.i[3] &= 0x7fff;
#endif
#ifdef MIEEE
    u.i[0] &= 0x7fff;
#endif
#ifdef DEC
    u.i[3] &= 0x7fff;
#endif
#ifdef UNK
if( u.d < 0 )
   u.d = -u.d;
#endif
return( u.d );
}

Messung V0.5 in Prozent
C=97 H=100 G=98

¤ Dauer der Verarbeitung: 0.9 Sekunden  (vorverarbeitet am  2026-06-17) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.