module laplac2 { # Laplacian operator in 2-D use igrad2 logical, parameter, private :: T = .true., F = .false. real, dimension (m1*m2*2), allocatable :: tmp #%_init (m1, m2) integer m1, m2 call igrad2_init (m1, m2) #%_lop (x, y) integer stat1, stat2 if( adj) { stat1 = igrad2_lop ( F, F, y, tmp) # tmp = grad y stat2 = igrad2_lop ( T, T, x, tmp) # x = x + grad' tmp } else { stat1 = igrad2_lop ( F, F, x, tmp) # tmp = grad x stat2 = igrad2_lop ( T, T, y, tmp) # y = y + grad' tmp } }