LAPACK  3.8.0
LAPACK: Linear Algebra PACKage

◆ cbeg()

complex function cbeg ( logical  RESET)

Definition at line 3131 of file cblat2.f.

3131 *
3132 * Generates complex numbers as pairs of random numbers uniformly
3133 * distributed between -0.5 and 0.5.
3134 *
3135 * Auxiliary routine for test program for Level 2 Blas.
3136 *
3137 * -- Written on 10-August-1987.
3138 * Richard Hanson, Sandia National Labs.
3139 * Jeremy Du Croz, NAG Central Office.
3140 *
3141 * .. Scalar Arguments ..
3142  LOGICAL reset
3143 * .. Local Scalars ..
3144  INTEGER i, ic, j, mi, mj
3145 * .. Save statement ..
3146  SAVE i, ic, j, mi, mj
3147 * .. Intrinsic Functions ..
3148  INTRINSIC cmplx
3149 * .. Executable Statements ..
3150  IF( reset )THEN
3151 * Initialize local variables.
3152  mi = 891
3153  mj = 457
3154  i = 7
3155  j = 7
3156  ic = 0
3157  reset = .false.
3158  END IF
3159 *
3160 * The sequence of values of I or J is bounded between 1 and 999.
3161 * If initial I or J = 1,2,3,6,7 or 9, the period will be 50.
3162 * If initial I or J = 4 or 8, the period will be 25.
3163 * If initial I or J = 5, the period will be 10.
3164 * IC is used to break up the period by skipping 1 value of I or J
3165 * in 6.
3166 *
3167  ic = ic + 1
3168  10 i = i*mi
3169  j = j*mj
3170  i = i - 1000*( i/1000 )
3171  j = j - 1000*( j/1000 )
3172  IF( ic.GE.5 )THEN
3173  ic = 0
3174  GO TO 10
3175  END IF
3176  cbeg = cmplx( ( i - 500 )/1001.0, ( j - 500 )/1001.0 )
3177  RETURN
3178 *
3179 * End of CBEG.
3180 *
complex function cbeg(RESET)
Definition: cblat2.f:3131
Here is the caller graph for this function: