$treeview $search $mathjax
|
Palabos
Version 1.1
$projectbrief
|
$projectbrief
|
$searchbox |
00001 /* This file is part of the Palabos library. 00002 * 00003 * Copyright (C) 2011 FlowKit Sarl 00004 * Avenue de Chailly 23 00005 * 1012 Lausanne, Switzerland 00006 * E-mail contact: contact@flowkit.com 00007 * 00008 * The most recent release of Palabos can be downloaded at 00009 * <http://www.palabos.org/> 00010 * 00011 * The library Palabos is free software: you can redistribute it and/or 00012 * modify it under the terms of the GNU Affero General Public License as 00013 * published by the Free Software Foundation, either version 3 of the 00014 * License, or (at your option) any later version. 00015 * 00016 * The library 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 Affero General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU Affero General Public License 00022 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00023 */ 00024 00028 #ifndef NEAREST_NEIGHBOR_LATTICES_2D_HH 00029 #define NEAREST_NEIGHBOR_LATTICES_2D_HH 00030 00031 #include "latticeBoltzmann/nearestNeighborLattices2D.h" 00032 00033 namespace plb { 00034 00035 namespace descriptors { 00036 00037 // D2Q9 //////////////////////////////////////////////////////////// 00038 00039 template<typename T> 00040 const T D2Q9Constants<T>::invD = (T)1 / (T) d; 00041 00042 template<typename T> 00043 const int D2Q9Constants<T>::vicinity = 1; 00044 00045 template<typename T> 00046 const int D2Q9Constants<T>::c 00047 [D2Q9Constants<T>::q][D2Q9Constants<T>::d] = 00048 { 00049 { 0, 0}, 00050 {-1, 1}, {-1, 0}, {-1,-1}, { 0,-1}, 00051 { 1,-1}, { 1, 0}, { 1, 1}, { 0, 1} 00052 }; 00053 00054 template<typename T> 00055 const int D2Q9Constants<T>::cNormSqr[D2Q9Constants<T>::q] = 00056 { 0, 2, 1, 2, 1, 2, 1, 2, 1 }; 00057 00058 template<typename T> 00059 const T D2Q9Constants<T>::t[D2Q9Constants<T>::q] = 00060 { 00061 (T)4/(T)9, (T)1/(T)36, (T)1/(T)9, (T)1/(T)36, (T)1/(T)9, 00062 (T)1/(T)36, (T)1/(T)9, (T)1/(T)36, (T)1/(T)9 00063 }; 00064 00065 template<typename T> 00066 const T D2Q9Constants<T>::cs2 = (T)1 / (T)3; 00067 00068 template<typename T> 00069 const T D2Q9Constants<T>::invCs2 = (T)3; 00070 00071 template<typename T> 00072 const char D2Q9Descriptor<T>::name[] = "D2Q9"; 00073 00074 template<typename T> 00075 const char ForcedD2Q9Descriptor<T>::name[] = "ForcedD2Q9"; 00076 00077 template<typename T> 00078 const char RhoBarJD2Q9Descriptor<T>::name[] = "RhoBarJD2Q9"; 00079 00080 template<typename T> 00081 const char VelocityD2Q9Descriptor<T>::name[] = "VelocityD2Q9"; 00082 00083 template<typename T> 00084 const char Tau1_D2Q9Descriptor<T>::name[] = "Tau1_D2Q9"; 00085 00086 } // namespace descriptors 00087 00088 } // namespace plb 00089 00090 #endif
1.6.3
1.6.3