208 REAL FUNCTION slatm2( 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
224 INTEGER iseed( 4 ), iwork( * )
225 REAL d( * ), dl( * ), dr( * )
233 parameter( zero = 0.0e0 )
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(
slaran( 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 =
slarnd( 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 )