Skip to content
Snippets Groups Projects
Commit a2628f09 authored by Timo Koch's avatar Timo Koch
Browse files

[parallel] Uncomment the parallel interface member functions

Communicate seems to be required by DefaultGridView.
Throw an exception in loadBalance when the number of processes is greater than 1.
parent 2770f9d8
No related branches found
No related tags found
1 merge request!38[parallel] Uncomment the parallel interface member functions
This commit is part of merge request !38. Comments created here will be created in the context of that merge request.
......@@ -534,15 +534,18 @@ class FoamGrid :
return 0;
}
#if 0
/** \brief Distributes this grid over the available nodes in a distributed machine
*
* \param minlevel The coarsest grid level that gets distributed
* \param maxlevel does currently get ignored
*/
void loadBalance(int strategy, int minlevel, int depth, int maxlevel, int minelement){
DUNE_THROW(NotImplemented, "FoamGrid::loadBalance()");
template<class DataHandle>
void loadBalance(DataHandle& data)
{
loadBalance();
}
void loadBalance()
{
if (comm().size() > 1)
DUNE_THROW(Dune::NotImplemented, "Load balancing not implemented. Foamgrid does not run in parallel yet!");
}
/** \brief The communication interface
......@@ -557,12 +560,12 @@ class FoamGrid :
* the protocol. Therefore P is called the "protocol class".
*/
template<class T, template<class> class P, int codim>
void communicate (T& t, InterfaceType iftype, CommunicationDirection dir, int level);
void communicate (T& t, InterfaceType iftype, CommunicationDirection dir, int level) const
{}
/*! The new communication interface
communicate objects for all codims on a given level
*/
*communicate objects for all codims on a given level
*/
template<class DataHandle>
void communicate (DataHandle& data, InterfaceType iftype, CommunicationDirection dir, int level) const
{}
......@@ -570,7 +573,6 @@ class FoamGrid :
template<class DataHandle>
void communicate (DataHandle& data, InterfaceType iftype, CommunicationDirection dir) const
{}
#endif
/** dummy collective communication */
const typename Traits::CollectiveCommunication& comm () const
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment