Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
blockDim Class Reference

#include <gridutil.h>

Inheritance diagram for blockDim:
Collaboration diagram for blockDim:

Public Member Functions

 blockDim ()
 
 blockDim (int i_, int j_, int k_)
 
int getSize (void) const
 
int c_index (int xi, int xj, int xk) const
 
int operator[] (const blockLoc &l) const
 
int & operator[] (int d)
 
int operator[] (int d) const
 
- Public Member Functions inherited from blockLoc
 blockLoc ()
 
 blockLoc (int i_, int j_, int k_)
 
blockLoc operator+ (const blockLoc &b) const
 
blockLocoperator+= (const blockLoc &b)
 
blockDim operator- (const blockLoc &b) const
 
bool operator== (const blockLoc &o) const
 
bool operator!= (const blockLoc &o) const
 
int & operator[] (int d)
 
int operator[] (int d) const
 

Additional Inherited Members

- Protected Attributes inherited from blockLoc
int i
 
int j
 
int k
 

Detailed Description

Definition at line 120 of file gridutil.h.

Constructor & Destructor Documentation

blockDim ( )
inline

Definition at line 122 of file gridutil.h.

122 { }
blockDim ( int  i_,
int  j_,
int  k_ 
)
inline

Definition at line 123 of file gridutil.h.

124  :blockLoc(i_,j_,k_)
125  { }
blockLoc()
Definition: gridutil.h:96

Member Function Documentation

int c_index ( int  xi,
int  xj,
int  xk 
) const
inline

Definition at line 129 of file gridutil.h.

References blockLoc::i, and blockLoc::j.

Referenced by operator[]().

130  { return xi+i*(xj+j*xk); }
int i
Definition: gridutil.h:94
int j
Definition: gridutil.h:94

Here is the caller graph for this function:

int getSize ( void  ) const
inline

Definition at line 126 of file gridutil.h.

References blockLoc::i, blockLoc::j, and blockLoc::k.

Referenced by blockConsumer::allocateBlock(), block::block(), isSmaller(), main(), read_general(), read_hdf(), block::subBlock(), volume(), write_fortran(), and write_hdf().

127  { return i*j*k; }
int k
Definition: gridutil.h:94
int i
Definition: gridutil.h:94
int j
Definition: gridutil.h:94

Here is the caller graph for this function:

int operator[] ( const blockLoc l) const
inline

Definition at line 133 of file gridutil.h.

References c_index().

134  { return c_index(l[0],l[1],l[2]); }
int c_index(int xi, int xj, int xk) const
Definition: gridutil.h:129

Here is the call graph for this function:

int& operator[] ( int  d)
inline

Definition at line 137 of file gridutil.h.

References d, and blockLoc::i.

137 {return (&i)[d];}
const NT & d
int i
Definition: gridutil.h:94
int operator[] ( int  d) const
inline

Definition at line 138 of file gridutil.h.

References d, and blockLoc::i.

138 {return (&i)[d];}
const NT & d
int i
Definition: gridutil.h:94

The documentation for this class was generated from the following file: