# PhasicFlow: src/Interaction/contactSearch/methods/particleWallContactSearchs.cpp Source File
PhasicFlow is an open-source parallel DEM (discrete element method) package for simulating granular flow. It is developed in C++ and can be exectued on both GPU (like CUDA) and CPU.

particleWallContactSearchs.cpp
Go to the documentation of this file.
/*------------------------------- phasicFlow ---------------------------------
O C enter of
O O E ngineering and
O O M ultiscale modeling of
OOOOOOO F luid flow
------------------------------------------------------------------------------
Copyright (C): www.cemf.ir
email: hamid.r.norouzi AT gmail.com
------------------------------------------------------------------------------
Licence:
This file is part of phasicFlow code. It is a free software for simulating
granular and multiphase flows. You can redistribute it and/or modify it under
the terms of GNU General Public License v3 or any other later versions.
phasicFlow is distributed to help others in their research in the field of
granular and multiphase flows, but WITHOUT ANY WARRANTY; without even the
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----------------------------------------------------------------------------*/
template <typename method>
pFlow::particleWallContactSearchs<method>::particleWallContactSearchs
(
const dictionary &dict,
const box &domain,
real minSize,
real maxSize,
const ViewType1D<realx3, memory_space> &position,
const pFlagTypeDevice &flags,
const ViewType1D<real, memory_space> &diam
)
:
domainBox_(domain)
{}
template <typename method>
bool pFlow::particleWallContactSearchs<method>::broadSearch
(
uint32 iter,
real t,
real dt,
csPairContainerType& ppPairs,
csPairContainerType& pwPairs,
const deviceViewType1D<realx3>& pointPos,
const pFlagTypeDevice& flags,
const deviceViewType1D<real>& diameter,
bool force
)
{
if(!getMethod().impl_broadSearch(
ppPairs,
pwPairs,
pointPos,
flags,
diameter))
{
fatalErrorInFunction<<
"Error in performing particle-particle broadSearch in method"<<
getMethod().typeName()<<endl;
return false;
}
return true;
}
pFlow::particleWallContactSearchs::broadSearch
bool broadSearch(uint32 iter, real t, real dt, csPairContainerType &ppPairs, csPairContainerType &pwPairs, const deviceViewType1D< realx3 > &pointPos, const pFlagTypeDevice &flags, const deviceViewType1D< real > &diameter, bool force=false)
Definition: particleWallContactSearchs.cpp:39
pFlow::real
float real
Definition: builtinTypes.hpp:45
pFlow::uint32
unsigned int uint32
Definition: builtinTypes.hpp:56
pFlow::endl
iOstream & endl(iOstream &os)
Add newline and flush stream.
Definition: iOstream.hpp:341
pFlow::deviceViewType1D
Kokkos::View< T * > deviceViewType1D
1D array (vector) with default device (memory space and execution space)
Definition: KokkosTypes.hpp:121
pFlow::unsortedPairs
Definition: unsortedPairs.hpp:32
fatalErrorInFunction
#define fatalErrorInFunction
Report a fatal error and function name and exit the application.
Definition: error.hpp:77
pFlow::ViewType1D
Kokkos::View< T *, properties... > ViewType1D
1D veiw as a vector
Definition: KokkosTypes.hpp:93
pFlow::box
Definition: box.hpp:32
pFlow::domain
Definition: domain.hpp:31
pFlow::dictionary
Dictionary holds a set of data entries or sub-dictionaries that are enclosed in a curely braces or ar...
Definition: dictionary.hpp:67
pFlow::pointFlag< DefaultExecutionSpace >
pFlow::particleWallContactSearchs::particleWallContactSearchs
particleWallContactSearchs(const dictionary &dict, const box &domain, real minSize, real maxSize, const ViewType1D< realx3, memory_space > &position, const pFlagTypeDevice &flags, const ViewType1D< real, memory_space > &diam)
Definition: particleWallContactSearchs.cpp:24