MOOSE - Multiscale Object Oriented Simulation Environment
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
HinesMatrix.cpp File Reference
#include "header.h"
#include "HinesMatrix.h"
#include <sstream>
#include <iomanip>
#include <stdexcept>
+ Include dependency graph for HinesMatrix.cpp:

Go to the source code of this file.

Functions

bool groupCompare (const vector< unsigned int > &A, const vector< unsigned int > &B)
 
ostream & operator<< (ostream &s, const HinesMatrix &m)
 

Function Documentation

bool groupCompare ( const vector< unsigned int > &  A,
const vector< unsigned int > &  B 
)

Definition at line 73 of file HinesMatrix.cpp.

Referenced by HinesMatrix::makeJunctions().

76 {
77  if ( A.empty() || B.empty() )
78  return 0;
79 
80  return A[ 0 ] < B[ 0 ];
81 }

+ Here is the caller graph for this function:

ostream& operator<< ( ostream &  s,
const HinesMatrix m 
)

Definition at line 449 of file HinesMatrix.cpp.

References HinesMatrix::getA(), HinesMatrix::getB(), HinesMatrix::getSize(), and HinesMatrix::getVMid().

450 {
451  unsigned int size = m.getSize();
452 
453  s << "\nA:\n";
454  for ( unsigned int i = 0; i < size; i++ )
455  {
456  for ( unsigned int j = 0; j < size; j++ )
457  s << setw( 12 ) << setprecision( 5 ) << m.getA( i, j );
458  s << "\n";
459  }
460 
461  s << "\n" << "V:\n";
462  for ( unsigned int i = 0; i < size; i++ )
463  s << m.getVMid( i ) << "\n";
464 
465  s << "\n" << "B:\n";
466  for ( unsigned int i = 0; i < size; i++ )
467  s << m.getB( i ) << "\n";
468 
469  return s;
470 }
double getVMid(unsigned int row) const
double getB(unsigned int row) const
unsigned int getSize() const
double getA(unsigned int row, unsigned int col) const

+ Here is the call graph for this function: