$treeview $search $mathjax
Palabos  Version 1.1
$projectbrief
$projectbrief
$searchbox

dynamicsProcessor3D.h

Go to the documentation of this file.
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 DYNAMICS_PROCESSOR_3D_H
00029 #define DYNAMICS_PROCESSOR_3D_H
00030 
00031 #include "core/globalDefs.h"
00032 #include "atomicBlock/dataProcessingFunctional3D.h"
00033 #include "core/dynamics.h"
00034 
00035 namespace plb {
00036 
00037 /* *************** Class ExternalRhoJcollideAndStream3D ******************* */
00038 
00039 template<typename T, template<typename U> class Descriptor>
00040 class ExternalRhoJcollideAndStream3D : public BoxProcessingFunctional3D
00041 {
00042 public:
00043     // Block 0: lattice; Block 1: rhoBar; Block 2: j.
00044     virtual void processGenericBlocks( Box3D domain,
00045                                        std::vector<AtomicBlock3D*> atomicBlocks );
00046     virtual ExternalRhoJcollideAndStream3D<T,Descriptor>* clone() const;
00047     virtual void getTypeOfModification(std::vector<modif::ModifT>& modified) const;
00048 private:
00049     void collide (
00050             BlockLattice3D<T,Descriptor>& lattice, Box3D const& domain,
00051             ScalarField3D<T> const& rhoBarField, Dot3D const& offset1,
00052             TensorField3D<T,3> const& jField, Dot3D const& offset2, BlockStatistics& stat );
00053     void bulkCollideAndStream (
00054             BlockLattice3D<T,Descriptor>& lattice, Box3D const& domain,
00055             ScalarField3D<T> const& rhoBarField, Dot3D const& offset1,
00056             TensorField3D<T,3> const& jField, Dot3D const& offset2, BlockStatistics& stat );
00057     void boundaryStream (
00058             BlockLattice3D<T,Descriptor>& lattice,
00059             Box3D const& bound, Box3D const& domain );
00060 };
00061 
00062 template<typename T, template<typename U> class Descriptor>
00063 class OnLinkExternalRhoJcollideAndStream3D : public BoxProcessingFunctional3D
00064 {
00065 public:
00066     // Block 0: lattice; Block 1: rhoBar; Block 2: j.
00067     virtual void processGenericBlocks( Box3D domain,
00068                                        std::vector<AtomicBlock3D*> atomicBlocks );
00069     virtual OnLinkExternalRhoJcollideAndStream3D<T,Descriptor>* clone() const;
00070     virtual void getTypeOfModification(std::vector<modif::ModifT>& modified) const;
00071 private:
00072     void collide (
00073             BlockLattice3D<T,Descriptor>& lattice, Box3D const& domain,
00074             ScalarField3D<T> const& rhoBarField, Dot3D const& offset1,
00075             TensorField3D<T,3> const& jField, Dot3D const& offset2, BlockStatistics& stat );
00076     void bulkCollideAndStream (
00077             BlockLattice3D<T,Descriptor>& lattice, Box3D const& domain,
00078             ScalarField3D<T> const& rhoBarField, Dot3D const& offset1,
00079             TensorField3D<T,3> const& jField, Dot3D const& offset2, BlockStatistics& stat );
00080     void boundaryStream (
00081             BlockLattice3D<T,Descriptor>& lattice,
00082             Box3D const& bound, Box3D const& domain );
00083 };
00084 
00085 
00086 }  // namespace plb
00087 
00088 #endif  // DYNAMICS_PROCESSOR_3D_H