ENH: mapDistribute : added whichTransform to find transform from local index

This commit is contained in:
mattijs
2011-01-31 12:12:32 +00:00
parent 4212b1159d
commit 6b90a6c235
2 changed files with 10 additions and 0 deletions

View File

@ -29,6 +29,7 @@ License
#include "globalIndex.H"
#include "globalIndexAndTransform.H"
#include "transformField.H"
#include "ListOps.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
@ -1104,6 +1105,12 @@ Foam::mapDistribute::mapDistribute(const Xfer<mapDistribute>& map)
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
Foam::label Foam::mapDistribute::whichTransform(const label index) const
{
return findLower(transformStart_, index+1);
}
void Foam::mapDistribute::transfer(mapDistribute& rhs)
{
constructSize_ = rhs.constructSize_;

View File

@ -385,6 +385,9 @@ public:
return transformStart_;
}
//- Find transform from transformElements
label whichTransform(const label index) const;
//- Calculate a schedule. See above.
static List<labelPair> schedule
(