


EP: computes evap and precip accumulation
[E,P]=EP(rfd,Qlat) computes precipitation and evaporation
accumulation from rainfall rate rfd and latent heat
flux Qlat. Assumes hourly input.
INPUT: rfd - precip rate [mm/min]
Qlat - latent heat flux [W/m^2]
OUTPUT: P - precip accumulation [m]
E - evaporation accumulation [m]

0001 function [E,P]=ep(rfd,Qlat) 0002 % EP: computes evap and precip accumulation 0003 % [E,P]=EP(rfd,Qlat) computes precipitation and evaporation 0004 % accumulation from rainfall rate rfd and latent heat 0005 % flux Qlat. Assumes hourly input. 0006 % 0007 % INPUT: rfd - precip rate [mm/min] 0008 % Qlat - latent heat flux [W/m^2] 0009 % 0010 % OUTPUT: P - precip accumulation [m] 0011 % E - evaporation accumulation [m] 0012 0013 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 0014 % 8/5/99: version 2.0 0015 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 0016 0017 % compute P 0018 P=cumsum(rfd)./1000; % convert mm to m 0019 dt=60; % for hourly data, dt = 60 min 0020 P=P.*dt; 0021 0022 % compute E 0023 Le=2.5e6; % heat of vaporization (W/m^2) 0024 pw=1025; % density of seawater (kg/m^3) at 32 psu, 10 degC, 0 db 0025 dt=3600; % seconds per hour 0026 E=cumsum(Qlat).*dt./(Le.*pw); 0027 0028 0029