comparison src/DLD-FUNCTIONS/colamd.cc @ 10527:b4d2080b6df7

Replace nzmax by nnz as needed
author David Bateman <dbateman@free.fr>
date Fri, 16 Apr 2010 16:14:45 +0200
parents c9780d8e228c
children 89f4d7e294cc
comparison
equal deleted inserted replaced
10526:660c244d3206 10527:b4d2080b6df7
345 if (args(0).is_complex_type ()) 345 if (args(0).is_complex_type ())
346 { 346 {
347 scm = args(0). sparse_complex_matrix_value (); 347 scm = args(0). sparse_complex_matrix_value ();
348 n_row = scm.rows (); 348 n_row = scm.rows ();
349 n_col = scm.cols (); 349 n_col = scm.cols ();
350 nnz = scm.nzmax (); 350 nnz = scm.nnz ();
351 ridx = scm.xridx (); 351 ridx = scm.xridx ();
352 cidx = scm.xcidx (); 352 cidx = scm.xcidx ();
353 } 353 }
354 else 354 else
355 { 355 {
356 sm = args(0).sparse_matrix_value (); 356 sm = args(0).sparse_matrix_value ();
357 357
358 n_row = sm.rows (); 358 n_row = sm.rows ();
359 n_col = sm.cols (); 359 n_col = sm.cols ();
360 nnz = sm.nzmax (); 360 nnz = sm.nnz ();
361 ridx = sm.xridx (); 361 ridx = sm.xridx ();
362 cidx = sm.xcidx (); 362 cidx = sm.xcidx ();
363 } 363 }
364 } 364 }
365 else 365 else
369 else 369 else
370 sm = SparseMatrix (args(0).matrix_value ()); 370 sm = SparseMatrix (args(0).matrix_value ());
371 371
372 n_row = sm.rows (); 372 n_row = sm.rows ();
373 n_col = sm.cols (); 373 n_col = sm.cols ();
374 nnz = sm.nzmax (); 374 nnz = sm.nnz ();
375 ridx = sm.xridx (); 375 ridx = sm.xridx ();
376 cidx = sm.xcidx (); 376 cidx = sm.xcidx ();
377 } 377 }
378 378
379 // Allocate workspace for colamd 379 // Allocate workspace for colamd
554 if (args(0).is_complex_type ()) 554 if (args(0).is_complex_type ())
555 { 555 {
556 scm = args(0).sparse_complex_matrix_value (); 556 scm = args(0).sparse_complex_matrix_value ();
557 n_row = scm.rows (); 557 n_row = scm.rows ();
558 n_col = scm.cols (); 558 n_col = scm.cols ();
559 nnz = scm.nzmax (); 559 nnz = scm.nnz ();
560 ridx = scm.xridx (); 560 ridx = scm.xridx ();
561 cidx = scm.xcidx (); 561 cidx = scm.xcidx ();
562 } 562 }
563 else 563 else
564 { 564 {
565 sm = args(0).sparse_matrix_value (); 565 sm = args(0).sparse_matrix_value ();
566 n_row = sm.rows (); 566 n_row = sm.rows ();
567 n_col = sm.cols (); 567 n_col = sm.cols ();
568 nnz = sm.nzmax (); 568 nnz = sm.nnz ();
569 ridx = sm.xridx (); 569 ridx = sm.xridx ();
570 cidx = sm.xcidx (); 570 cidx = sm.xcidx ();
571 } 571 }
572 } 572 }
573 else 573 else
577 else 577 else
578 sm = SparseMatrix (args(0).matrix_value ()); 578 sm = SparseMatrix (args(0).matrix_value ());
579 579
580 n_row = sm.rows (); 580 n_row = sm.rows ();
581 n_col = sm.cols (); 581 n_col = sm.cols ();
582 nnz = sm.nzmax (); 582 nnz = sm.nnz ();
583 ridx = sm.xridx (); 583 ridx = sm.xridx ();
584 cidx = sm.xcidx (); 584 cidx = sm.xcidx ();
585 } 585 }
586 586
587 if (n_row != n_col) 587 if (n_row != n_col)
679 if (args(0).is_complex_type ()) 679 if (args(0).is_complex_type ())
680 { 680 {
681 scm = args(0).sparse_complex_matrix_value (); 681 scm = args(0).sparse_complex_matrix_value ();
682 n_row = scm.rows (); 682 n_row = scm.rows ();
683 n_col = scm.cols (); 683 n_col = scm.cols ();
684 nnz = scm.nzmax (); 684 nnz = scm.nnz ();
685 ridx = scm.xridx (); 685 ridx = scm.xridx ();
686 cidx = scm.xcidx (); 686 cidx = scm.xcidx ();
687 } 687 }
688 else 688 else
689 { 689 {
690 sm = args(0).sparse_matrix_value (); 690 sm = args(0).sparse_matrix_value ();
691 n_row = sm.rows (); 691 n_row = sm.rows ();
692 n_col = sm.cols (); 692 n_col = sm.cols ();
693 nnz = sm.nzmax (); 693 nnz = sm.nnz ();
694 ridx = sm.xridx (); 694 ridx = sm.xridx ();
695 cidx = sm.xcidx (); 695 cidx = sm.xcidx ();
696 } 696 }
697 697
698 } 698 }