Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 using namespace std;
00022
00023 #ifndef BIPARTITEGRAPHINPUTOUTPUT_H
00024 #define BIPARTITEGRAPHINPUTOUTPUT_H
00025
00026 namespace ColPack
00027 {
00036 class BipartiteGraphInputOutput : public BipartiteGraphCore
00037 {
00038 public:
00039
00041
00065 int ReadBipartiteGraph(string s_InputFile, string s_fileFormat="AUTO_DETECTED");
00066
00068
00075 int BuildBPGraphFromRowCompressedFormat(unsigned int ** uip2_JacobianSparsityPattern, int i_RowCount, int i_ColumnCount);
00076
00078
00085 int RowCompressedFormat2BipartiteGraph(unsigned int ** uip2_JacobianSparsityPattern, int i_RowCount, int i_ColumnCount);
00086
00088
00096 int BipartiteGraph2RowCompressedFormat(unsigned int *** uip3_JacobianSparsityPattern, unsigned int * uip1_RowCount, unsigned int * uip1_ColumnCount);
00097
00098
00099
00101
00120 int ReadGenericMatrixBipartiteGraph(string s_InputFile);
00121
00122
00124
00135 int ReadGenericSquareMatrixBipartiteGraph(string s_InputFile);
00136
00137
00138 private:
00139
00140
00141 void CalculateVertexDegrees();
00142
00143 public:
00144
00145
00146 BipartiteGraphInputOutput();
00147
00148
00149 ~BipartiteGraphInputOutput();
00150
00151
00152
00153 virtual void Initialize();
00154
00155
00156 virtual void Clear();
00157
00158
00160 int ReadMatrixMarketBipartiteGraph(string s_InputFile);
00161
00162
00164 int ReadMeTiSBipartiteGraph(string s_InputFile);
00165
00166
00168 int ReadHarwellBoeingBipartiteGraph(string s_InputFile);
00169
00170
00171 void PrintBipartiteGraph();
00172
00173
00174 void PrintVertexDegrees();
00175 };
00176 }
00177 #endif