208 DOUBLE PRECISION FUNCTION dlatm2( M, N, I, J, KL, KU, IDIST,
209 $ iseed, d, igrade, dl, dr, ipvtng, iwork, sparse )
218 INTEGER I, IDIST, IGRADE, IPVTNG, J, KL, KU, M, N
219 DOUBLE PRECISION SPARSE
224 INTEGER ISEED( 4 ), IWORK( * )
225 DOUBLE PRECISION D( * ), DL( * ), DR( * )
232 DOUBLE PRECISION ZERO
233 parameter ( zero = 0.0d0 )
239 DOUBLE PRECISION TEMP
244 DOUBLE PRECISION DLARAN, DLARND
245 EXTERNAL dlaran, dlarnd
255 IF( i.LT.1 .OR. i.GT.m .OR. j.LT.1 .OR. j.GT.n )
THEN
262 IF( j.GT.i+ku .OR. j.LT.i-kl )
THEN
269 IF( sparse.GT.zero )
THEN
270 IF( dlaran( iseed ).LT.sparse )
THEN
278 IF( ipvtng.EQ.0 )
THEN
281 ELSE IF( ipvtng.EQ.1 )
THEN
284 ELSE IF( ipvtng.EQ.2 )
THEN
287 ELSE IF( ipvtng.EQ.3 )
THEN
294 IF( isub.EQ.jsub )
THEN
297 temp = dlarnd( idist, iseed )
299 IF( igrade.EQ.1 )
THEN
300 temp = temp*dl( isub )
301 ELSE IF( igrade.EQ.2 )
THEN
302 temp = temp*dr( jsub )
303 ELSE IF( igrade.EQ.3 )
THEN
304 temp = temp*dl( isub )*dr( jsub )
305 ELSE IF( igrade.EQ.4 .AND. isub.NE.jsub )
THEN
306 temp = temp*dl( isub ) / dl( jsub )
307 ELSE IF( igrade.EQ.5 )
THEN
308 temp = temp*dl( isub )*dl( jsub )
double precision function dlatm2(M, N, I, J, KL, KU, IDIST, ISEED, D, IGRADE, DL, DR, IPVTNG, IWORK, SPARSE)
DLATM2