lcm.hh

Go to the documentation of this file.
00001 #ifndef DUNE_LCM_HH
00002 #define DUNE_LCM_HH
00003 
00004 #include<dune/common/static_assert.hh>
00005 #include<dune/common/gcd.hh>
00006 
00007 namespace Dune
00008 {
00009   
00023   template<long m, long n>
00024   struct Lcm
00025   {
00026     static void conceptCheck()
00027     {
00028       dune_static_assert(0<m, "m must be positive!");
00029       dune_static_assert(0<n, "n must be positive!");
00030     }
00035     const static long value = (m/Gcd<m,n>::value)*n;
00036   };
00037 }
00038 
00039 #endif

Generated on Thu Apr 2 10:39:53 2009 for dune-common by  doxygen 1.5.6