function h = ozone_conserved ( y )

%*****************************************************************************80
%
%% ozone_conserved() evaluates a quantity that should be conserved.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    05 January 2021
%
%  Author:
%
%    John Burkardt
%
%  Reference:
%
%    Dale Durran,
%    Numerical methods for fluid dynamics, with applications to geophysics,
%    Second Edition,
%    Springer, 2010,
%    ISBN13: 978-1-4419-6412-0.
%
%  Input:
%
%    real Y(4): the current solution.
%
%  Output:
%
%    real H: the conserved quantity.
%
  y1 = y(:,1);
  y2 = y(:,2);
  y3 = y(:,3);
  y4 = y(:,4);

  h = y1 + y2 + 2.0 * y3 + y4;

  return
end
