Main Page | User's Guide | Namespace List | Class List | File List | Namespace Members | Class Members

Kz.hxx

00001 // Copyright (C) 2003-2005 CEREA
00002 //     Author: Vivien Mallet
00003 //
00004 // CEREA (http://www.enpc.fr/cerea) is a joint laboratory of
00005 // ENPC (http://www.enpc.fr) and EDF R&D (http://www.edf.fr).
00006 //
00007 // This file is part of AtmoData library.
00008 // AtmoData library is a tool for data processing in atmospheric
00009 // sciences.
00010 // 
00011 // AtmoData is free software; you can redistribute it and/or modify
00012 // it under the terms of the GNU General Public License as published by
00013 // the Free Software Foundation; either version 2 of the License, or
00014 // (at your option) any later version.
00015 // 
00016 // AtmoData is distributed in the hope that it will be useful,
00017 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00018 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019 // GNU General Public License (file "license") for more details.
00020 //
00021 // For more information, please see the AtmoData home page:
00022 //     http://spacetown.free.fr/lib/atmodata
00023 
00024 
00025 #ifndef ATMODATA_FILE_KZ_HXX
00026 
00027 namespace AtmoData
00028 {
00029 
00031 
00036   template <class T, class T0>
00037   inline T min(T x, T0 y)
00038   {
00039 
00040     return x<y?x:y;
00041 
00042   }
00043 
00045 
00050   template <class T, class T0>
00051   inline T max(T x, T0 y)
00052   {
00053 
00054     return x>y?x:y;
00055 
00056   }
00057 
00058   template<class TU, class TV, class TTp, class T, class TG>
00059   void ComputeLouisKz(Data<TU, 4, TG>& U, Data<TV, 4, TG>& V,
00060                       Data<TTp, 4, TG>& Tp, Data<T, 4, TG>& Kz,
00061                       T L0 = T(100), T B = T(5),
00062                       T C = T(5), T D = T(5), T z0 = T(1),
00063                       T a = T(0.115), T b = T(0.175), T delta_z0 = T(0.01),
00064                       T Ka = T(0.4));
00065 
00066   template<class TU, class TTp, class T, class TG>
00067   void ComputeLMO(const Data<TU, 3, TG>& FrictionModule,
00068                   const Data<TTp, 3, TG>& SurfacePotentialTemperature,
00069                   const Data<TTp, 4, TG>& PotentialTemperature,
00070                   const Data<T, 3, TG>& SensibleHeat,
00071                   const Data<T, 3, TG>& Evaporation,
00072                   Data<T, 3, TG>& LMO, T Ka = T(0.4));
00073 
00074   template<class TT, class TTp, class TU, class T, class TG>
00075   void ComputePBLH_TM(const Data<TT, 3, TG>& SurfaceTemperature,
00076                       const Data<TTp, 3, TG>& SurfacePotentialTemperature,
00077                       const Data<TTp, 4, TG>& PotentialTemperature,
00078                       const Data<TU, 3, TG>& FrictionModule,
00079                       const Data<TU, 4, TG>& WindModule,
00080                       const Data<T, 3, TG>& SensibleHeat,
00081                       const Data<T, 3, TG>& LMO,
00082                       const Grid<TG>& GridZ_interf,
00083                       Data<T, 3, TG>& BoundaryHeight, 
00084                       T SBL = T(0.1), T Ric = T(0.21), T C = T(6.5), 
00085                       T Ka = T(0.4));
00086 
00087   template<class T, class TG>
00088   void ComputePBLH_Richardson(const Data<T, 4, TG>& Richardson,
00089                               const Grid<TG>& GridZ_interf,
00090                               Data<T, 3, TG>& BoundaryHeight, 
00091                               T Ric = T(0.21));
00092 
00093   template<class TU, class TT, class T, class TG>
00094   void ComputeTM_Kz(const Data<TT, 3, TG>& SurfaceTemperature,
00095                     const Data<TU, 3, TG>& FrictionModule,
00096                     const Data<T, 3, TG>& SensibleHeat,
00097                     const Data<T, 3, TG>& LMO,
00098                     const Data<T, 3, TG>& BoundaryHeight, 
00099                     Data<T, 4, TG>& Kz,
00100                     bool TM_stable = true, T SBL = T(0.1), T p = T(2.0),
00101                     T Ka = T(0.4));
00102 
00103 }  // namespace AtmoData.
00104 
00105 #define ATMODATA_FILE_KZ_HXX
00106 #endif

Generated on Tue Nov 7 14:58:48 2006 for AtmoData by  doxygen 1.4.2