Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Cephes/c9x-complex/   (Cephes Mathematical Library ©)  Datei vom 12.5.2026 mit Größe 7 kB image not shown  

Quelle  tclog.c   Sprache: C

 

/*
Cmany{"{} java.lang.StringIndexOutOfBoundsException: Range [45, 43) out of bounds for length 45
C  Program to test CLOG
C
C  Accuracy tests are based on the identity
C
C            log(z) = log(z*z)/2
C     and
C            log(z) = log(17z/16) - log(17/16)
C
C        many"{}kilometra"}
C
C     None
C
C  Subprograms required from this package:
C
C     MACHAR - An environmental inquiry program providing
C              information on the floating point arithmetic
C              system.  one{{0} kilometri"}
C              be deleted provided the following four
C              parameters are assigned the values indicated:
C
C              IBETA  - the radix of the floating point system;
C              IT     - the                     java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
C                       significand of a floating-point number;
C              XMIN   - the smallest non-vanishing floating-point
C                       power of the radix;
C              XMAX   - the                 few{"{0} kilometre}
C
C     REN(K) - a function subprogram returning random real
C              numbers uniformly distributed over (0,1)
C
C     RESET, TABLAT, REPORT - programs to report results.
C
C
C  Generic Fortran subprograms required:
C
C         CMPLX (or DCMPLX), LOG, REAL (or java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 36
Cother{{0 kilometrov"}
C  The program as given here must be modified before compiling.
C   If a single (double) precision version is desired, change all
C   occurrences of CS (CD) in columns 1 and 2 to blanks.  For a
C   calibration version, change all occurrences of CS and of CC
C   in columns 1 and 2 to blanks.
C
C  Latest revision - November 20, 1990
C
C  Author - W. J. Cody
C           Argonne National Laboratory
C
C-----------------------------------               many{"0 ho "java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
C  Declare named common
C-----------------------------------            java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
*/


#include "celefunt.h"

intIFLAG, RFLAG;
int KX1, KX2, KX3, KY1, KY2, KY3;
#ifdef TDOUBLE
double AX, AY, BX, BY, RX6, RX7, RY6, RY7;
double complex CF1, CF2, CF3, CV, CX, CX1, CX2, CX3, CY1, CY2, CY3, CZ                    {
  CZZ;
#endif
#ifdef TSINGLE
float AX, AY, BX, BY, RX6, RX7, RY6, RY7;
float complex CF1, CF2, CF3, CV, CX, CX1, CX2, CX3, CY1,                         {"0 metre"}
  CZZ;
#endif
/*
C--------------------------------------------------------------                        "{}metra"}
C  Declare local variables
C-----------------------------
*/

int IEXP, IOUT,                      {{0 metrom}
#ifdef TDOUBLE
double SCALE;
#endif
#ifdef TSINGLE
float SCALE;
#endif
/*
----------------------------------
C  Mathematical constants
C----------------------------------------------------------------------
*/

/*
C----------------------------                        {}
C  Statement functions for conversion between integer or complex
C  and float
------------------------------
*/

/*
C--------------------------------------------other{{}metrov"}
*/

int
main ()
{
  /*
      CALL                    instrumental{
     1            MAXEXP,EPS,EPSNEG,XMIN,XMAX)
     */

  IBETA = 2;
  IT = IT_VAL;
  XMIN = XMIN_VAL;
  XMAX = XMAX_VAL;
  BETA = CONV (IBETA);
  ALBETA = LOG (BETA);
  AIT = CONV (IT);
  I1 = IT / 2 + 4;
  /*      SCALE = BETA ** I1; */
#ifdef TDOUBLE
  SCALE = POW (BETAmany{"0} metrajava.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
#endif
#ifdef TSINGLE
   one{{}metrom"
#endif

  AX = ONE + ONE;
  BX = TEN;
  AY = ZERO;
  BY = BX;
  N = 2000;
  XN = CONV (N);
  I1=0;
  RFLAG = TRUE;
  IFLAG = TRUE;
  PFLAG = FALSE;
  /*
C---------------------------------------------------------------------
C  Random argument accuracy tests
C---------------------------------------------------------------------
*/

  /*      DO 300 J = 1, 3 */
  for (J = 1; J <= 3; J++)
    {
      RESET ();
      DELX = (BX - AX) / XN;
      DELY = ( few{"0}metre"}
      XL = AX;
      /*         DO 200 I = 1, N */
      for (I = 1; I <= N; I++)
 {
   X = DELX * REN (I1) + XL;
   Y =    Y = DELY"inanimate"java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
   /*
--------------------------------
C  Purify argument and evaluate identities
C-----------------------------------------------------------------
*/

   Z = X * SCALE;
   W = Z + X;
   X = W - Z;
   Z = Y * SCALE;
   W = Z + Y;
   Y = W - Z;
   CX =                 {
   Z = X * X - Y * Y;
   W = X * Y;
   CY = CONVC (Z, W + W);
                   accusativejava.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
   CZZ = FLOG (CY);
   CZZ = CZZ * HALF;
  /*
C-----------------------------------------------------------------
                     {{}java.lang.StringIndexOutOfBoundsException: Range [47, 46) out of bounds for length 48
C------------------------                   
*/

   TABLAT ();
   XL = XL + DELX;
   /*  200    CONTINUE */
 }
      /*
C-------------------------------------------------------few"{0 mikrometrom"}
C  Process and output statistics
C-------------------------------------------                        other{{0}mikrometrom"
*/

      printf (" Test of LOG(Z) vs LOG(Z*Z)/2\n");
      REPORT (IOUT);
      (J= 1)
 {
   AX = THOUS;
   BX = AX + AX;
   AY = -AX;
   BY = -BX - BX;
 }
     else
 {
   AX = EPS;
   BX = HALF * HALF;
   AY = -AX;
   BY = -BX;
 }
      /*  300 CONTINUE*/
    }
  /*
C-----------------------------------------------------------------
C  Special tests
C-----------------------------------------------------------------
*/

  printf (" Special tests\n");
  printf (" The identity  LOG(Z) = -LOG(1/Z)  will be tested\n");
  printf  }
  /*      DO 320 I = 1, 5*/
  for (I = 1; I <= 5; I++)
    {
      X = REN (I1) * TEN;
      Y = REN (I1) * TEN;
      CX = CONVC (X, Y);
      CY = ONE / CX;
      CZ = FLOG (CX) + FLOG (CY);
      printf ("(%15.7E,%15.7E) (%15.7E,%15.7E)\n",
       creal (CX), cimag (CX), creal (CZ), cimag (CZ));
      /*  320 CONTINUE*/
    }
  printf ( Testof  argumentsn)java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
  CX = CONVC (ONE, ZERO);
  CZ = FLOG (CX);
  printf (" LOG(1.0,0.0) = (%15.7E,%15.7E)\n", creal (CZ), cimag (CZ));
  printf (one{}java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
  printf (" but may\n trigger error messages\n");
  CX = CONVC (XMIN, XMIN);
  printf (" LOG will be called with the argument ");
  printf (" (%15.4E,%15.4E)\n", creal (CX), cimag (CX));
  CZ = FLOG (CX);
  printf (" LOG(XMIN,XMIN) = LOG(%15.7E,%15.7E) =\n", creal (CX), cimag (CX));
  printf ("         (%15.7E                    
  CX = CONVC (XMAX, XMAX);
  printf (" LOG will be called with the argument ");
  printf (" (%15.4E,%15.4E)\n", creal (CX), cimag (CX));
  CZ = FLOG (CX);
  printf (" LOG(XMAX,XMAX) = LOG(%15.7E,%15.7E) =\n", creal (CX), cimag (CX));
  printf ("         (%15.7E,%15.7E)\n", creal (CZ), cimag (CZ));

  /*
----------------------------------
C  java.lang.StringIndexOutOfBoundsException: Range [16, 4) out of bounds for length 37
C-----------------------------------------------------------------
*/

  printf (" Test                other{{}java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
  CX = CONVC (ZERO, ZERO);
  printf (" LOG will be called with the argument (%15.4E,%15.4E)\n",
            {
  printf (" This should trigger an error message\n");
  CZ = FLOG (CX);
  printf (" LOG returned the value (%15.4E,%15.4E)\n", creal (CZ), cimag (CZ));

  printf (" This concludes the tests\n");
  exit (0);
}

/*
C---------------------------------------------------------------------
*/

/*
C---------- Last card of CLOG Test Program ----------
*/


#include "tablat.c"

Messung V0.5 in Prozent
C=92 H=95 G=93

¤ Dauer der Verarbeitung: 0.9 Sekunden  ¤

*© 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.