$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 SERIAL_MULTI_DATA_FIELD_3D_H 00029 #define SERIAL_MULTI_DATA_FIELD_3D_H 00030 00031 #include "core/globalDefs.h" 00032 #include "multiBlock/multiDataField3D.h" 00033 00034 namespace plb { 00035 00036 template<typename T> 00037 class SerialScalarAccess3D : public MultiScalarAccess3D<T> { 00038 public: 00039 SerialScalarAccess3D(); 00040 virtual T& getDistributedScalar ( 00041 plint iX, plint iY, plint iZ, 00042 MultiBlockManagement3D const& multiBlockManagement, 00043 std::map<plint,ScalarField3D<T>*>& fields ); 00044 virtual T const& getDistributedScalar ( 00045 plint iX, plint iY, plint iZ, 00046 MultiBlockManagement3D const& multiBlockManagement, 00047 std::map<plint,ScalarField3D<T>*> const& fields ) const; 00048 virtual SerialScalarAccess3D<T>* clone() const; 00049 private: 00050 mutable plint locatedBlock; 00051 }; 00052 00053 00054 template<typename T, int nDim> 00055 class SerialTensorAccess3D : public MultiTensorAccess3D<T,nDim> { 00056 public: 00057 SerialTensorAccess3D(); 00058 virtual Array<T,nDim>& getDistributedTensor ( 00059 plint iX, plint iY, plint iZ, 00060 MultiBlockManagement3D const& multiBlockManagement, 00061 std::map<plint,TensorField3D<T,nDim>*>& fields ); 00062 virtual Array<T,nDim> const& getDistributedTensor ( 00063 plint iX, plint iY, plint iZ, 00064 MultiBlockManagement3D const& multiBlockManagement, 00065 std::map<plint,TensorField3D<T,nDim>*> const& fields ) const; 00066 virtual SerialTensorAccess3D<T,nDim>* clone() const; 00067 private: 00068 mutable plint locatedBlock; 00069 }; 00070 00071 00072 template<typename T> 00073 class SerialNTensorAccess3D : public MultiNTensorAccess3D<T> { 00074 public: 00075 SerialNTensorAccess3D(); 00076 virtual T* getDistributedNTensor ( 00077 plint iX, plint iY, plint iZ, 00078 MultiBlockManagement3D const& multiBlockManagement, 00079 std::map<plint,NTensorField3D<T>*>& fields ); 00080 virtual T const* getDistributedNTensor ( 00081 plint iX, plint iY, plint iZ, 00082 MultiBlockManagement3D const& multiBlockManagement, 00083 std::map<plint,NTensorField3D<T>*> const& fields ) const; 00084 virtual SerialNTensorAccess3D<T>* clone() const; 00085 private: 00086 mutable plint locatedBlock; 00087 }; 00088 00089 } // namespace plb 00090 00091 #endif // SERIAL_MULTI_DATA_FIELD_3D_H
1.6.3
1.6.3