msm::IndexRange Class Reference

#include <MsmMap.h>

Inheritance diagram for msm::IndexRange:

msm::Grid< T > msm::Grid< C1Matrix > msm::Grid< C1Vector > msm::GridFixed< T, N > List of all members.

Public Member Functions

 IndexRange ()
void set (int pia, int pni, int pja, int pnj, int pka, int pnk)
void setbounds (int pia, int pib, int pja, int pjb, int pka, int pkb)
int ia () const
int ib () const
int ja () const
int jb () const
int ka () const
int kb () const
int ni () const
int nj () const
int nk () const
int nn () const
Ivec lower () const
Ivec extent () const
int operator<= (const IndexRange &n)

Protected Attributes

Ivec nlower
Ivec nextent

Detailed Description

Definition at line 423 of file MsmMap.h.


Constructor & Destructor Documentation

msm::IndexRange::IndexRange (  )  [inline]

Definition at line 425 of file MsmMap.h.

Referenced by msm::Grid< Vtype >::extract(), msm::GridFixed< T, N >::extract(), msm::Grid< Vtype >::operator+=(), and msm::GridFixed< T, N >::operator+=().

00425 : nlower(0), nextent(0) { }


Member Function Documentation

Ivec msm::IndexRange::extent (  )  const [inline]

Definition at line 445 of file MsmMap.h.

References nextent.

Referenced by msm::Grid< Vtype >::init(), msm::GridFixed< T, N >::init(), and GridMsg::put().

00445 { return nextent; }

int msm::IndexRange::ia (  )  const [inline]

Definition at line 434 of file MsmMap.h.

References msm::Ivec::i, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::Grid< Vtype >::flatindex(), msm::GridFixed< T, N >::flatindex(), msm::PatchData::interpolationC1Hermite(), msm::Grid< Vtype >::operator+=(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00434 { return nlower.i; }

int msm::IndexRange::ib (  )  const [inline]

Definition at line 435 of file MsmMap.h.

References msm::Ivec::i, nextent, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::PatchData::interpolationC1Hermite(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00435 { return nlower.i + nextent.i - 1; }

int msm::IndexRange::ja (  )  const [inline]

Definition at line 436 of file MsmMap.h.

References msm::Ivec::j, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::Grid< Vtype >::flatindex(), msm::GridFixed< T, N >::flatindex(), msm::PatchData::interpolationC1Hermite(), msm::Grid< Vtype >::operator+=(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00436 { return nlower.j; }

int msm::IndexRange::jb (  )  const [inline]

Definition at line 437 of file MsmMap.h.

References msm::Ivec::j, nextent, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::PatchData::interpolationC1Hermite(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00437 { return nlower.j + nextent.j - 1; }

int msm::IndexRange::ka (  )  const [inline]

Definition at line 438 of file MsmMap.h.

References msm::Ivec::k, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::Grid< Vtype >::flatindex(), msm::GridFixed< T, N >::flatindex(), msm::PatchData::interpolationC1Hermite(), msm::Grid< Vtype >::operator+=(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00438 { return nlower.k; }

int msm::IndexRange::kb (  )  const [inline]

Definition at line 439 of file MsmMap.h.

References msm::Ivec::k, nextent, and nlower.

Referenced by msm::PatchData::anterpolationC1Hermite(), msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::elem(), msm::GridFixed< T, N >::elem(), msm::PatchData::interpolationC1Hermite(), operator<=(), MsmBlockKernel< Vtype, Mtype >::prolongationKernel(), MsmBlockKernel< Vtype, Mtype >::restrictionKernel(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00439 { return nlower.k + nextent.k - 1; }

Ivec msm::IndexRange::lower (  )  const [inline]

Definition at line 444 of file MsmMap.h.

References nlower.

Referenced by msm::Grid< Vtype >::init(), msm::GridFixed< T, N >::init(), and GridMsg::put().

00444 { return nlower; }

int msm::IndexRange::ni (  )  const [inline]

Definition at line 440 of file MsmMap.h.

References msm::Ivec::i, and nextent.

Referenced by msm::PatchData::anterpolationC1Hermite(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::extract(), msm::GridFixed< T, N >::extract(), msm::Grid< Vtype >::flatindex(), msm::GridFixed< T, N >::flatindex(), msm::PatchData::interpolationC1Hermite(), msm::Grid< Vtype >::operator+=(), and msm::GridFixed< T, N >::operator+=().

00440 { return nextent.i; }

int msm::IndexRange::nj (  )  const [inline]

Definition at line 441 of file MsmMap.h.

References msm::Ivec::j, and nextent.

Referenced by msm::PatchData::anterpolationC1Hermite(), MsmC1HermiteGridCutoff::compute_specialized(), msm::Grid< Vtype >::flatindex(), msm::GridFixed< T, N >::flatindex(), and msm::PatchData::interpolationC1Hermite().

00441 { return nextent.j; }

int msm::IndexRange::nk (  )  const [inline]

Definition at line 442 of file MsmMap.h.

References msm::Ivec::k, and nextent.

Referenced by MsmC1HermiteGridCutoff::compute_specialized().

00442 { return nextent.k; }

int msm::IndexRange::nn (  )  const [inline]

Definition at line 443 of file MsmMap.h.

References msm::Ivec::i, msm::Ivec::j, msm::Ivec::k, and nextent.

Referenced by msm::Grid< Vtype >::init(), msm::Grid< Vtype >::reset(), msm::GridFixed< T, N >::reset(), MsmC1HermiteBlock::sendDownPotential(), MsmBlock::sendDownPotential(), MsmC1HermiteBlock::sendPatch(), MsmBlock::sendPatch(), MsmC1HermiteBlock::sendUpCharge(), MsmBlock::sendUpCharge(), msm::Grid< Vtype >::set(), and msm::Grid< Vtype >::setbounds().

00443 { return nextent.i * nextent.j * nextent.k; }

int msm::IndexRange::operator<= ( const IndexRange n  )  [inline]

Definition at line 446 of file MsmMap.h.

References ia(), ib(), ja(), jb(), ka(), and kb().

00446                                           {
00447         // true if this IndexRange fits inside n
00448         return ( ia() >= n.ia() && ib() <= n.ib() &&
00449                  ja() >= n.ja() && jb() <= n.jb() &&
00450                  ka() >= n.ka() && kb() <= n.kb() );
00451       }

void msm::IndexRange::set ( int  pia,
int  pni,
int  pja,
int  pnj,
int  pka,
int  pnk 
) [inline]

Reimplemented in msm::GridFixed< T, N >, msm::Grid< T >, msm::Grid< msm::BlockDiagram >, msm::Grid< C1Vector >, msm::Grid< Mtype >, msm::Grid< float >, msm::Grid< C1Matrix >, and msm::Grid< Vtype >.

Definition at line 426 of file MsmMap.h.

References ASSERT, nextent, and nlower.

Referenced by msm::Map::indexRangeOfBlockFold(), msm::Grid< Vtype >::set(), msm::GridFixed< T, N >::set(), and setbounds().

00426                                                                      {
00427         ASSERT(pni >= 0 && pnj >= 0 && pnk >= 0);
00428         nlower = Ivec(pia, pja, pka);
00429         nextent = Ivec(pni, pnj, pnk);
00430       }

void msm::IndexRange::setbounds ( int  pia,
int  pib,
int  pja,
int  pjb,
int  pka,
int  pkb 
) [inline]

Reimplemented in msm::GridFixed< T, N >, msm::Grid< T >, msm::Grid< msm::BlockDiagram >, msm::Grid< C1Vector >, msm::Grid< Mtype >, msm::Grid< float >, msm::Grid< C1Matrix >, and msm::Grid< Vtype >.

Definition at line 431 of file MsmMap.h.

References set().

Referenced by msm::Map::clipBlockToIndexRange(), msm::Map::clipBlockToIndexRangeFold(), msm::Grid< Vtype >::setbounds(), msm::GridFixed< T, N >::setbounds(), msm::Map::wrapBlockSend(), and msm::Map::wrapBlockSendFold().

00431                                                                            {
00432         set(pia, pib-pia+1, pja, pjb-pja+1, pka, pkb-pka+1);
00433       }


Member Data Documentation

Ivec msm::IndexRange::nextent [protected]

Definition at line 459 of file MsmMap.h.

Referenced by extent(), msm::Grid< Vtype >::extract(), msm::GridFixed< T, N >::extract(), ib(), msm::Grid< Vtype >::init(), msm::GridFixed< T, N >::init(), jb(), kb(), ni(), nj(), nk(), nn(), msm::Grid< Vtype >::operator+=(), msm::GridFixed< T, N >::operator+=(), msm::GridFixed< T, N >::set(), set(), and msm::GridFixed< T, N >::setbounds().

Ivec msm::IndexRange::nlower [protected]

Definition at line 458 of file MsmMap.h.

Referenced by msm::Grid< Vtype >::extract(), msm::GridFixed< T, N >::extract(), ia(), ib(), msm::Grid< Vtype >::init(), msm::GridFixed< T, N >::init(), ja(), jb(), ka(), kb(), lower(), msm::Grid< Vtype >::operator+=(), msm::GridFixed< T, N >::operator+=(), set(), msm::Grid< Vtype >::updateLower(), and msm::GridFixed< T, N >::updateLower().


The documentation for this class was generated from the following file:
Generated on Sat Sep 23 01:17:22 2017 for NAMD by  doxygen 1.4.7