diag.out; LAI

Generalised diag.out file location specification and made LAI
calculation more efficient.