From ff3d4ff2d64568d717d71c0d295fc96400c09dc0 Mon Sep 17 00:00:00 2001 From: jedokaplan Date: Mon, 7 Mar 2022 11:28:20 +0800 Subject: [PATCH] override if elevation input not present --- biome4driver.f90 | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/biome4driver.f90 b/biome4driver.f90 index c37bc21..242028b 100644 --- a/biome4driver.f90 +++ b/biome4driver.f90 @@ -163,10 +163,16 @@ program biome4main ! elevation status = nf90_inq_varid(ncid,'elv',varid) -if (status /= nf90_noerr) call handle_err(status) +if (status == nf90_noerr) then -status = nf90_get_var(ncid,varid,elv,start=[srtx,srty],count=[cntx,cnty]) -if (status /= nf90_noerr) call handle_err(status) + status = nf90_get_var(ncid,varid,elv,start=[srtx,srty],count=[cntx,cnty]) + if (status /= nf90_noerr) call handle_err(status) + +else + + elv = 0. + +end if !------------------------------------------------------- ! temperature