$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 00025 #ifndef INTERPARTICLE_POTENTIAL_H 00026 #define INTERPARTICLE_POTENTIAL_H 00027 00028 #include "core/globalDefs.h" 00029 #include <cmath> 00030 00031 namespace plb { 00032 00034 namespace interparticlePotential { 00035 00037 template<typename T> 00038 struct PsiFunction { 00039 virtual ~PsiFunction(); 00040 virtual T compute(T rho) const =0; 00041 virtual PsiFunction<T>* clone() const =0; 00042 }; 00043 00044 00045 template<typename T> 00046 class PsiIsRho : public PsiFunction<T> { 00047 virtual T compute(T rho) const; 00048 virtual PsiIsRho<T>* clone() const; 00049 }; 00050 00052 template<typename T> 00053 class PsiShanChen93 : public PsiFunction<T> { 00054 public: 00055 PsiShanChen93(T rho_0_); 00056 virtual T compute(T rho) const; 00057 virtual PsiShanChen93<T>* clone() const; 00058 private: 00059 T rho_0; 00060 }; 00061 00063 template<typename T> 00064 class PsiShanChen94 : public PsiFunction<T> { 00065 public: 00066 PsiShanChen94(T psi_0_, T rho_0_); 00067 virtual T compute(T rho) const; 00068 virtual PsiShanChen94<T>* clone() const; 00069 private: 00070 T psi_0, rho_0; 00071 }; 00072 00074 template<typename T> 00075 class PsiQian95 : public PsiFunction<T> { 00076 public: 00077 PsiQian95(T rho_0_, T g_); 00078 virtual T compute(T rho) const; 00079 virtual PsiQian95<T>* clone() const; 00080 private: 00081 T rho_0, rho_0_sqr, g; 00082 }; 00083 00084 } // namespace potentials 00085 00086 } // namespace plb 00087 00088 #endif // INTERPARTICLE_POTENTIAL_H
1.6.3
1.6.3