function [soil_diff] = func_calc_diff(soil)
% Summary of this function goes here
%   Detailed explanation goes here
% 1: no routing 
% 2: 250m 
% 3: 500m
% 4: 1000m

%  % ---- difference field ----
%   1: routing_250m - no_routing
%   2: routing_250m - routing_500m
%   3: routing_250m - routing_1000m
%   4: routing_250m - routing_500m
%   5: routing_500m - routing_1000m


soil_diff(:,:,1,:)  = soil(:,:,2,:) -  soil(:,:,1,:);
soil_diff(:,:,2,:)  = soil(:,:,2,:) -  soil(:,:,3,:);
soil_diff(:,:,3,:)  = soil(:,:,2,:) -  soil(:,:,4,:);

soil_diff(:,:,4,:)  = soil(:,:,2,:) -  soil(:,:,3,:);
soil_diff(:,:,5,:)  = soil(:,:,3,:) -  soil(:,:,4,:);

soil_diff(:,:,:,5) = squeeze(mean(soil_diff , 4)); % obtain the annual mean value

end

