/[ascend]/trunk/base/generic/solver/mtx_basic.c
ViewVC logotype

Diff of /trunk/base/generic/solver/mtx_basic.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1174 by johnpye, Sat Jan 13 08:33:43 2007 UTC revision 1175 by johnpye, Thu Jan 18 00:34:22 2007 UTC
# Line 2839  void mtx_old_add_col_sparse(mtx_matrix_t Line 2839  void mtx_old_add_col_sparse(mtx_matrix_t
2839      mtx_renull_using_col(mtx,t_org,arr);      mtx_renull_using_col(mtx,t_org,arr);
2840    }    }
2841    mtx_null_vector_release();    mtx_null_vector_release();
2842  }  }
2843    
2844  size_t mtx_size(mtx_matrix_t mtx) {  size_t mtx_size(mtx_matrix_t mtx) {
2845    size_t size=0;    size_t size=0;
# Line 3257  void mtx_write_region_matlab(FILE *fp,mt Line 3257  void mtx_write_region_matlab(FILE *fp,mt
3257    
3258  #ifdef ASC_WITH_MMIO  #ifdef ASC_WITH_MMIO
3259  int mtx_write_region_mmio(FILE *fp,mtx_matrix_t mtx,mtx_region_t *region){  int mtx_write_region_mmio(FILE *fp,mtx_matrix_t mtx,mtx_region_t *region){
3260      MM_typecode matcode;                              MM_typecode matcode;
3261      int nrows, ncols, nnz, *perm;      int nrows, ncols, nnz, *perm;
3262      struct element_t Rewind, *elt;      struct element_t Rewind, *elt;
3263      mtx_coord_t nz;      mtx_coord_t nz;
# Line 3269  int mtx_write_region_mmio(FILE *fp,mtx_m Line 3269  int mtx_write_region_mmio(FILE *fp,mtx_m
3269      mm_set_coordinate(&matcode);      mm_set_coordinate(&matcode);
3270      mm_set_real(&matcode);      mm_set_real(&matcode);
3271    
3272      mm_write_banner(fp, matcode);      mm_write_banner(fp, matcode);
3273    
3274      if(region == mtx_ENTIRE_MATRIX)nrows = mtx->order-1;      if(region == mtx_ENTIRE_MATRIX)nrows = mtx->order-1;
3275      else nrows = region->row.high - region->row.low + 1;      else nrows = region->row.high - region->row.low + 1;
# Line 3282  int mtx_write_region_mmio(FILE *fp,mtx_m Line 3282  int mtx_write_region_mmio(FILE *fp,mtx_m
3282      fprintf(fp,"%% Matrix Market file format\n");      fprintf(fp,"%% Matrix Market file format\n");
3283      fprintf(fp,"%% see http://math.nist.gov/MatrixMarket/\n");      fprintf(fp,"%% see http://math.nist.gov/MatrixMarket/\n");
3284      fprintf(fp,"%% RANGE: rows = %d, cols = %d, num_of_non_zeros =%d\n",nrows,ncols,nnz);      fprintf(fp,"%% RANGE: rows = %d, cols = %d, num_of_non_zeros =%d\n",nrows,ncols,nnz);
3285      fprintf(fp,"%% MATRIX: rows = %d, cols = %d\n",mtx->order,mtx->order,nnz);      fprintf(fp,"%% MATRIX: rows = %d, cols = %d\n",mtx->order,mtx->order);
3286    
3287      mm_write_mtx_crd_size(fp, mtx->order, mtx->order, nnz);      mm_write_mtx_crd_size(fp, mtx->order, mtx->order, nnz);
3288        
3289      /*      /*
3290          NOTE: matrix market files use 1-based indices, i.e. first element          NOTE: matrix market files use 1-based indices, i.e. first element
3291          of a vector has index 1, not 0.          of a vector has index 1, not 0.

Legend:
Removed from v.1174  
changed lines
  Added in v.1175

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22