SNAP Library 6.0, User Reference  2020-12-09 16:24:20
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat Struct Reference

Public Member Functions

 TCmtyDat ()
 
 TCmtyDat (const double &NodeDegFrac, const int &OutDeg)
 
void AddQ (const int &NId, const double &Q)
 
void UpdateMaxQ ()
 
void DelLink (const int &K)
 
int GetMxQNId () const
 
double GetMxQ () const
 

Public Attributes

double DegFrac
 
TIntFltH NIdQH
 
int MxQId
 

Detailed Description

Definition at line 1328 of file cmty.cpp.

Constructor & Destructor Documentation

TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::TCmtyDat ( )
inline

Definition at line 1332 of file cmty.cpp.

TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::TCmtyDat ( const double &  NodeDegFrac,
const int &  OutDeg 
)
inline

Definition at line 1333 of file cmty.cpp.

Member Function Documentation

void TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::AddQ ( const int &  NId,
const double &  Q 
)
inline

Definition at line 1335 of file cmty.cpp.

1335  {
1336  NIdQH.AddDat(NId, Q);
1337  if (MxQId == -1 || NIdQH[MxQId]<Q) { MxQId = NIdQH.GetKeyId(NId); }
1338  }
int GetKeyId(const TKey &Key) const
Definition: hash.h:466
TDat & AddDat(const TKey &Key)
Definition: hash.h:238
void TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::DelLink ( const int &  K)
inline

Definition at line 1345 of file cmty.cpp.

1345  {
1346  const int NId = GetMxQNId();
1347  NIdQH.DelKey(K); if (NId == K) { UpdateMaxQ(); }
1348  }
void DelKey(const TKey &Key)
Definition: hash.h:404
double TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::GetMxQ ( ) const
inline

Definition at line 1350 of file cmty.cpp.

int TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::GetMxQNId ( ) const
inline

Definition at line 1349 of file cmty.cpp.

1349 { return NIdQH.GetKey(MxQId); }
const TKey & GetKey(const int &KeyId) const
Definition: hash.h:252
void TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::UpdateMaxQ ( )
inline

Definition at line 1339 of file cmty.cpp.

1339  {
1340  MxQId = -1;
1341  for (int i = -1; NIdQH.FNextKeyId(i);) {
1342  if (MxQId == -1 || NIdQH[MxQId]< NIdQH[i]) { MxQId = i; }
1343  }
1344  }
bool FNextKeyId(int &KeyId) const
Definition: hash.h:478

Member Data Documentation

double TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::DegFrac

Definition at line 1329 of file cmty.cpp.

int TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::MxQId

Definition at line 1331 of file cmty.cpp.

TIntFltH TSnap::TSnapDetail::TCNMQMatrix::TCmtyDat::NIdQH

Definition at line 1330 of file cmty.cpp.


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