LAPACK 3.12.1
LAPACK: Linear Algebra PACKage
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages

◆ cbeg()

complex function cbeg ( logical reset)

Definition at line 2731 of file c_cblat3.f.

2732*
2733* Generates complex numbers as pairs of random numbers uniformly
2734* distributed between -0.5 and 0.5.
2735*
2736* Auxiliary routine for test program for Level 3 Blas.
2737*
2738* -- Written on 8-February-1989.
2739* Jack Dongarra, Argonne National Laboratory.
2740* Iain Duff, AERE Harwell.
2741* Jeremy Du Croz, Numerical Algorithms Group Ltd.
2742* Sven Hammarling, Numerical Algorithms Group Ltd.
2743*
2744* .. Scalar Arguments ..
2745 LOGICAL RESET
2746* .. Local Scalars ..
2747 INTEGER I, IC, J, MI, MJ
2748* .. Save statement ..
2749 SAVE i, ic, j, mi, mj
2750* .. Intrinsic Functions ..
2751 INTRINSIC cmplx
2752* .. Executable Statements ..
2753 IF( reset )THEN
2754* Initialize local variables.
2755 mi = 891
2756 mj = 457
2757 i = 7
2758 j = 7
2759 ic = 0
2760 reset = .false.
2761 END IF
2762*
2763* The sequence of values of I or J is bounded between 1 and 999.
2764* If initial I or J = 1,2,3,6,7 or 9, the period will be 50.
2765* If initial I or J = 4 or 8, the period will be 25.
2766* If initial I or J = 5, the period will be 10.
2767* IC is used to break up the period by skipping 1 value of I or J
2768* in 6.
2769*
2770 ic = ic + 1
2771 10 i = i*mi
2772 j = j*mj
2773 i = i - 1000*( i/1000 )
2774 j = j - 1000*( j/1000 )
2775 IF( ic.GE.5 )THEN
2776 ic = 0
2777 GO TO 10
2778 END IF
2779 cbeg = cmplx( ( i - 500 )/1001.0, ( j - 500 )/1001.0 )
2780 RETURN
2781*
2782* End of CBEG.
2783*
complex function cbeg(reset)
Definition cblat2.f:3156
Here is the call graph for this function: