Mercurial > octave
comparison liboctave/array/CSparse.cc @ 21100:e39e05d90788
Switch gripe_XXX to either err_XXX or warn_XXX naming scheme.
* libinterp/corefcn/errwarn.h, libinterp/corefcn/errwarn.cc: New header and .cc
file with common errors and warnings for libinterp.
* libinterp/corefcn/module.mk: Add errwarn.h, errwarn.cc to build system.
* liboctave/util/lo-array-errwarn.h, liboctave/util/lo-array-errwarn.cc: New
header and .cc file with common errors and warnings for liboctave.
* liboctave/util/module.mk: Add lo-array-errwarn.h, lo-array-errwarn.cc to
build system.
* lo-array-gripes.h: #include "lo-array-errwarn.h" for access to class
index_exception. Remove const char *error_id_XXX prototypes.
* lo-array-gripes.cc: Remove const char *error_id_XXX initializations.
Remove index_exception method definitions.
* Cell.cc, __pchip_deriv__.cc, __qp__.cc, balance.cc, betainc.cc, cellfun.cc,
daspk.cc, dasrt.cc, dassl.cc, data.cc, debug.cc, defaults.cc, det.cc,
dirfns.cc, eig.cc, fft.cc, fft2.cc, fftn.cc, find.cc, gammainc.cc, gcd.cc,
getgrent.cc, getpwent.cc, graphics.in.h, help.cc, hess.cc, hex2num.cc,
input.cc, inv.cc, jit-typeinfo.cc, load-save.cc, lookup.cc, ls-hdf5.cc,
ls-mat-ascii.cc, ls-mat4.cc, ls-mat5.cc, ls-oct-binary.cc, ls-oct-text.cc,
lsode.cc, lu.cc, luinc.cc, max.cc, mgorth.cc, oct-hist.cc, oct-procbuf.cc,
oct-stream.cc, oct.h, pager.cc, pinv.cc, pr-output.cc, quad.cc, qz.cc, rand.cc,
rcond.cc, regexp.cc, schur.cc, sparse-xdiv.cc, sparse-xpow.cc, sparse.cc,
spparms.cc, sqrtm.cc, str2double.cc, strfind.cc, strfns.cc, sub2ind.cc, svd.cc,
sylvester.cc, syscalls.cc, typecast.cc, utils.cc, variables.cc, xdiv.cc,
xnorm.cc, xpow.cc, __eigs__.cc, __glpk__.cc, __magick_read__.cc,
__osmesa_print__.cc, audiodevinfo.cc, audioread.cc, chol.cc, dmperm.cc,
fftw.cc, qr.cc, symbfact.cc, symrcm.cc, ov-base-diag.cc, ov-base-int.cc,
ov-base-mat.cc, ov-base-scalar.cc, ov-base-sparse.cc, ov-base.cc,
ov-bool-mat.cc, ov-bool-sparse.cc, ov-bool.cc, ov-builtin.cc, ov-cell.cc,
ov-ch-mat.cc, ov-class.cc, ov-complex.cc, ov-complex.h, ov-cs-list.cc,
ov-cx-diag.cc, ov-cx-mat.cc, ov-cx-sparse.cc, ov-fcn-handle.cc,
ov-fcn-inline.cc, ov-float.cc, ov-float.h, ov-flt-complex.cc, ov-flt-complex.h,
ov-flt-cx-diag.cc, ov-flt-cx-mat.cc, ov-flt-re-mat.cc, ov-int16.cc,
ov-int32.cc, ov-int64.cc, ov-int8.cc, ov-intx.h, ov-mex-fcn.cc, ov-perm.cc,
ov-range.cc, ov-re-mat.cc, ov-re-sparse.cc, ov-scalar.cc, ov-scalar.h,
ov-str-mat.cc, ov-struct.cc, ov-type-conv.h, ov-uint16.cc, ov-uint32.cc,
ov-uint64.cc, ov-uint8.cc, ov-usr-fcn.cc, ov.cc, op-b-b.cc, op-b-bm.cc,
op-b-sbm.cc, op-bm-b.cc, op-bm-bm.cc, op-bm-sbm.cc, op-cdm-cdm.cc, op-cell.cc,
op-chm.cc, op-class.cc, op-cm-cm.cc, op-cm-cs.cc, op-cm-m.cc, op-cm-s.cc,
op-cm-scm.cc, op-cm-sm.cc, op-cs-cm.cc, op-cs-cs.cc, op-cs-m.cc, op-cs-s.cc,
op-cs-scm.cc, op-cs-sm.cc, op-dm-dm.cc, op-dm-scm.cc, op-dm-sm.cc,
op-dms-template.cc, op-double-conv.cc, op-fcdm-fcdm.cc, op-fcdm-fdm.cc,
op-fcm-fcm.cc, op-fcm-fcs.cc, op-fcm-fm.cc, op-fcm-fs.cc, op-fcn.cc,
op-fcs-fcm.cc, op-fcs-fcs.cc, op-fcs-fm.cc, op-fcs-fs.cc, op-fdm-fdm.cc,
op-float-conv.cc, op-fm-fcm.cc, op-fm-fcs.cc, op-fm-fm.cc, op-fm-fs.cc,
op-fs-fcm.cc, op-fs-fcs.cc, op-fs-fm.cc, op-fs-fs.cc, op-i16-i16.cc,
op-i32-i32.cc, op-i64-i64.cc, op-i8-i8.cc, op-int-concat.cc, op-int-conv.cc,
op-int.h, op-m-cm.cc, op-m-cs.cc, op-m-m.cc, op-m-s.cc, op-m-scm.cc,
op-m-sm.cc, op-pm-pm.cc, op-pm-scm.cc, op-pm-sm.cc, op-range.cc, op-s-cm.cc,
op-s-cs.cc, op-s-m.cc, op-s-s.cc, op-s-scm.cc, op-s-sm.cc, op-sbm-b.cc,
op-sbm-bm.cc, op-sbm-sbm.cc, op-scm-cm.cc, op-scm-cs.cc, op-scm-m.cc,
op-scm-s.cc, op-scm-scm.cc, op-scm-sm.cc, op-sm-cm.cc, op-sm-cs.cc, op-sm-m.cc,
op-sm-s.cc, op-sm-scm.cc, op-sm-sm.cc, op-str-m.cc, op-str-s.cc, op-str-str.cc,
op-struct.cc, op-ui16-ui16.cc, op-ui32-ui32.cc, op-ui64-ui64.cc, op-ui8-ui8.cc,
ops.h, lex.ll, pt-assign.cc, pt-eval.cc, pt-idx.cc, pt-loop.cc, pt-mat.cc,
pt-stmt.cc, Array-util.cc, Array-util.h, Array.cc, CColVector.cc,
CDiagMatrix.cc, CMatrix.cc, CNDArray.cc, CRowVector.cc, CSparse.cc,
DiagArray2.cc, MDiagArray2.cc, MSparse.cc, PermMatrix.cc, Range.cc, Sparse.cc,
dColVector.cc, dDiagMatrix.cc, dMatrix.cc, dNDArray.cc, dRowVector.cc,
dSparse.cc, fCColVector.cc, fCDiagMatrix.cc, fCMatrix.cc, fCNDArray.cc,
fCRowVector.cc, fColVector.cc, fDiagMatrix.cc, fMatrix.cc, fNDArray.cc,
fRowVector.cc, idx-vector.cc, CmplxGEPBAL.cc, dbleGEPBAL.cc, fCmplxGEPBAL.cc,
floatGEPBAL.cc, Sparse-diag-op-defs.h, Sparse-op-defs.h, Sparse-perm-op-defs.h,
mx-inlines.cc, mx-op-defs.h, oct-binmap.h:
Replace 'include "gripes.h"' with 'include "errwarn.h". Change all gripe_XXX
to err_XXX or warn_XXX or errwarn_XXX.
author | Rik <rik@octave.org> |
---|---|
date | Mon, 18 Jan 2016 18:28:06 -0800 |
parents | 77f5591878bf |
children | bd1752782e56 |
comparison
equal
deleted
inserted
replaced
21099:52af4092f863 | 21100:e39e05d90788 |
---|---|
1796 { | 1796 { |
1797 sing_handler (rcond); | 1797 sing_handler (rcond); |
1798 mattype.mark_as_rectangular (); | 1798 mattype.mark_as_rectangular (); |
1799 } | 1799 } |
1800 else | 1800 else |
1801 gripe_singular_matrix (rcond); | 1801 errwarn_singular_matrix (rcond); |
1802 } | 1802 } |
1803 | 1803 |
1804 volatile double rcond_plus_one = rcond + 1.0; | 1804 volatile double rcond_plus_one = rcond + 1.0; |
1805 | 1805 |
1806 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 1806 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
1811 { | 1811 { |
1812 sing_handler (rcond); | 1812 sing_handler (rcond); |
1813 mattype.mark_as_rectangular (); | 1813 mattype.mark_as_rectangular (); |
1814 } | 1814 } |
1815 else | 1815 else |
1816 gripe_singular_matrix (rcond); | 1816 errwarn_singular_matrix (rcond); |
1817 } | 1817 } |
1818 } | 1818 } |
1819 else | 1819 else |
1820 (*current_liboctave_error_handler) ("incorrect matrix type"); | 1820 (*current_liboctave_error_handler) ("incorrect matrix type"); |
1821 } | 1821 } |
2079 { | 2079 { |
2080 sing_handler (rcond); | 2080 sing_handler (rcond); |
2081 mattype.mark_as_rectangular (); | 2081 mattype.mark_as_rectangular (); |
2082 } | 2082 } |
2083 else | 2083 else |
2084 gripe_singular_matrix (rcond); | 2084 errwarn_singular_matrix (rcond); |
2085 } | 2085 } |
2086 | 2086 |
2087 volatile double rcond_plus_one = rcond + 1.0; | 2087 volatile double rcond_plus_one = rcond + 1.0; |
2088 | 2088 |
2089 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 2089 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
2094 { | 2094 { |
2095 sing_handler (rcond); | 2095 sing_handler (rcond); |
2096 mattype.mark_as_rectangular (); | 2096 mattype.mark_as_rectangular (); |
2097 } | 2097 } |
2098 else | 2098 else |
2099 gripe_singular_matrix (rcond); | 2099 errwarn_singular_matrix (rcond); |
2100 } | 2100 } |
2101 } | 2101 } |
2102 else | 2102 else |
2103 (*current_liboctave_error_handler) ("incorrect matrix type"); | 2103 (*current_liboctave_error_handler) ("incorrect matrix type"); |
2104 } | 2104 } |
2309 { | 2309 { |
2310 sing_handler (rcond); | 2310 sing_handler (rcond); |
2311 mattype.mark_as_rectangular (); | 2311 mattype.mark_as_rectangular (); |
2312 } | 2312 } |
2313 else | 2313 else |
2314 gripe_singular_matrix (rcond); | 2314 errwarn_singular_matrix (rcond); |
2315 } | 2315 } |
2316 | 2316 |
2317 volatile double rcond_plus_one = rcond + 1.0; | 2317 volatile double rcond_plus_one = rcond + 1.0; |
2318 | 2318 |
2319 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 2319 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
2324 { | 2324 { |
2325 sing_handler (rcond); | 2325 sing_handler (rcond); |
2326 mattype.mark_as_rectangular (); | 2326 mattype.mark_as_rectangular (); |
2327 } | 2327 } |
2328 else | 2328 else |
2329 gripe_singular_matrix (rcond); | 2329 errwarn_singular_matrix (rcond); |
2330 } | 2330 } |
2331 } | 2331 } |
2332 else | 2332 else |
2333 (*current_liboctave_error_handler) ("incorrect matrix type"); | 2333 (*current_liboctave_error_handler) ("incorrect matrix type"); |
2334 } | 2334 } |
2592 { | 2592 { |
2593 sing_handler (rcond); | 2593 sing_handler (rcond); |
2594 mattype.mark_as_rectangular (); | 2594 mattype.mark_as_rectangular (); |
2595 } | 2595 } |
2596 else | 2596 else |
2597 gripe_singular_matrix (rcond); | 2597 errwarn_singular_matrix (rcond); |
2598 } | 2598 } |
2599 | 2599 |
2600 volatile double rcond_plus_one = rcond + 1.0; | 2600 volatile double rcond_plus_one = rcond + 1.0; |
2601 | 2601 |
2602 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 2602 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
2607 { | 2607 { |
2608 sing_handler (rcond); | 2608 sing_handler (rcond); |
2609 mattype.mark_as_rectangular (); | 2609 mattype.mark_as_rectangular (); |
2610 } | 2610 } |
2611 else | 2611 else |
2612 gripe_singular_matrix (rcond); | 2612 errwarn_singular_matrix (rcond); |
2613 } | 2613 } |
2614 } | 2614 } |
2615 else | 2615 else |
2616 (*current_liboctave_error_handler) ("incorrect matrix type"); | 2616 (*current_liboctave_error_handler) ("incorrect matrix type"); |
2617 } | 2617 } |
2842 { | 2842 { |
2843 sing_handler (rcond); | 2843 sing_handler (rcond); |
2844 mattype.mark_as_rectangular (); | 2844 mattype.mark_as_rectangular (); |
2845 } | 2845 } |
2846 else | 2846 else |
2847 gripe_singular_matrix (rcond); | 2847 errwarn_singular_matrix (rcond); |
2848 } | 2848 } |
2849 | 2849 |
2850 volatile double rcond_plus_one = rcond + 1.0; | 2850 volatile double rcond_plus_one = rcond + 1.0; |
2851 | 2851 |
2852 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 2852 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
2857 { | 2857 { |
2858 sing_handler (rcond); | 2858 sing_handler (rcond); |
2859 mattype.mark_as_rectangular (); | 2859 mattype.mark_as_rectangular (); |
2860 } | 2860 } |
2861 else | 2861 else |
2862 gripe_singular_matrix (rcond); | 2862 errwarn_singular_matrix (rcond); |
2863 } | 2863 } |
2864 } | 2864 } |
2865 else | 2865 else |
2866 (*current_liboctave_error_handler) ("incorrect matrix type"); | 2866 (*current_liboctave_error_handler) ("incorrect matrix type"); |
2867 } | 2867 } |
3144 { | 3144 { |
3145 sing_handler (rcond); | 3145 sing_handler (rcond); |
3146 mattype.mark_as_rectangular (); | 3146 mattype.mark_as_rectangular (); |
3147 } | 3147 } |
3148 else | 3148 else |
3149 gripe_singular_matrix (rcond); | 3149 errwarn_singular_matrix (rcond); |
3150 } | 3150 } |
3151 | 3151 |
3152 volatile double rcond_plus_one = rcond + 1.0; | 3152 volatile double rcond_plus_one = rcond + 1.0; |
3153 | 3153 |
3154 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 3154 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
3159 { | 3159 { |
3160 sing_handler (rcond); | 3160 sing_handler (rcond); |
3161 mattype.mark_as_rectangular (); | 3161 mattype.mark_as_rectangular (); |
3162 } | 3162 } |
3163 else | 3163 else |
3164 gripe_singular_matrix (rcond); | 3164 errwarn_singular_matrix (rcond); |
3165 } | 3165 } |
3166 } | 3166 } |
3167 else | 3167 else |
3168 (*current_liboctave_error_handler) ("incorrect matrix type"); | 3168 (*current_liboctave_error_handler) ("incorrect matrix type"); |
3169 } | 3169 } |
3398 { | 3398 { |
3399 sing_handler (rcond); | 3399 sing_handler (rcond); |
3400 mattype.mark_as_rectangular (); | 3400 mattype.mark_as_rectangular (); |
3401 } | 3401 } |
3402 else | 3402 else |
3403 gripe_singular_matrix (rcond); | 3403 errwarn_singular_matrix (rcond); |
3404 } | 3404 } |
3405 | 3405 |
3406 volatile double rcond_plus_one = rcond + 1.0; | 3406 volatile double rcond_plus_one = rcond + 1.0; |
3407 | 3407 |
3408 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 3408 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
3413 { | 3413 { |
3414 sing_handler (rcond); | 3414 sing_handler (rcond); |
3415 mattype.mark_as_rectangular (); | 3415 mattype.mark_as_rectangular (); |
3416 } | 3416 } |
3417 else | 3417 else |
3418 gripe_singular_matrix (rcond); | 3418 errwarn_singular_matrix (rcond); |
3419 } | 3419 } |
3420 } | 3420 } |
3421 else | 3421 else |
3422 (*current_liboctave_error_handler) ("incorrect matrix type"); | 3422 (*current_liboctave_error_handler) ("incorrect matrix type"); |
3423 } | 3423 } |
3699 { | 3699 { |
3700 sing_handler (rcond); | 3700 sing_handler (rcond); |
3701 mattype.mark_as_rectangular (); | 3701 mattype.mark_as_rectangular (); |
3702 } | 3702 } |
3703 else | 3703 else |
3704 gripe_singular_matrix (rcond); | 3704 errwarn_singular_matrix (rcond); |
3705 } | 3705 } |
3706 | 3706 |
3707 volatile double rcond_plus_one = rcond + 1.0; | 3707 volatile double rcond_plus_one = rcond + 1.0; |
3708 | 3708 |
3709 if (rcond_plus_one == 1.0 || xisnan (rcond)) | 3709 if (rcond_plus_one == 1.0 || xisnan (rcond)) |
3714 { | 3714 { |
3715 sing_handler (rcond); | 3715 sing_handler (rcond); |
3716 mattype.mark_as_rectangular (); | 3716 mattype.mark_as_rectangular (); |
3717 } | 3717 } |
3718 else | 3718 else |
3719 gripe_singular_matrix (rcond); | 3719 errwarn_singular_matrix (rcond); |
3720 } | 3720 } |
3721 } | 3721 } |
3722 else | 3722 else |
3723 (*current_liboctave_error_handler) ("incorrect matrix type"); | 3723 (*current_liboctave_error_handler) ("incorrect matrix type"); |
3724 } | 3724 } |
3861 { | 3861 { |
3862 sing_handler (rcond); | 3862 sing_handler (rcond); |
3863 mattype.mark_as_rectangular (); | 3863 mattype.mark_as_rectangular (); |
3864 } | 3864 } |
3865 else | 3865 else |
3866 gripe_singular_matrix (); | 3866 errwarn_singular_matrix (); |
3867 | 3867 |
3868 } | 3868 } |
3869 else | 3869 else |
3870 rcond = 1.; | 3870 rcond = 1.; |
3871 } | 3871 } |
3958 { | 3958 { |
3959 sing_handler (rcond); | 3959 sing_handler (rcond); |
3960 mattype.mark_as_rectangular (); | 3960 mattype.mark_as_rectangular (); |
3961 } | 3961 } |
3962 else | 3962 else |
3963 gripe_singular_matrix (); | 3963 errwarn_singular_matrix (); |
3964 } | 3964 } |
3965 else | 3965 else |
3966 { | 3966 { |
3967 char job = 'N'; | 3967 char job = 'N'; |
3968 volatile octave_idx_type x_nz = b.nnz (); | 3968 volatile octave_idx_type x_nz = b.nnz (); |
4160 { | 4160 { |
4161 sing_handler (rcond); | 4161 sing_handler (rcond); |
4162 mattype.mark_as_rectangular (); | 4162 mattype.mark_as_rectangular (); |
4163 } | 4163 } |
4164 else | 4164 else |
4165 gripe_singular_matrix (); | 4165 errwarn_singular_matrix (); |
4166 } | 4166 } |
4167 } | 4167 } |
4168 else if (typ != MatrixType::Tridiagonal_Hermitian) | 4168 else if (typ != MatrixType::Tridiagonal_Hermitian) |
4169 (*current_liboctave_error_handler) ("incorrect matrix type"); | 4169 (*current_liboctave_error_handler) ("incorrect matrix type"); |
4170 } | 4170 } |
4255 { | 4255 { |
4256 sing_handler (rcond); | 4256 sing_handler (rcond); |
4257 mattype.mark_as_rectangular (); | 4257 mattype.mark_as_rectangular (); |
4258 } | 4258 } |
4259 else | 4259 else |
4260 gripe_singular_matrix (); | 4260 errwarn_singular_matrix (); |
4261 } | 4261 } |
4262 else | 4262 else |
4263 { | 4263 { |
4264 rcond = 1.; | 4264 rcond = 1.; |
4265 char job = 'N'; | 4265 char job = 'N'; |
4424 { | 4424 { |
4425 sing_handler (rcond); | 4425 sing_handler (rcond); |
4426 mattype.mark_as_rectangular (); | 4426 mattype.mark_as_rectangular (); |
4427 } | 4427 } |
4428 else | 4428 else |
4429 gripe_singular_matrix (rcond); | 4429 errwarn_singular_matrix (rcond); |
4430 } | 4430 } |
4431 } | 4431 } |
4432 else | 4432 else |
4433 rcond = 1.0; | 4433 rcond = 1.0; |
4434 | 4434 |
4509 { | 4509 { |
4510 sing_handler (rcond); | 4510 sing_handler (rcond); |
4511 mattype.mark_as_rectangular (); | 4511 mattype.mark_as_rectangular (); |
4512 } | 4512 } |
4513 else | 4513 else |
4514 gripe_singular_matrix (); | 4514 errwarn_singular_matrix (); |
4515 } | 4515 } |
4516 else | 4516 else |
4517 { | 4517 { |
4518 if (calc_cond) | 4518 if (calc_cond) |
4519 { | 4519 { |
4542 { | 4542 { |
4543 sing_handler (rcond); | 4543 sing_handler (rcond); |
4544 mattype.mark_as_rectangular (); | 4544 mattype.mark_as_rectangular (); |
4545 } | 4545 } |
4546 else | 4546 else |
4547 gripe_singular_matrix (rcond); | 4547 errwarn_singular_matrix (rcond); |
4548 } | 4548 } |
4549 } | 4549 } |
4550 else | 4550 else |
4551 rcond = 1.; | 4551 rcond = 1.; |
4552 | 4552 |
4666 { | 4666 { |
4667 sing_handler (rcond); | 4667 sing_handler (rcond); |
4668 mattype.mark_as_rectangular (); | 4668 mattype.mark_as_rectangular (); |
4669 } | 4669 } |
4670 else | 4670 else |
4671 gripe_singular_matrix (rcond); | 4671 errwarn_singular_matrix (rcond); |
4672 } | 4672 } |
4673 } | 4673 } |
4674 else | 4674 else |
4675 rcond = 1.0; | 4675 rcond = 1.0; |
4676 | 4676 |
4784 { | 4784 { |
4785 sing_handler (rcond); | 4785 sing_handler (rcond); |
4786 mattype.mark_as_rectangular (); | 4786 mattype.mark_as_rectangular (); |
4787 } | 4787 } |
4788 else | 4788 else |
4789 gripe_singular_matrix (); | 4789 errwarn_singular_matrix (); |
4790 } | 4790 } |
4791 else | 4791 else |
4792 { | 4792 { |
4793 if (calc_cond) | 4793 if (calc_cond) |
4794 { | 4794 { |
4817 { | 4817 { |
4818 sing_handler (rcond); | 4818 sing_handler (rcond); |
4819 mattype.mark_as_rectangular (); | 4819 mattype.mark_as_rectangular (); |
4820 } | 4820 } |
4821 else | 4821 else |
4822 gripe_singular_matrix (rcond); | 4822 errwarn_singular_matrix (rcond); |
4823 } | 4823 } |
4824 } | 4824 } |
4825 else | 4825 else |
4826 rcond = 1.; | 4826 rcond = 1.; |
4827 | 4827 |
4980 { | 4980 { |
4981 sing_handler (rcond); | 4981 sing_handler (rcond); |
4982 mattype.mark_as_rectangular (); | 4982 mattype.mark_as_rectangular (); |
4983 } | 4983 } |
4984 else | 4984 else |
4985 gripe_singular_matrix (rcond); | 4985 errwarn_singular_matrix (rcond); |
4986 } | 4986 } |
4987 } | 4987 } |
4988 else | 4988 else |
4989 rcond = 1.0; | 4989 rcond = 1.0; |
4990 | 4990 |
5063 { | 5063 { |
5064 sing_handler (rcond); | 5064 sing_handler (rcond); |
5065 mattype.mark_as_rectangular (); | 5065 mattype.mark_as_rectangular (); |
5066 } | 5066 } |
5067 else | 5067 else |
5068 gripe_singular_matrix (); | 5068 errwarn_singular_matrix (); |
5069 } | 5069 } |
5070 else | 5070 else |
5071 { | 5071 { |
5072 if (calc_cond) | 5072 if (calc_cond) |
5073 { | 5073 { |
5096 { | 5096 { |
5097 sing_handler (rcond); | 5097 sing_handler (rcond); |
5098 mattype.mark_as_rectangular (); | 5098 mattype.mark_as_rectangular (); |
5099 } | 5099 } |
5100 else | 5100 else |
5101 gripe_singular_matrix (rcond); | 5101 errwarn_singular_matrix (rcond); |
5102 } | 5102 } |
5103 } | 5103 } |
5104 else | 5104 else |
5105 rcond = 1.; | 5105 rcond = 1.; |
5106 | 5106 |
5222 { | 5222 { |
5223 sing_handler (rcond); | 5223 sing_handler (rcond); |
5224 mattype.mark_as_rectangular (); | 5224 mattype.mark_as_rectangular (); |
5225 } | 5225 } |
5226 else | 5226 else |
5227 gripe_singular_matrix (rcond); | 5227 errwarn_singular_matrix (rcond); |
5228 } | 5228 } |
5229 } | 5229 } |
5230 else | 5230 else |
5231 rcond = 1.0; | 5231 rcond = 1.0; |
5232 | 5232 |
5345 { | 5345 { |
5346 sing_handler (rcond); | 5346 sing_handler (rcond); |
5347 mattype.mark_as_rectangular (); | 5347 mattype.mark_as_rectangular (); |
5348 } | 5348 } |
5349 else | 5349 else |
5350 gripe_singular_matrix (); | 5350 errwarn_singular_matrix (); |
5351 } | 5351 } |
5352 else | 5352 else |
5353 { | 5353 { |
5354 if (calc_cond) | 5354 if (calc_cond) |
5355 { | 5355 { |
5378 { | 5378 { |
5379 sing_handler (rcond); | 5379 sing_handler (rcond); |
5380 mattype.mark_as_rectangular (); | 5380 mattype.mark_as_rectangular (); |
5381 } | 5381 } |
5382 else | 5382 else |
5383 gripe_singular_matrix (rcond); | 5383 errwarn_singular_matrix (rcond); |
5384 } | 5384 } |
5385 } | 5385 } |
5386 else | 5386 else |
5387 rcond = 1.; | 5387 rcond = 1.; |
5388 | 5388 |
5531 err = -2; | 5531 err = -2; |
5532 | 5532 |
5533 if (sing_handler) | 5533 if (sing_handler) |
5534 sing_handler (rcond); | 5534 sing_handler (rcond); |
5535 else | 5535 else |
5536 gripe_singular_matrix (rcond); | 5536 errwarn_singular_matrix (rcond); |
5537 } | 5537 } |
5538 else if (status < 0) | 5538 else if (status < 0) |
5539 { | 5539 { |
5540 (*current_liboctave_error_handler) | 5540 (*current_liboctave_error_handler) |
5541 ("SparseComplexMatrix::solve numeric factorization failed"); | 5541 ("SparseComplexMatrix::solve numeric factorization failed"); |
5679 { | 5679 { |
5680 sing_handler (rcond); | 5680 sing_handler (rcond); |
5681 mattype.mark_as_rectangular (); | 5681 mattype.mark_as_rectangular (); |
5682 } | 5682 } |
5683 else | 5683 else |
5684 gripe_singular_matrix (rcond); | 5684 errwarn_singular_matrix (rcond); |
5685 | 5685 |
5686 return retval; | 5686 return retval; |
5687 } | 5687 } |
5688 | 5688 |
5689 cholmod_dense *X; | 5689 cholmod_dense *X; |
5930 { | 5930 { |
5931 sing_handler (rcond); | 5931 sing_handler (rcond); |
5932 mattype.mark_as_rectangular (); | 5932 mattype.mark_as_rectangular (); |
5933 } | 5933 } |
5934 else | 5934 else |
5935 gripe_singular_matrix (rcond); | 5935 errwarn_singular_matrix (rcond); |
5936 | 5936 |
5937 return retval; | 5937 return retval; |
5938 } | 5938 } |
5939 | 5939 |
5940 cholmod_sparse *X; | 5940 cholmod_sparse *X; |
6209 { | 6209 { |
6210 sing_handler (rcond); | 6210 sing_handler (rcond); |
6211 mattype.mark_as_rectangular (); | 6211 mattype.mark_as_rectangular (); |
6212 } | 6212 } |
6213 else | 6213 else |
6214 gripe_singular_matrix (rcond); | 6214 errwarn_singular_matrix (rcond); |
6215 | 6215 |
6216 return retval; | 6216 return retval; |
6217 } | 6217 } |
6218 | 6218 |
6219 cholmod_dense *X; | 6219 cholmod_dense *X; |
6439 { | 6439 { |
6440 sing_handler (rcond); | 6440 sing_handler (rcond); |
6441 mattype.mark_as_rectangular (); | 6441 mattype.mark_as_rectangular (); |
6442 } | 6442 } |
6443 else | 6443 else |
6444 gripe_singular_matrix (rcond); | 6444 errwarn_singular_matrix (rcond); |
6445 | 6445 |
6446 return retval; | 6446 return retval; |
6447 } | 6447 } |
6448 | 6448 |
6449 cholmod_sparse *X; | 6449 cholmod_sparse *X; |
6568 err = -2; | 6568 err = -2; |
6569 | 6569 |
6570 if (sing_handler) | 6570 if (sing_handler) |
6571 sing_handler (rcond); | 6571 sing_handler (rcond); |
6572 else | 6572 else |
6573 gripe_singular_matrix (rcond); | 6573 errwarn_singular_matrix (rcond); |
6574 } | 6574 } |
6575 | 6575 |
6576 UMFPACK_ZNAME (report_info) (control, info); | 6576 UMFPACK_ZNAME (report_info) (control, info); |
6577 | 6577 |
6578 UMFPACK_ZNAME (free_numeric) (&Numeric); | 6578 UMFPACK_ZNAME (free_numeric) (&Numeric); |
7116 // unary operations | 7116 // unary operations |
7117 SparseBoolMatrix | 7117 SparseBoolMatrix |
7118 SparseComplexMatrix::operator ! (void) const | 7118 SparseComplexMatrix::operator ! (void) const |
7119 { | 7119 { |
7120 if (any_element_is_nan ()) | 7120 if (any_element_is_nan ()) |
7121 gripe_nan_to_logical_conversion (); | 7121 err_nan_to_logical_conversion (); |
7122 | 7122 |
7123 octave_idx_type nr = rows (); | 7123 octave_idx_type nr = rows (); |
7124 octave_idx_type nc = cols (); | 7124 octave_idx_type nc = cols (); |
7125 octave_idx_type nz1 = nnz (); | 7125 octave_idx_type nz1 = nnz (); |
7126 octave_idx_type nz2 = nr*nc - nz1; | 7126 octave_idx_type nz2 = nr*nc - nz1; |
7678 if (a_nr == 0 || a_nc == 0) | 7678 if (a_nr == 0 || a_nc == 0) |
7679 r.resize (a_nr, a_nc); | 7679 r.resize (a_nr, a_nc); |
7680 else if (b_nr == 0 || b_nc == 0) | 7680 else if (b_nr == 0 || b_nc == 0) |
7681 r.resize (b_nr, b_nc); | 7681 r.resize (b_nr, b_nc); |
7682 else | 7682 else |
7683 gripe_nonconformant ("min", a_nr, a_nc, b_nr, b_nc); | 7683 err_nonconformant ("min", a_nr, a_nc, b_nr, b_nc); |
7684 } | 7684 } |
7685 | 7685 |
7686 return r; | 7686 return r; |
7687 } | 7687 } |
7688 | 7688 |
7795 if (a_nr == 0 || a_nc == 0) | 7795 if (a_nr == 0 || a_nc == 0) |
7796 r.resize (a_nr, a_nc); | 7796 r.resize (a_nr, a_nc); |
7797 else if (b_nr == 0 || b_nc == 0) | 7797 else if (b_nr == 0 || b_nc == 0) |
7798 r.resize (b_nr, b_nc); | 7798 r.resize (b_nr, b_nc); |
7799 else | 7799 else |
7800 gripe_nonconformant ("max", a_nr, a_nc, b_nr, b_nc); | 7800 err_nonconformant ("max", a_nr, a_nc, b_nr, b_nc); |
7801 } | 7801 } |
7802 | 7802 |
7803 return r; | 7803 return r; |
7804 } | 7804 } |
7805 | 7805 |