C-XSC - A C++ Class Library for Extended Scientific Computing 2.5.4
l_rmatrix.hpp
1/*
2** CXSC is a C++ library for eXtended Scientific Computing (V 2.5.4)
3**
4** Copyright (C) 1990-2000 Institut fuer Angewandte Mathematik,
5** Universitaet Karlsruhe, Germany
6** (C) 2000-2014 Wiss. Rechnen/Softwaretechnologie
7** Universitaet Wuppertal, Germany
8**
9** This library is free software; you can redistribute it and/or
10** modify it under the terms of the GNU Library General Public
11** License as published by the Free Software Foundation; either
12** version 2 of the License, or (at your option) any later version.
13**
14** This library is distributed in the hope that it will be useful,
15** but WITHOUT ANY WARRANTY; without even the implied warranty of
16** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17** Library General Public License for more details.
18**
19** You should have received a copy of the GNU Library General Public
20** License along with this library; if not, write to the Free
21** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22*/
23
24/* CVS $Id: l_rmatrix.hpp,v 1.20 2014/01/30 17:23:46 cxsc Exp $ */
25
26#ifndef _CXSC_LRMATRIX_HPP_INCLUDED
27#define _CXSC_LRMATRIX_HPP_INCLUDED
28
29#include "xscclass.hpp"
30#include "dot.hpp"
31#include "idot.hpp"
32#include "l_rvector.hpp"
33#include "except.hpp"
34#include "matrix.hpp"
35#include "rmatrix.hpp"
36
37namespace cxsc {
38
39class l_rmatrix;
40class l_rmatrix_slice;
41
43
47{
48 friend class l_rvector;
49 friend class l_ivector;
50 friend class l_rmatrix;
51 friend class l_rmatrix_slice;
52 private:
53 l_real *dat;
54 int lb,ub;
55 int size,start,offset; // start=first element index 0..n-1
56
57 public:
59 friend INLINE l_rmatrix_subv Row(l_rmatrix &m,const int &i)
60#if(CXSC_INDEX_CHECK)
61;
62#else
63 noexcept;
64#endif
66 friend INLINE l_rmatrix_subv Col(l_rmatrix &m,const int &i)
67#if(CXSC_INDEX_CHECK)
68;
69#else
70 noexcept;
71#endif
73 friend INLINE l_rmatrix_subv Row(const l_rmatrix &m,const int &i)
74#if(CXSC_INDEX_CHECK)
75;
76#else
77 noexcept;
78#endif
80 friend INLINE l_rmatrix_subv Col(const l_rmatrix &m,const int &i)
81#if(CXSC_INDEX_CHECK)
82;
83#else
84 noexcept;
85#endif
86//#if(CXSC_INDEX_CHECK)
87
88template<typename S, typename T>
89friend inline void addDot(const S &x, const T &y, dotprecision &val);
90
91
92#ifdef _CXSC_FRIEND_TPL
93 //----------------- Templates ---------------------------------------
94template <class MV1,class MV2> friend MV1 &_mvmvassign(MV1 &v,const MV2 &rv)
95#if(CXSC_INDEX_CHECK)
96;
97#else
98 noexcept;
99#endif
100template <class MV,class S> friend MV &_mvsassign(MV &v,const S &r) noexcept;
101template <class MV,class V> friend MV &_mvvassign(MV &v,const V &rv)
102#if(CXSC_INDEX_CHECK)
103;
104#else
105 noexcept;
106#endif
107template <class V,class MV2,class S> friend V &_vmvassign(V &v,const MV2 &rv) noexcept;
108template <class MV,class V> friend V _mvabs(const MV &mv) noexcept;
109template <class DP,class V,class SV> friend void _vmvaccu(DP &dp, const V & rv1, const SV &rv2)
110#if(CXSC_INDEX_CHECK)
111 ;
112#else
113 noexcept;
114#endif
115template <class DP,class MV1,class MV2> friend void _mvmvaccu(DP &dp, const MV1 & rv1, const MV2 &rv2)
116#if(CXSC_INDEX_CHECK)
117 ;
118#else
119 noexcept;
120#endif
121
122
123 template <class MV1,class MV2,class S> friend S _mvmvlmult(const MV1 & rv1, const MV2 &rv2)
124#if(CXSC_INDEX_CHECK)
125 ;
126#else
127 noexcept;
128#endif
129 template <class V,class MV,class S> friend S _vmvlmult(const V &rv1, const MV &rv2)
130#if(CXSC_INDEX_CHECK)
131 ;
132#else
133 noexcept;
134#endif
135 template <class MV,class S,class E> friend E _mvsmult(const MV &rv, const S &s) noexcept;
136 template <class MV1,class MV2,class E> friend E _mvmvplus(const MV1 &rv1, const MV2 &rv2)
137#if(CXSC_INDEX_CHECK)
138 ;
139#else
140 noexcept;
141#endif
142 template <class MV1,class MV2,class E> friend E _mvmvminus(const MV1 &rv1, const MV2 &rv2)
143#if(CXSC_INDEX_CHECK)
144 ;
145#else
146 noexcept;
147#endif
148 template <class MV,class V,class E> friend E _mvvplus(const MV &rv1, const V &rv2)
149#if(CXSC_INDEX_CHECK)
150 ;
151#else
152 noexcept;
153#endif
154 template <class MV,class V,class E> friend E _mvvminus(const MV &rv1, const V &rv2)
155#if(CXSC_INDEX_CHECK)
156 ;
157#else
158 noexcept;
159#endif
160 template <class V,class MV,class E> friend E _vmvminus(const V &rv1, const MV &rv2)
161#if(CXSC_INDEX_CHECK)
162 ;
163#else
164 noexcept;
165#endif
166 template <class MV,class S,class E> friend E _mvsdiv(const MV &rv, const S &s) noexcept;
167template <class MV,class S> friend MV &_mvsmultassign(MV &v,const S &r) noexcept;
168template <class MV, class S> friend MV &_mvsplusassign(MV &v,const S &r) noexcept;
169template <class MV,class S> friend MV &_mvsminusassign(MV &v,const S &r) noexcept;
170template <class MV,class S> friend MV &_mvsdivassign(MV &v,const S &r) noexcept;
171template <class MV,class V> friend MV &_mvvplusassign(MV &v,const V &rv)
172#if(CXSC_INDEX_CHECK)
173;
174#else
175 noexcept;
176#endif
177template <class V,class MV> friend V &_vmvplusassign(V &rv,const MV &v)
178#if(CXSC_INDEX_CHECK)
179;
180#else
181 noexcept;
182#endif
183template <class MV,class V> friend MV &_mvvminusassign(MV &v,const V &rv)
184#if(CXSC_INDEX_CHECK)
185;
186#else
187 noexcept;
188#endif
189template <class V,class MV> friend V &_vmvminusassign(V &rv,const MV &v)
190#if(CXSC_INDEX_CHECK)
191;
192#else
193 noexcept;
194#endif
195
196template <class V,class MV> friend V &_vmvsetinf(V &rv,const MV &v)
197#if(CXSC_INDEX_CHECK)
198;
199#else
200 noexcept;
201#endif
202template <class V,class MV> friend V &_vmvsetsup(V &rv,const MV &v)
203#if(CXSC_INDEX_CHECK)
204;
205#else
206 noexcept;
207#endif
208template <class V,class MV> friend V &_vmvusetinf(V &rv,const MV &v)
209#if(CXSC_INDEX_CHECK)
210;
211#else
212 noexcept;
213#endif
214template <class V,class MV> friend V &_vmvusetsup(V &rv,const MV &v)
215#if(CXSC_INDEX_CHECK)
216;
217#else
218 noexcept;
219#endif
220
221#endif
222
223 //----------------- Konstruktoren ----------------------------------
224
226 explicit INLINE l_rmatrix_subv (l_real *d, const int &l, const int &u, const int &s, const int &st, const int &o) noexcept:dat(d),lb(l),ub(u),size(s),start(st),offset(o) { }
227 public:
229 INLINE l_rmatrix_subv(const l_rmatrix_subv &v) noexcept:dat(v.dat),lb(v.lb),ub(v.ub),size(v.size),start(v.start),offset(v.offset) { }
230 public:
231
232 //---------------------- Standardfunktionen ------------------------
234 friend INLINE int Lb(const l_rmatrix_subv &rv) noexcept { return rv.lb; }
236 friend INLINE int Ub(const l_rmatrix_subv &rv) noexcept { return rv.ub; }
238 INLINE l_real &operator [](const int &i) const
239#if(CXSC_INDEX_CHECK)
240;
241#else
242 noexcept;
243#endif
245 INLINE l_rmatrix_subv &operator ()() noexcept { return *this; }
247 INLINE l_rmatrix_subv operator ()(const int &i)
248#if(CXSC_INDEX_CHECK)
249;
250#else
251 noexcept;
252#endif
254 INLINE l_rmatrix_subv operator ()(const int &i1,const int &i2)
255#if(CXSC_INDEX_CHECK)
256;
257#else
258 noexcept;
259#endif
260
261
263 INLINE l_rmatrix_subv &operator =(const l_rmatrix_subv &rv) noexcept;
265 INLINE l_rmatrix_subv &operator =(const l_real &r) noexcept;
267 INLINE l_rmatrix_subv &operator =(const l_rmatrix &m)
268#if(CXSC_INDEX_CHECK)
269;
270#else
271 noexcept;
272#endif
275#if(CXSC_INDEX_CHECK)
276;
277#else
278 noexcept;
279#endif
281 INLINE l_rmatrix_subv &operator =(const l_rvector &v)
282#if(CXSC_INDEX_CHECK)
283;
284#else
285 noexcept;
286#endif
289#if(CXSC_INDEX_CHECK)
290;
291#else
292 noexcept;
293#endif
294
296 INLINE l_rmatrix_subv &operator *=(const l_real &c) noexcept;
298 INLINE l_rmatrix_subv &operator +=(const l_real &c) noexcept;
300 INLINE l_rmatrix_subv &operator -=(const l_real &c) noexcept;
302 INLINE l_rmatrix_subv &operator /=(const l_real &c) noexcept;
304 INLINE l_rmatrix_subv &operator -=(const l_rvector &rv)
305#if(CXSC_INDEX_CHECK)
306;
307#else
308 noexcept;
309#endif
311 INLINE l_rmatrix_subv &operator +=(const l_rvector &rv)
312#if(CXSC_INDEX_CHECK)
313;
314#else
315 noexcept;
316#endif
319#if(CXSC_INDEX_CHECK)
320;
321#else
322 noexcept;
323#endif
326#if(CXSC_INDEX_CHECK)
327;
328#else
329 noexcept;
330#endif
331 // Real
333 INLINE l_rmatrix_subv &operator =(const rmatrix_subv &rv) noexcept;
335 INLINE l_rmatrix_subv &operator =(const real &r) noexcept;
337 INLINE l_rmatrix_subv &operator =(const rmatrix &m)
338#if(CXSC_INDEX_CHECK)
339;
340#else
341 noexcept;
342#endif
344 INLINE l_rmatrix_subv &operator =(const rmatrix_slice &m)
345#if(CXSC_INDEX_CHECK)
346;
347#else
348 noexcept;
349#endif
351 INLINE l_rmatrix_subv &operator =(const rvector &v)
352#if(CXSC_INDEX_CHECK)
353;
354#else
355 noexcept;
356#endif
358 INLINE l_rmatrix_subv &operator =(const rvector_slice &v)
359#if(CXSC_INDEX_CHECK)
360;
361#else
362 noexcept;
363#endif
364
366 INLINE l_rmatrix_subv &operator *=(const real &c) noexcept;
368 INLINE l_rmatrix_subv &operator +=(const real &c) noexcept;
370 INLINE l_rmatrix_subv &operator -=(const real &c) noexcept;
372 INLINE l_rmatrix_subv &operator /=(const real &c) noexcept;
374 INLINE l_rmatrix_subv &operator -=(const rvector &rv)
375#if(CXSC_INDEX_CHECK)
376;
377#else
378 noexcept;
379#endif
381 INLINE l_rmatrix_subv &operator +=(const rvector &rv)
382#if(CXSC_INDEX_CHECK)
383;
384#else
385 noexcept;
386#endif
388 INLINE l_rmatrix_subv &operator -=(const rvector_slice &rv)
389#if(CXSC_INDEX_CHECK)
390;
391#else
392 noexcept;
393#endif
395 INLINE l_rmatrix_subv &operator +=(const rvector_slice &rv)
396#if(CXSC_INDEX_CHECK)
397;
398#else
399 noexcept;
400#endif
401//#else
402//#endif
403
404};
405
406
407//----------------------- Matrix -----------------------------------------------
408
409class l_rmatrix_slice;
410
412
416{
417 friend class l_rmatrix_slice;
418 friend class l_rmatrix_subv;
419 friend class l_imatrix;
420 private:
421 l_real *dat;
422 int lb1,ub1,lb2,ub2,xsize,ysize;
423
424 public:
425//#if(CXSC_INDEX_CHECK)
426#ifdef _CXSC_FRIEND_TPL
427 //----------------- Templates ---------------------------------------
428template <class S,class M> friend void _smconstr(S &s,const M &m)
429#if(CXSC_INDEX_CHECK)
430;
431#else
432 noexcept;
433#endif
434template <class V,class M,class S> friend void _vmconstr(V &v,const M &m)
435#if(CXSC_INDEX_CHECK)
436;
437#else
438 noexcept;
439#endif
440 template <class M1,class M2,class S> friend M1 &_mmassign(M1 &m1,const M2 &m,S ms) noexcept;
441 template <class M,class MS2,class S> friend M &_mmsassign(M &m,const MS2 &ms) noexcept;
442 template <class MS,class M> friend MS &_msmassign(MS &ms,const M &m)
443#if(CXSC_INDEX_CHECK)
444 ;
445#else
446 noexcept;
447#endif
448 template <class M,class S> friend M &_msassign(M &m,const S &r) noexcept;
449template <class V,class M,class S> friend V &_vmassign(V &v,const M &m)
450#if(CXSC_INDEX_CHECK)
451;
452#else
453 noexcept;
454#endif
455template <class M,class V,class S> friend M &_mvassign(M &m,const V &v) noexcept;
456 template <class M> friend int _mlb(const M &m, const int &i)
457#if(CXSC_INDEX_CHECK)
458;
459#else
460 noexcept;
461#endif
462 template <class M> friend int _mub(const M &m, const int &i)
463#if(CXSC_INDEX_CHECK)
464;
465#else
466 noexcept;
467#endif
468 template <class M> friend M &_msetlb(M &m, const int &i,const int &j)
469#if(CXSC_INDEX_CHECK)
470;
471#else
472 noexcept;
473#endif
474 template <class M> friend M &_msetub(M &m, const int &i,const int &j)
475#if(CXSC_INDEX_CHECK)
476;
477#else
478 noexcept;
479#endif
480 template <class M> friend void _mresize(M &A) noexcept;
481 template <class M,class S> friend void _mresize(M &A,const int &m, const int &n)
482#if(CXSC_INDEX_CHECK)
483 ;
484#else
485 noexcept;
486#endif
487 template <class M,class S> friend void _mresize(M &A,const int &m1, const int &m2,const int &n1,const int &n2)
488#if(CXSC_INDEX_CHECK)
489 ;
490#else
491 noexcept;
492#endif
493 template <class M,class E> friend E _mabs(const M &m) noexcept;
494 template <class MS,class E> friend E _msabs(const MS &ms) noexcept;
495 //-------------- matrix-matrix -------------
496 template <class M1,class M2,class E> friend E _mmplus(const M1 &m1,const M2 &m2)
497#if(CXSC_INDEX_CHECK)
498 ;
499#else
500 noexcept;
501#endif
502 template <class M,class MS,class E> friend E _mmsplus(const M &m,const MS &ms)
503#if(CXSC_INDEX_CHECK)
504 ;
505#else
506 noexcept;
507#endif
508 template <class M> friend M _mminus(const M &m) noexcept;
509 template <class MS,class E> friend E _msminus(const MS &ms) noexcept;
510 template <class M1,class M2,class E> friend E _mmminus(const M1 &m1,const M2 &m2)
511#if(CXSC_INDEX_CHECK)
512 ;
513#else
514 noexcept;
515#endif
516 template <class M1,class M2> friend M1 &_mmplusassign(M1 &m1,const M2 &m2)
517#if(CXSC_INDEX_CHECK)
518 ;
519#else
520 noexcept;
521#endif
522 template <class M,class MS> friend M &_mmsplusassign(M &m1,const MS &ms)
523#if(CXSC_INDEX_CHECK)
524 ;
525#else
526 noexcept;
527#endif
528 template <class MS,class M> friend MS &_msmplusassign(MS &ms,const M &m1)
529#if(CXSC_INDEX_CHECK)
530 ;
531#else
532 noexcept;
533#endif
534 template <class MS1,class MS2,class E> friend E _msmsplus(const MS1 &m1,const MS2 &m2)
535#if(CXSC_INDEX_CHECK)
536 ;
537#else
538 noexcept;
539#endif
540 template <class M,class MS,class E> friend E _mmsminus(const M &m,const MS &ms)
541#if(CXSC_INDEX_CHECK)
542 ;
543#else
544 noexcept;
545#endif
546 template <class MS,class M,class E> friend E _msmminus(const MS &ms,const M &m)
547#if(CXSC_INDEX_CHECK)
548 ;
549#else
550 noexcept;
551#endif
552 template <class MS1,class MS2,class E> friend E _msmsminus(const MS1 &ms1,const MS2 &ms2)
553#if(CXSC_INDEX_CHECK)
554 ;
555#else
556 noexcept;
557#endif
558 template <class M1,class M2> friend M1 &_mmminusassign(M1 &m1,const M2 &m2)
559#if(CXSC_INDEX_CHECK)
560 ;
561#else
562 noexcept;
563#endif
564 template <class M,class MS> friend M &_mmsminusassign(M &m1,const MS &ms)
565#if(CXSC_INDEX_CHECK)
566 ;
567#else
568 noexcept;
569#endif
570 template <class MS,class M> friend MS &_msmminusassign(MS &ms,const M &m1)
571#if(CXSC_INDEX_CHECK)
572 ;
573#else
574 noexcept;
575#endif
576 template <class M1,class M2,class E> friend E _mmlmult(const M1 &m1, const M2 &m2)
577#if(CXSC_INDEX_CHECK)
578 ;
579#else
580 noexcept;
581#endif
582 template <class M1,class M2,class S> friend M1 &_mmlmultassign(M1 &m1,const M2 &m2)
583#if(CXSC_INDEX_CHECK)
584 ;
585#else
586 noexcept;
587#endif
588 template <class M,class MS,class E> friend E _mmslmult(const M &m1, const MS &ms)
589#if(CXSC_INDEX_CHECK)
590 ;
591#else
592 noexcept;
593#endif
594 template <class MS,class M,class E> friend E _msmlmult(const MS &ms, const M &m2)
595#if(CXSC_INDEX_CHECK)
596 ;
597#else
598 noexcept;
599#endif
600 template <class M,class MS,class S> friend M &_mmslmultassign(M &m1,const MS &ms)
601#if(CXSC_INDEX_CHECK)
602 ;
603#else
604 noexcept;
605#endif
606 template <class MS1,class MS2,class E> friend E _msmslmult(const MS1 &ms1, const MS2 &ms2)
607#if(CXSC_INDEX_CHECK)
608 ;
609#else
610 noexcept;
611#endif
612 template <class M1,class M2,class E> friend E _mmconv(const M1 &m1,const M2 &m2)
613#if(CXSC_INDEX_CHECK)
614 ;
615#else
616 noexcept;
617#endif
618 template <class M,class MS,class E> friend E _mmsconv(const M &m,const MS &ms)
619#if(CXSC_INDEX_CHECK)
620 ;
621#else
622 noexcept;
623#endif
624 //-------- matrix-scalar -----------------
625 template <class S,class M,class E> friend E _smmult(const S &c, const M &m) noexcept;
626 template <class M,class S> friend M &_msmultassign(M &m,const S &c) noexcept;
627 template <class S,class MS,class E> friend E _smsmult(const S &c, const MS &ms) noexcept;
628 template <class M,class S,class E> friend E _msdiv(const M &m,const S &c) noexcept;
629 template <class M,class S> friend M &_msdivassign(M &m,const S &c) noexcept;
630 template <class MS,class S,class E> friend E _mssdiv(const MS &ms, const S &c) noexcept;
631 //-------- matrix-vector ---------------------
632 template <class M,class V,class E> friend E _mvlmult(const M &m,const V &v)
633#if(CXSC_INDEX_CHECK)
634 ;
635#else
636 noexcept;
637#endif
638 template <class V,class M,class E> friend E _vmlmult(const V &v,const M &m)
639#if(CXSC_INDEX_CHECK)
640 ;
641#else
642 noexcept;
643#endif
644 template <class V,class M,class S> friend V &_vmlmultassign(V &v,const M &m)
645#if(CXSC_INDEX_CHECK)
646 ;
647#else
648 noexcept;
649#endif
650 template <class VS,class M,class S> friend VS &_vsmlmultassign(VS &v,const M &m)
651#if(CXSC_INDEX_CHECK)
652 ;
653#else
654 noexcept;
655#endif
656
657 template <class M> friend void *_mvoid(const M &m) noexcept;
658 template <class M> friend bool _mnot(const M &m) noexcept;
659 template <class MS> friend void *_msvoid(const MS &ms) noexcept;
660 template <class MS> friend bool _msnot(const MS &ms) noexcept;
661 template <class M1,class M2> friend bool _mmeq(const M1 &m1,const M2 &m2) noexcept;
662 template <class M1,class M2> friend bool _mmneq(const M1 &m1,const M2 &m2) noexcept;
663 template <class M1,class M2> friend bool _mmless(const M1 &m1,const M2 &m2) noexcept;
664 template <class M1,class M2> friend bool _mmleq(const M1 &m1,const M2 &m2) noexcept;
665 template <class M,class MS> friend bool _mmseq(const M &m1,const MS &ms) noexcept;
666 template <class M,class MS> friend bool _mmsneq(const M &m1,const MS &ms) noexcept;
667 template <class M,class MS> friend bool _mmsless(const M &m1,const MS &ms) noexcept;
668 template <class M,class MS> friend bool _mmsleq(const M &m1,const MS &ms) noexcept;
669 template <class MS,class M> friend bool _msmless(const MS &ms,const M &m1) noexcept;
670 template <class MS,class M> friend bool _msmleq(const MS &ms,const M &m1) noexcept;
671 template <class M> friend std::ostream &_mout(std::ostream &s,const M &r) noexcept;
672 template <class M> friend std::istream &_min(std::istream &s,M &r) noexcept;
673
674 //--- Real --------- matrix-vector ----------------------
675 template <class MS,class V,class E> friend E _msvlmult(const MS &ms,const V &v)
676#if(CXSC_INDEX_CHECK)
677 ;
678#else
679 noexcept;
680#endif
681 template <class V,class MS,class E> friend E _vmslmult(const V &v,const MS &ms)
682#if(CXSC_INDEX_CHECK)
683 ;
684#else
685 noexcept;
686#endif
687
688 template <class M1,class M2,class E> friend E _mmlimult(const M1 &m1, const M2 &m2)
689#if(CXSC_INDEX_CHECK)
690 ;
691#else
692 noexcept;
693#endif
694
695 template <class M,class MS,class E> friend E _mmslimult(const M &m1, const MS &ms)
696#if(CXSC_INDEX_CHECK)
697 ;
698#else
699 noexcept;
700#endif
701
702 template <class MS,class M,class E> friend E _msmlimult(const MS &ms, const M &m2)
703#if(CXSC_INDEX_CHECK)
704 ;
705#else
706 noexcept;
707#endif
708
709 template <class MS1,class MS2,class E> friend E _msmslimult(const MS1 &ms1, const MS2 &ms2)
710#if(CXSC_INDEX_CHECK)
711 ;
712#else
713 noexcept;
714#endif
715
716 template <class MS1,class MS2,class E> friend E _msmsconv(const MS1 &m1,const MS2 &m2)
717#if(CXSC_INDEX_CHECK)
718 ;
719#else
720 noexcept;
721#endif
722 template <class M1,class M2,class E> friend E _mmsect(const M1 &m1,const M2 &m2)
723#if(CXSC_INDEX_CHECK)
724 ;
725#else
726 noexcept;
727#endif
728 template <class M,class MS,class E> friend E _mmssect(const M &m,const MS &ms)
729#if(CXSC_INDEX_CHECK)
730 ;
731#else
732 noexcept;
733#endif
734
735 template <class MS1,class MS2,class E> friend E _msmssect(const MS1 &m1,const MS2 &m2)
736#if(CXSC_INDEX_CHECK)
737 ;
738#else
739 noexcept;
740#endif
741 // matrix-scalar
742
743 // matrix-vector
744
745 template <class M,class V,class E> friend E _mvlimult(const M &m,const V &v)
746#if(CXSC_INDEX_CHECK)
747 ;
748#else
749 noexcept;
750#endif
751 template <class V,class M,class E> friend E _vmlimult(const V &v,const M &m)
752#if(CXSC_INDEX_CHECK)
753 ;
754#else
755 noexcept;
756#endif
757 template <class MS,class V,class E> friend E _msvlimult(const MS &ms,const V &v)
758#if(CXSC_INDEX_CHECK)
759 ;
760#else
761 noexcept;
762#endif
763
764 // l_interval ----------
765
766 template <class M,class E> friend E _mdiam(const M &m) noexcept;
767 template <class M,class E> friend E _mmid(const M &m) noexcept;
768 template <class MS,class E> friend E _msdiam(const MS &ms) noexcept;
769 template <class MS,class E> friend E _msmid(const MS &ms) noexcept;
770 template <class M,class E> friend E _minf(const M &m) noexcept;
771 template <class MS,class E> friend E _msinf(const MS &ms) noexcept;
772 template <class M,class E> friend E _msup(const M &m) noexcept;
773 template <class MS,class E> friend E _mssup(const MS &ms) noexcept;
774 template <class M1,class M2> friend M1 &_mmsetinf(M1 &m1,const M2 &m2)
775#if(CXSC_INDEX_CHECK)
776 ;
777#else
778 noexcept;
779#endif
780 template <class M1,class M2> friend M1 &_mmsetsup(M1 &m1,const M2 &m2)
781#if(CXSC_INDEX_CHECK)
782 ;
783#else
784 noexcept;
785#endif
786 template <class M1,class M2> friend M1 &_mmusetinf(M1 &m1,const M2 &m2)
787#if(CXSC_INDEX_CHECK)
788 ;
789#else
790 noexcept;
791#endif
792 template <class M1,class M2> friend M1 &_mmusetsup(M1 &m1,const M2 &m2)
793#if(CXSC_INDEX_CHECK)
794 ;
795#else
796 noexcept;
797#endif
798 template <class MS1,class M2> friend MS1 &_msmsetinf(MS1 &ms1,const M2 &m2)
799#if(CXSC_INDEX_CHECK)
800 ;
801#else
802 noexcept;
803#endif
804 template <class MS1,class M2> friend MS1 &_msmsetsup(MS1 &ms1,const M2 &m2)
805#if(CXSC_INDEX_CHECK)
806 ;
807#else
808 noexcept;
809#endif
810 template <class MS1,class M2> friend MS1 &_msmusetinf(MS1 &ms1,const M2 &m2)
811#if(CXSC_INDEX_CHECK)
812 ;
813#else
814 noexcept;
815#endif
816 template <class MS1,class M2> friend MS1 &_msmusetsup(MS1 &ms1,const M2 &m2)
817#if(CXSC_INDEX_CHECK)
818 ;
819#else
820 noexcept;
821#endif
822
823 template <class M1,class M2,class S> friend M1 &_mmlimultassign(M1 &m1,const M2 &m2)
824#if(CXSC_INDEX_CHECK)
825 ;
826#else
827 noexcept;
828#endif
829
830 template <class M,class MS,class S> friend M &_mmslimultassign(M &m1,const MS &ms)
831#if(CXSC_INDEX_CHECK)
832 ;
833#else
834 noexcept;
835#endif
836
837 template <class M1,class M2> friend M1 &_mmconvassign(M1 &m1,const M2 &m2)
838#if(CXSC_INDEX_CHECK)
839 ;
840#else
841 noexcept;
842#endif
843 template <class M,class MS> friend M &_mmsconvassign(M &m1,const MS &ms)
844#if(CXSC_INDEX_CHECK)
845 ;
846#else
847 noexcept;
848#endif
849 template <class MS,class M> friend MS &_msmconvassign(MS &ms,const M &m1)
850#if(CXSC_INDEX_CHECK)
851 ;
852#else
853 noexcept;
854#endif
855
856 template <class M1,class M2> friend M1 &_mmsectassign(M1 &m1,const M2 &m2)
857#if(CXSC_INDEX_CHECK)
858 ;
859#else
860 noexcept;
861#endif
862 template <class M,class MS> friend M &_mmssectassign(M &m1,const MS &ms)
863#if(CXSC_INDEX_CHECK)
864 ;
865#else
866 noexcept;
867#endif
868 template <class MS,class M> friend MS &_msmsectassign(MS &ms,const M &m1)
869#if(CXSC_INDEX_CHECK)
870 ;
871#else
872 noexcept;
873#endif
874
875 template <class V,class M,class S> friend V &_vmlimultassign(V &v,const M &m)
876#if(CXSC_INDEX_CHECK)
877 ;
878#else
879 noexcept;
880#endif
881 template <class VS,class M,class S> friend VS &_vsmlimultassign(VS &v,const M &m)
882#if(CXSC_INDEX_CHECK)
883 ;
884#else
885 noexcept;
886#endif
887
888#endif
889
890 //-------------------------- Konstruktoren ----------------------------
891
892// l_real
894 INLINE l_rmatrix(const l_rmatrix &rm) noexcept;
896 INLINE l_rmatrix(const l_rmatrix_slice &rm) noexcept;
898 INLINE l_rmatrix() noexcept;
900 explicit INLINE l_rmatrix(const int &m, const int &n)
901#if(CXSC_INDEX_CHECK)
902;
903#else
904 noexcept;
905#endif
907 explicit INLINE l_rmatrix(const int &m1, const int &n1, const int &m2, const int &n2)
908#if(CXSC_INDEX_CHECK)
909;
910#else
911 noexcept;
912#endif
914 explicit INLINE l_rmatrix(const l_rvector &v) noexcept;
916 explicit INLINE l_rmatrix(const l_rvector_slice &v) noexcept;
918 explicit INLINE l_rmatrix(const l_real &r) noexcept;
920 INLINE l_rmatrix &operator =(const l_real &r) noexcept;
922 INLINE l_rmatrix &operator =(const l_rmatrix &m) noexcept;
924 INLINE l_rmatrix &operator =(const l_rmatrix_slice &ms) noexcept;
926 INLINE l_rmatrix &operator =(const l_rvector &v) noexcept;
928 INLINE l_rmatrix &operator =(const l_rvector_slice &v) noexcept;
929// real
931 explicit INLINE l_rmatrix(const real &) noexcept;
933 explicit INLINE l_rmatrix(const rmatrix &rm) noexcept;
935 explicit INLINE l_rmatrix(const rmatrix_slice &rm) noexcept;
937 explicit INLINE l_rmatrix(const rvector &v) noexcept;
939 explicit INLINE l_rmatrix(const rvector_slice &v) noexcept;
941 INLINE l_rmatrix &operator =(const real &r) noexcept;
943 INLINE l_rmatrix &operator =(const rmatrix &m) noexcept;
945 INLINE l_rmatrix &operator =(const rmatrix_slice &ms) noexcept;
947 INLINE l_rmatrix &operator =(const rvector &v) noexcept;
949 INLINE l_rmatrix &operator =(const rvector_slice &v) noexcept;
950
951 //--------------------------- Destruktoren -----------------------------
952
953 INLINE ~l_rmatrix() noexcept { delete [] dat; }
954
955 //------------------------- Standardfunktionen -------------------------
956
958 INLINE l_rmatrix_subv operator [](const int &i) const
959#if(CXSC_INDEX_CHECK)
960;
961#else
962 noexcept;
963#endif
965 INLINE l_rmatrix_subv operator [](const cxscmatrix_column &i) const
966#if(CXSC_INDEX_CHECK)
967;
968#else
969 noexcept;
970#endif
972 INLINE l_rmatrix &operator ()() noexcept { return *this; }
974 INLINE l_rmatrix_slice operator ()(const int &m, const int &n)
975#if(CXSC_INDEX_CHECK)
976;
977#else
978 noexcept;
979#endif
981 INLINE l_rmatrix_slice operator ()(const int &m1, const int &m2, const int &n1, const int &n2)
982#if(CXSC_INDEX_CHECK)
983;
984#else
985 noexcept;
986#endif
987 INLINE operator void*() noexcept;
988//#else
989//#endif
990};
991
992
994
1000{
1001 friend class l_rmatrix;
1002 friend class l_imatrix;
1003 private:
1004 l_real *dat;
1005 int offset1,offset2,mxsize,mysize;
1006 int start1,end1,start2,end2,sxsize,sysize; // slice size
1007
1008 public:
1009//#if(CXSC_INDEX_CHECK)
1010#ifdef _CXSC_FRIEND_TPL
1011 //----------------- Templates ---------------------------------------
1012template <class V,class MS,class S> friend void _vmsconstr(V &v,const MS &m)
1013#if(CXSC_INDEX_CHECK)
1014;
1015#else
1016 noexcept;
1017#endif
1018 template <class MS,class M> friend MS &_msmassign(MS &ms,const M &m)
1019#if(CXSC_INDEX_CHECK)
1020 ;
1021#else
1022 noexcept;
1023#endif
1024 template <class MS1,class MS2> friend MS1 &_msmsassign(MS1 &ms1,const MS2 &ms)
1025#if(CXSC_INDEX_CHECK)
1026 ;
1027#else
1028 noexcept;
1029#endif
1030 template <class M,class MS2,class S> friend M &_mmsassign(M &m,const MS2 &ms) noexcept;
1031 template <class MS,class S> friend MS &_mssassign(MS &ms,const S &r) noexcept;
1032
1033 template <class MS> friend int _mslb(const MS &ms, const int &i)
1034#if(CXSC_INDEX_CHECK)
1035;
1036#else
1037 noexcept;
1038#endif
1039 template <class MS> friend int _msub(const MS &ms, const int &i)
1040#if(CXSC_INDEX_CHECK)
1041;
1042#else
1043 noexcept;
1044#endif
1045 template <class MS,class E> friend E _msabs(const MS &ms) noexcept;
1046 //-------- matrix-matrix --------------
1047 template <class MS,class E> friend E _msminus(const MS &ms) noexcept;
1048 template <class M,class MS,class E> friend E _mmsplus(const M &m,const MS &ms)
1049#if(CXSC_INDEX_CHECK)
1050 ;
1051#else
1052 noexcept;
1053#endif
1054 template <class MS1,class MS2,class E> friend E _msmsplus(const MS1 &m1,const MS2 &m2)
1055#if(CXSC_INDEX_CHECK)
1056 ;
1057#else
1058 noexcept;
1059#endif
1060 template <class M,class MS> friend M &_mmsplusassign(M &m1,const MS &ms)
1061#if(CXSC_INDEX_CHECK)
1062 ;
1063#else
1064 noexcept;
1065#endif
1066 template <class MS,class M> friend MS &_msmplusassign(MS &ms,const M &m1)
1067#if(CXSC_INDEX_CHECK)
1068 ;
1069#else
1070 noexcept;
1071#endif
1072 template <class MS1,class MS2> friend MS1 &_msmsplusassign(MS1 &ms1,const MS2 &ms2)
1073#if(CXSC_INDEX_CHECK)
1074 ;
1075#else
1076 noexcept;
1077#endif
1078 template <class M,class MS,class E> friend E _mmsminus(const M &m,const MS &ms)
1079#if(CXSC_INDEX_CHECK)
1080 ;
1081#else
1082 noexcept;
1083#endif
1084 template <class MS,class M,class E> friend E _msmminus(const MS &ms,const M &m)
1085#if(CXSC_INDEX_CHECK)
1086 ;
1087#else
1088 noexcept;
1089#endif
1090 template <class MS1,class MS2,class E> friend E _msmsminus(const MS1 &ms1,const MS2 &ms2)
1091#if(CXSC_INDEX_CHECK)
1092 ;
1093#else
1094 noexcept;
1095#endif
1096 template <class M,class MS> friend M &_mmsminusassign(M &m1,const MS &ms)
1097#if(CXSC_INDEX_CHECK)
1098 ;
1099#else
1100 noexcept;
1101#endif
1102 template <class MS,class M> friend MS &_msmminusassign(MS &ms,const M &m1)
1103#if(CXSC_INDEX_CHECK)
1104 ;
1105#else
1106 noexcept;
1107#endif
1108 template <class MS1,class MS2> friend MS1 &_msmsminusassign(MS1 &ms1,const MS2 &ms2)
1109#if(CXSC_INDEX_CHECK)
1110 ;
1111#else
1112 noexcept;
1113#endif
1114 template <class M,class MS,class E> friend E _mmslmult(const M &m1, const MS &ms)
1115#if(CXSC_INDEX_CHECK)
1116 ;
1117#else
1118 noexcept;
1119#endif
1120 template <class MS,class M,class E> friend E _msmlmult(const MS &ms, const M &m2)
1121#if(CXSC_INDEX_CHECK)
1122 ;
1123#else
1124 noexcept;
1125#endif
1126 template <class M,class MS,class S> friend M &_mmslmultassign(M &m1,const MS &ms)
1127#if(CXSC_INDEX_CHECK)
1128 ;
1129#else
1130 noexcept;
1131#endif
1132 template <class MS1,class MS2,class E> friend E _msmslmult(const MS1 &ms1, const MS2 &ms2)
1133#if(CXSC_INDEX_CHECK)
1134 ;
1135#else
1136 noexcept;
1137#endif
1138 template <class M,class MS,class E> friend E _mmsconv(const M &m,const MS &ms)
1139#if(CXSC_INDEX_CHECK)
1140 ;
1141#else
1142 noexcept;
1143#endif
1144 template <class MS1,class MS2,class E> friend E _msmsconv(const MS1 &m1,const MS2 &m2)
1145#if(CXSC_INDEX_CHECK)
1146 ;
1147#else
1148 noexcept;
1149#endif
1150 //--------- matrix-vector --------------
1151 template <class MS,class V,class E> friend E _msvlmult(const MS &ms,const V &v)
1152#if(CXSC_INDEX_CHECK)
1153 ;
1154#else
1155 noexcept;
1156#endif
1157 template <class V,class MS,class E> friend E _vmslmult(const V &v,const MS &ms)
1158#if(CXSC_INDEX_CHECK)
1159 ;
1160#else
1161 noexcept;
1162#endif
1163 template <class V,class MS,class S> friend V &_vmslmultassign(V &v,const MS &ms)
1164#if(CXSC_INDEX_CHECK)
1165 ;
1166#else
1167 noexcept;
1168#endif
1169 //--------- matrix-scalar --------------
1170 template <class S,class MS,class E> friend E _smsmult(const S &c, const MS &ms) noexcept;
1171 template <class MS,class S> friend MS &_mssmultassign(MS &ms,const S &c) noexcept;
1172 template <class MS,class S,class E> friend E _mssdiv(const MS &ms, const S &c) noexcept;
1173 template <class MS,class S> friend MS &_mssdivassign(MS &ms,const S &c) noexcept;
1174
1175 template <class MS> friend void *_msvoid(const MS &ms) noexcept;
1176 template <class MS> friend bool _msnot(const MS &ms) noexcept;
1177 template <class M,class MS> friend bool _mmseq(const M &m1,const MS &ms) noexcept;
1178 template <class M,class MS> friend bool _mmsneq(const M &m1,const MS &ms) noexcept;
1179 template <class M,class MS> friend bool _mmsless(const M &m1,const MS &ms) noexcept;
1180 template <class M,class MS> friend bool _mmsleq(const M &m1,const MS &ms) noexcept;
1181 template <class MS,class M> friend bool _msmless(const MS &ms,const M &m1) noexcept;
1182 template <class MS,class M> friend bool _msmleq(const MS &ms,const M &m1) noexcept;
1183 template <class MS1,class MS2> friend bool _msmseq(const MS1 &ms1,const MS2 &ms2) noexcept;
1184 template <class MS1,class MS2> friend bool _msmsneq(const MS1 &ms1,const MS2 &ms2) noexcept;
1185 template <class MS1,class MS2> friend bool _msmsless(const MS1 &ms1,const MS2 &ms2) noexcept;
1186 template <class MS1,class MS2> friend bool _msmsleq(const MS1 &ms1,const MS2 &ms2) noexcept;
1187 template <class MS> friend std::ostream &_msout(std::ostream &s,const MS &r) noexcept;
1188 template <class MS> friend std::istream &_msin(std::istream &s,MS &r) noexcept;
1189
1190 //--- Real ------------ matrix-matrix -----------
1191
1192 template <class M,class MS,class E> friend E _mmslimult(const M &m1, const MS &ms)
1193#if(CXSC_INDEX_CHECK)
1194 ;
1195#else
1196 noexcept;
1197#endif
1198 template <class MS,class M,class E> friend E _msmlimult(const MS &ms, const M &m2)
1199#if(CXSC_INDEX_CHECK)
1200 ;
1201#else
1202 noexcept;
1203#endif
1204
1205 template <class MS1,class MS2,class E> friend E _msmslimult(const MS1 &ms1, const MS2 &ms2)
1206#if(CXSC_INDEX_CHECK)
1207 ;
1208#else
1209 noexcept;
1210#endif
1211
1212 template <class M,class MS,class E> friend E _mmssect(const M &m,const MS &ms)
1213#if(CXSC_INDEX_CHECK)
1214 ;
1215#else
1216 noexcept;
1217#endif
1218 template <class MS1,class MS2,class E> friend E _msmssect(const MS1 &m1,const MS2 &m2)
1219#if(CXSC_INDEX_CHECK)
1220 ;
1221#else
1222 noexcept;
1223#endif
1224 // matrix-scalar
1225 // matrix-vector
1226
1227 template <class MS,class V,class E> friend E _msvlimult(const MS &ms,const V &v)
1228#if(CXSC_INDEX_CHECK)
1229 ;
1230#else
1231 noexcept;
1232#endif
1233 template <class V,class MS,class E> friend E _vmslimult(const V &v,const MS &ms)
1234#if(CXSC_INDEX_CHECK)
1235 ;
1236#else
1237 noexcept;
1238#endif
1239
1240 // l_interval --------------
1241
1242 template <class M1,class MS2> friend M1 &_mmssetinf(M1 &m1,const MS2 &ms2)
1243#if(CXSC_INDEX_CHECK)
1244 ;
1245#else
1246 noexcept;
1247#endif
1248 template <class M1,class MS2> friend M1 &_mmssetsup(M1 &m1,const MS2 &ms2)
1249#if(CXSC_INDEX_CHECK)
1250 ;
1251#else
1252 noexcept;
1253#endif
1254 template <class M1,class MS2> friend M1 &_mmsusetinf(M1 &m1,const MS2 &ms2)
1255#if(CXSC_INDEX_CHECK)
1256 ;
1257#else
1258 noexcept;
1259#endif
1260 template <class M1,class MS2> friend M1 &_mmsusetsup(M1 &m1,const MS2 &ms2)
1261#if(CXSC_INDEX_CHECK)
1262 ;
1263#else
1264 noexcept;
1265#endif
1266 template <class MS1,class MS2> friend MS1 &_msmssetinf(MS1 &ms1,const MS2 &ms2)
1267#if(CXSC_INDEX_CHECK)
1268 ;
1269#else
1270 noexcept;
1271#endif
1272 template <class MS1,class MS2> friend MS1 &_msmssetsup(MS1 &ms1,const MS2 &ms2)
1273#if(CXSC_INDEX_CHECK)
1274 ;
1275#else
1276 noexcept;
1277#endif
1278 template <class MS1,class MS2> friend MS1 &_msmsusetinf(MS1 &ms1,const MS2 &ms2)
1279#if(CXSC_INDEX_CHECK)
1280 ;
1281#else
1282 noexcept;
1283#endif
1284 template <class MS1,class MS2> friend MS1 &_msmsusetsup(MS1 &ms1,const MS2 &ms2)
1285#if(CXSC_INDEX_CHECK)
1286 ;
1287#else
1288 noexcept;
1289#endif
1290
1291
1292 template <class M,class MS,class S> friend M &_mmslimultassign(M &m1,const MS &ms)
1293#if(CXSC_INDEX_CHECK)
1294 ;
1295#else
1296 noexcept;
1297#endif
1298
1299
1300 template <class M,class MS> friend M &_mmsconvassign(M &m1,const MS &ms)
1301#if(CXSC_INDEX_CHECK)
1302 ;
1303#else
1304 noexcept;
1305#endif
1306 template <class MS1,class MS2> friend MS1 &_msmsconvassign(MS1 &ms1,const MS2 &ms2)
1307#if(CXSC_INDEX_CHECK)
1308 ;
1309#else
1310 noexcept;
1311#endif
1312
1313 template <class M,class MS> friend M &_mmssectassign(M &m1,const MS &ms)
1314#if(CXSC_INDEX_CHECK)
1315 ;
1316#else
1317 noexcept;
1318#endif
1319 template <class MS1,class MS2> friend MS1 &_msmssectassign(MS1 &ms1,const MS2 &ms2)
1320#if(CXSC_INDEX_CHECK)
1321 ;
1322#else
1323 noexcept;
1324#endif
1325
1326 /* friend TINLINE l_ivector &_vsmslimultassign<l_ivector_slice,l_rmatrix_slice,l_interval>(l_ivector_slice &v,const l_rmatrix_slice &ms)
1327#if(CXSC_INDEX_CHECK)
1328;
1329#else
1330 noexcept;
1331 #endif */
1332 template <class V,class MS,class S> friend V &_vmslimultassign(V &v,const MS &ms)
1333#if(CXSC_INDEX_CHECK)
1334 ;
1335#else
1336 noexcept;
1337#endif
1338
1339#endif
1340
1341 //--------------- Konstruktoren ----------------------------------------
1342
1344 explicit INLINE l_rmatrix_slice(l_rmatrix &a,const int &l1,const int &u1,const int &l2, const int &u2) noexcept:dat(a.dat),offset1(l1-a.lb1),offset2(l2-a.lb2),mxsize(a.xsize),mysize(a.ysize),start1(l1),end1(u1),start2(l2),end2(u2),sxsize(u2-l2+1),sysize(u1-l1+1) { }
1346 explicit INLINE l_rmatrix_slice(l_rmatrix_slice &a,const int &l1,const int &u1,const int &l2, const int &u2) noexcept:dat(a.dat),offset1(a.offset1+l1-a.start1),offset2(a.offset2+l2-a.start2),mxsize(a.mxsize),mysize(a.mysize),start1(l1),end1(u1),start2(l2),end2(u2),sxsize(u2-l2+1),sysize(u1-l1+1) { }
1347 public:
1349 INLINE l_rmatrix_slice(const l_rmatrix_slice &ms) noexcept:dat(ms.dat),offset1(ms.offset1),offset2(ms.offset2),mxsize(ms.mxsize),mysize(ms.mysize),start1(ms.start1),end1(ms.end1),start2(ms.start2),end2(ms.end2),sxsize(ms.sxsize),sysize(ms.sysize) { }
1350 public:
1351
1352 //---------------- Standardfunktionen -----------------------------------
1353
1354 friend INLINE l_rvector::l_rvector(const l_rmatrix_slice &sl)
1355#if(CXSC_INDEX_CHECK)
1356;
1357#else
1358 noexcept;
1359#endif
1360 friend INLINE l_rmatrix::l_rmatrix(const l_rmatrix_slice &) noexcept;
1362 INLINE l_rmatrix_slice &operator =(const l_rmatrix &m)
1363#if(CXSC_INDEX_CHECK)
1364;
1365#else
1366 noexcept;
1367#endif
1369 INLINE l_rmatrix_slice &operator =(const l_rmatrix_slice &ms)
1370#if(CXSC_INDEX_CHECK)
1371;
1372#else
1373 noexcept;
1374#endif
1376 INLINE l_rmatrix_slice &operator =(const l_real &r) noexcept;
1378 INLINE l_rmatrix_slice &operator =(const l_rvector &v)
1379#if(CXSC_INDEX_CHECK)
1380;
1381#else
1382 noexcept;
1383#endif
1386#if(CXSC_INDEX_CHECK)
1387;
1388#else
1389 noexcept;
1390#endif
1392 INLINE l_rmatrix_slice &operator =(const rmatrix &m)
1393#if(CXSC_INDEX_CHECK)
1394;
1395#else
1396 noexcept;
1397#endif
1399 INLINE l_rmatrix_slice &operator =(const rmatrix_slice &ms)
1400#if(CXSC_INDEX_CHECK)
1401;
1402#else
1403 noexcept;
1404#endif
1406 INLINE l_rmatrix_slice &operator =(const real &r) noexcept;
1408 INLINE l_rmatrix_slice &operator =(const rvector &v)
1409#if(CXSC_INDEX_CHECK)
1410;
1411#else
1412 noexcept;
1413#endif
1415 INLINE l_rmatrix_slice &operator =(const rvector_slice &v)
1416#if(CXSC_INDEX_CHECK)
1417;
1418#else
1419 noexcept;
1420#endif
1422 INLINE l_rmatrix_subv operator [](const int &i) const
1423#if(CXSC_INDEX_CHECK)
1424;
1425#else
1426 noexcept;
1427#endif
1429 INLINE l_rmatrix_subv operator [](const cxscmatrix_column &i) const
1430#if(CXSC_INDEX_CHECK)
1431;
1432#else
1433 noexcept;
1434#endif
1436 INLINE l_rmatrix_slice &operator ()() noexcept { return *this; }
1438 INLINE l_rmatrix_slice operator ()(const int &m, const int &n)
1439#if(CXSC_INDEX_CHECK)
1440;
1441#else
1442 noexcept;
1443#endif
1445 INLINE l_rmatrix_slice operator ()(const int &m1, const int &m2, const int &n1, const int &n2)
1446#if(CXSC_INDEX_CHECK)
1447;
1448#else
1449 noexcept;
1450#endif
1452 INLINE l_rmatrix_slice &operator *=(const l_rmatrix &m)
1453#if(CXSC_INDEX_CHECK)
1454;
1455#else
1456 noexcept;
1457#endif
1459 INLINE l_rmatrix_slice &operator *=(const rmatrix &m)
1460#if(CXSC_INDEX_CHECK)
1461;
1462#else
1463 noexcept;
1464#endif
1466 INLINE l_rmatrix_slice &operator *=(const l_rmatrix_slice &ms2)
1467#if(CXSC_INDEX_CHECK)
1468;
1469#else
1470 noexcept;
1471#endif
1473 INLINE l_rmatrix_slice &operator *=(const rmatrix_slice &ms2)
1474#if(CXSC_INDEX_CHECK)
1475;
1476#else
1477 noexcept;
1478#endif
1480 INLINE l_rmatrix_slice &operator +=(const l_rmatrix &m1)
1481#if(CXSC_INDEX_CHECK)
1482;
1483#else
1484 noexcept;
1485#endif
1487 INLINE l_rmatrix_slice &operator +=(const rmatrix &m1)
1488#if(CXSC_INDEX_CHECK)
1489;
1490#else
1491 noexcept;
1492#endif
1494 INLINE l_rmatrix_slice &operator +=(const l_rmatrix_slice &ms2)
1495#if(CXSC_INDEX_CHECK)
1496;
1497#else
1498 noexcept;
1499#endif
1501 INLINE l_rmatrix_slice &operator +=(const rmatrix_slice &ms2)
1502#if(CXSC_INDEX_CHECK)
1503;
1504#else
1505 noexcept;
1506#endif
1508 INLINE l_rmatrix_slice &operator -=(const l_rmatrix &m1)
1509#if(CXSC_INDEX_CHECK)
1510;
1511#else
1512 noexcept;
1513#endif
1515 INLINE l_rmatrix_slice &operator -=(const rmatrix &m1)
1516#if(CXSC_INDEX_CHECK)
1517;
1518#else
1519 noexcept;
1520#endif
1522 INLINE l_rmatrix_slice &operator -=(const l_rmatrix_slice &ms2)
1523#if(CXSC_INDEX_CHECK)
1524;
1525#else
1526 noexcept;
1527#endif
1529 INLINE l_rmatrix_slice &operator -=(const rmatrix_slice &ms2)
1530#if(CXSC_INDEX_CHECK)
1531;
1532#else
1533 noexcept;
1534#endif
1537#if(CXSC_INDEX_CHECK)
1538;
1539#else
1540 noexcept;
1541#endif
1544#if(CXSC_INDEX_CHECK)
1545;
1546#else
1547 noexcept;
1548#endif
1551#if(CXSC_INDEX_CHECK)
1552;
1553#else
1554 noexcept;
1555#endif
1558#if(CXSC_INDEX_CHECK)
1559;
1560#else
1561 noexcept;
1562#endif
1564 INLINE l_rmatrix_slice &operator *=(const l_real &c) noexcept;
1566 INLINE l_rmatrix_slice &operator *=(const real &c) noexcept;
1568 INLINE l_rmatrix_slice &operator /=(const l_real &c) noexcept;
1570 INLINE l_rmatrix_slice &operator /=(const real &c) noexcept;
1571 INLINE operator void*() noexcept;
1572//#else
1573//#endif
1574};
1575
1576//================================================================
1577//====================== Subvector Functions =====================
1578
1579//=======================Vector / Scalar =========================
1580
1582 INLINE l_rvector operator /(const l_rmatrix_subv &rv, const l_real &s) noexcept;
1584 INLINE l_rvector operator *(const l_rmatrix_subv &rv, const l_real &s) noexcept;
1586 INLINE l_rvector operator *(const l_real &s, const l_rmatrix_subv &rv) noexcept;
1587
1588//======================== Vector / Vector ========================
1589
1591 INLINE l_rvector abs(const l_rmatrix_subv &mv) noexcept;
1592
1594 INLINE void accumulate(dotprecision &dp, const l_rmatrix_subv & rv1, const l_rmatrix_subv &rv2)
1595#if(CXSC_INDEX_CHECK)
1596;
1597#else
1598 noexcept;
1599#endif
1601 INLINE void accumulate(dotprecision &dp, const l_rvector & rv1, const l_rmatrix_subv &rv2)
1602#if(CXSC_INDEX_CHECK)
1603;
1604#else
1605 noexcept;
1606#endif
1608 INLINE void accumulate(dotprecision &dp, const l_rmatrix_subv & rv1, const l_rvector &rv2)
1609#if(CXSC_INDEX_CHECK)
1610;
1611#else
1612 noexcept;
1613#endif
1615 INLINE void accumulate(dotprecision &dp, const l_rvector_slice & sl1, const l_rmatrix_subv &rv2)
1616#if(CXSC_INDEX_CHECK)
1617;
1618#else
1619 noexcept;
1620#endif
1622 INLINE void accumulate(dotprecision &dp, const l_rmatrix_subv & rv1, const l_rvector_slice &sl2)
1623#if(CXSC_INDEX_CHECK)
1624;
1625#else
1626 noexcept;
1627#endif
1628
1630 INLINE void accumulate(idotprecision &dp, const l_rmatrix_subv & rv1, const l_rmatrix_subv &rv2)
1631#if(CXSC_INDEX_CHECK)
1632;
1633#else
1634 noexcept;
1635#endif
1637 INLINE void accumulate(idotprecision &dp, const l_rvector & rv1, const l_rmatrix_subv &rv2)
1638#if(CXSC_INDEX_CHECK)
1639;
1640#else
1641 noexcept;
1642#endif
1644 INLINE void accumulate(idotprecision &dp, const l_rmatrix_subv & rv1, const l_rvector &rv2)
1645#if(CXSC_INDEX_CHECK)
1646;
1647#else
1648 noexcept;
1649#endif
1651 INLINE void accumulate(idotprecision &dp, const l_rvector_slice & sl1, const l_rmatrix_subv &rv2)
1652#if(CXSC_INDEX_CHECK)
1653;
1654#else
1655 noexcept;
1656#endif
1658 INLINE void accumulate(idotprecision &dp, const l_rmatrix_subv & rv1, const l_rvector_slice &sl2)
1659#if(CXSC_INDEX_CHECK)
1660;
1661#else
1662 noexcept;
1663#endif
1664
1666 INLINE l_real operator *(const l_rmatrix_subv & rv1, const l_rmatrix_subv &rv2)
1667#if(CXSC_INDEX_CHECK)
1668;
1669#else
1670 noexcept;
1671#endif
1673 INLINE l_real operator *(const l_rvector & rv1, const l_rmatrix_subv &rv2)
1674#if(CXSC_INDEX_CHECK)
1675;
1676#else
1677 noexcept;
1678#endif
1680 INLINE l_real operator *(const l_rmatrix_subv &rv1,const l_rvector &rv2)
1681#if(CXSC_INDEX_CHECK)
1682;
1683#else
1684 noexcept;
1685#endif
1687 INLINE l_real operator *(const l_rvector_slice &sl,const l_rmatrix_subv &sv)
1688#if(CXSC_INDEX_CHECK)
1689;
1690#else
1691 noexcept;
1692#endif
1694 INLINE l_real operator *(const l_rmatrix_subv &mv,const l_rvector_slice &vs)
1695#if(CXSC_INDEX_CHECK)
1696;
1697#else
1698 noexcept;
1699#endif
1700
1702 INLINE l_rvector operator +(const l_rmatrix_subv & rv1, const l_rmatrix_subv &rv2)
1703#if(CXSC_INDEX_CHECK)
1704;
1705#else
1706 noexcept;
1707#endif
1709 INLINE l_rvector operator +(const l_rmatrix_subv &rv1,const l_rvector &rv2)
1710#if(CXSC_INDEX_CHECK)
1711;
1712#else
1713 noexcept;
1714#endif
1716 INLINE l_rvector operator +(const l_rvector & rv1, const l_rmatrix_subv &rv2)
1717#if(CXSC_INDEX_CHECK)
1718;
1719#else
1720 noexcept;
1721#endif
1723 INLINE l_rvector operator +(const l_rvector_slice &sl,const l_rmatrix_subv &mv)
1724#if(CXSC_INDEX_CHECK)
1725;
1726#else
1727 noexcept;
1728#endif
1730 INLINE l_rvector operator +(const l_rmatrix_subv &mv,const l_rvector_slice &sl)
1731#if(CXSC_INDEX_CHECK)
1732;
1733#else
1734 noexcept;
1735#endif
1736
1738 INLINE l_rvector operator -(const l_rmatrix_subv & rv1, const l_rmatrix_subv &rv2)
1739#if(CXSC_INDEX_CHECK)
1740;
1741#else
1742 noexcept;
1743#endif
1745 INLINE l_rvector operator -(const l_rvector & rv1, const l_rmatrix_subv &rv2)
1746#if(CXSC_INDEX_CHECK)
1747;
1748#else
1749 noexcept;
1750#endif
1752 INLINE l_rvector operator -(const l_rmatrix_subv &rv1,const l_rvector &rv2)
1753#if(CXSC_INDEX_CHECK)
1754;
1755#else
1756 noexcept;
1757#endif
1759 INLINE l_rvector operator -(const l_rvector_slice &sl,const l_rmatrix_subv &mv)
1760#if(CXSC_INDEX_CHECK)
1761;
1762#else
1763 noexcept;
1764#endif
1766 INLINE l_rvector operator -(const l_rmatrix_subv &mv,const l_rvector_slice &sl)
1767#if(CXSC_INDEX_CHECK)
1768;
1769#else
1770 noexcept;
1771#endif
1772
1773//====================================================================
1774//===================== Matrix Functions =============================
1775
1777 INLINE l_rmatrix _l_rmatrix(const l_rmatrix &rm) noexcept;
1779 INLINE l_rmatrix _l_rmatrix(const l_rvector &v) noexcept;
1781 INLINE l_rmatrix _l_rmatrix(const l_rvector_slice &v) noexcept;
1783 INLINE l_rmatrix _l_rmatrix(const l_real &r) noexcept;
1784
1786 INLINE int Lb(const l_rmatrix &rm, const int &i)
1787#if(CXSC_INDEX_CHECK)
1788;
1789#else
1790 noexcept;
1791#endif
1793 INLINE int Ub(const l_rmatrix &rm, const int &i)
1794#if(CXSC_INDEX_CHECK)
1795;
1796#else
1797 noexcept;
1798#endif
1800 INLINE int Lb(const l_rmatrix_slice &rm, const int &i)
1801#if(CXSC_INDEX_CHECK)
1802;
1803#else
1804 noexcept;
1805#endif
1807 INLINE int Ub(const l_rmatrix_slice &rm, const int &i)
1808#if(CXSC_INDEX_CHECK)
1809;
1810#else
1811 noexcept;
1812#endif
1814 INLINE l_rmatrix &SetLb(l_rmatrix &m, const int &i,const int &j)
1815#if(CXSC_INDEX_CHECK)
1816;
1817#else
1818 noexcept;
1819#endif
1821 INLINE l_rmatrix &SetUb(l_rmatrix &m, const int &i,const int &j)
1822#if(CXSC_INDEX_CHECK)
1823;
1824#else
1825 noexcept;
1826#endif
1828 INLINE void Resize(l_rmatrix &A) noexcept;
1830 INLINE void Resize(l_rmatrix &A,const int &m, const int &n)
1831#if(CXSC_INDEX_CHECK)
1832;
1833#else
1834 noexcept;
1835#endif
1837 INLINE void Resize(l_rmatrix &A,const int &m1, const int &m2,const int &n1,const int &n2)
1838#if(CXSC_INDEX_CHECK)
1839;
1840#else
1841 noexcept;
1842#endif
1843
1845 INLINE l_rmatrix abs(const l_rmatrix &m) noexcept;
1847 INLINE l_rmatrix abs(const l_rmatrix_slice &ms) noexcept;
1848
1849//===================== Matrix / Scalar ===============================
1850
1852 INLINE l_rmatrix operator *(const l_real &c, const l_rmatrix &m) noexcept;
1854 INLINE l_rmatrix operator *(const l_real &c, const l_rmatrix_slice &ms) noexcept;
1856 INLINE l_rmatrix operator *(const l_rmatrix &m,const l_real &c) noexcept;
1858 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms,const l_real &c) noexcept;
1860 INLINE l_rmatrix &operator *=(l_rmatrix &m,const l_real &c) noexcept;
1862 INLINE l_rmatrix operator /(const l_rmatrix &m,const l_real &c) noexcept;
1864 INLINE l_rmatrix operator /(const l_rmatrix_slice &ms, const l_real &c) noexcept;
1866 INLINE l_rmatrix &operator /=(l_rmatrix &m,const l_real &c) noexcept;
1867
1868//------------ real - l_rmatrix -----------------------------------------------
1869
1871 INLINE l_rmatrix operator *(const real &c, const l_rmatrix &m) noexcept;
1873 INLINE l_rmatrix operator *(const real &c, const l_rmatrix_slice &ms) noexcept;
1875 INLINE l_rmatrix operator *(const l_rmatrix &m,const real &c) noexcept;
1877 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms,const real &c) noexcept;
1879 INLINE l_rmatrix &operator *=(l_rmatrix &m,const real &c) noexcept;
1881 INLINE l_rmatrix operator /(const l_rmatrix &m,const real &c) noexcept;
1883 INLINE l_rmatrix operator /(const l_rmatrix_slice &ms, const real &c) noexcept;
1885 INLINE l_rmatrix &operator /=(l_rmatrix &m,const real &c) noexcept;
1886//----------------- rmatrix - l_real ----------------
1887
1889 INLINE l_rmatrix operator *(const l_real &c, const rmatrix &m) noexcept;
1891 INLINE l_rmatrix operator *(const l_real &c, const rmatrix_slice &ms) noexcept;
1893 INLINE l_rmatrix operator *(const rmatrix &m,const l_real &c) noexcept;
1895 INLINE l_rmatrix operator *(const rmatrix_slice &ms,const l_real &c) noexcept;
1897 INLINE l_rmatrix operator /(const rmatrix &m,const l_real &c) noexcept;
1899 INLINE l_rmatrix operator /(const rmatrix_slice &ms, const l_real &c) noexcept;
1900
1901
1902//============================ Matrix / Vector ===================================
1903
1904
1906 INLINE l_rvector operator *(const l_rmatrix &m,const l_rvector &v)
1907#if(CXSC_INDEX_CHECK)
1908;
1909#else
1910 noexcept;
1911#endif
1913 INLINE l_rvector operator *(const l_rmatrix_slice &ms,const l_rvector &v)
1914#if(CXSC_INDEX_CHECK)
1915;
1916#else
1917 noexcept;
1918#endif
1920 INLINE l_rvector operator *(const l_rvector &v,const l_rmatrix &m)
1921#if(CXSC_INDEX_CHECK)
1922;
1923#else
1924 noexcept;
1925#endif
1927 INLINE l_rvector operator *(const l_rvector &v,const l_rmatrix_slice &ms)
1928#if(CXSC_INDEX_CHECK)
1929;
1930#else
1931 noexcept;
1932#endif
1934 INLINE l_rvector &operator *=(l_rvector &v,const l_rmatrix &m)
1935#if(CXSC_INDEX_CHECK)
1936;
1937#else
1938 noexcept;
1939#endif
1941 INLINE l_rvector &operator *=(l_rvector &v,const l_rmatrix_slice &ms)
1942#if(CXSC_INDEX_CHECK)
1943;
1944#else
1945 noexcept;
1946#endif
1947
1949 INLINE l_rvector operator *(const l_rvector_slice &v,const l_rmatrix &m)
1950#if(CXSC_INDEX_CHECK)
1951;
1952#else
1953 noexcept;
1954#endif
1956 INLINE l_rvector operator *(const l_rvector_slice &v,const l_rmatrix_slice &m)
1957#if(CXSC_INDEX_CHECK)
1958;
1959#else
1960 noexcept;
1961#endif
1962
1963//----------------- real -------------------------------------
1964
1966 INLINE l_rvector operator *(const rvector &v,const l_rmatrix &m)
1967#if(CXSC_INDEX_CHECK)
1968;
1969#else
1970 noexcept;
1971#endif
1973 INLINE l_rvector operator *(const rvector &v,const l_rmatrix_slice &ms)
1974#if(CXSC_INDEX_CHECK)
1975;
1976#else
1977 noexcept;
1978#endif
1980 INLINE l_rvector operator *(const rvector_slice &v,const l_rmatrix &m)
1981#if(CXSC_INDEX_CHECK)
1982;
1983#else
1984 noexcept;
1985#endif
1986
1988 INLINE l_rvector operator *(const l_rmatrix &m,const rvector &v)
1989#if(CXSC_INDEX_CHECK)
1990;
1991#else
1992 noexcept;
1993#endif
1995 INLINE l_rvector operator *(const l_rmatrix_slice &ms,const rvector &v)
1996#if(CXSC_INDEX_CHECK)
1997;
1998#else
1999 noexcept;
2000#endif
2001
2002
2003//================ Matrix / Matrix ============================
2004
2006 INLINE const l_rmatrix &operator +(const l_rmatrix &m1) noexcept;
2008 INLINE l_rmatrix operator +(const l_rmatrix_slice &ms) noexcept;
2010 INLINE l_rmatrix operator +(const l_rmatrix &m1,const l_rmatrix &m2)
2011#if(CXSC_INDEX_CHECK)
2012;
2013#else
2014 noexcept;
2015#endif
2017 INLINE l_rmatrix operator +(const l_rmatrix &m,const l_rmatrix_slice &ms)
2018#if(CXSC_INDEX_CHECK)
2019;
2020#else
2021 noexcept;
2022#endif
2024 INLINE l_rmatrix operator +(const l_rmatrix_slice &ms,const l_rmatrix &m)
2025#if(CXSC_INDEX_CHECK)
2026;
2027#else
2028 noexcept;
2029#endif
2031 INLINE l_rmatrix operator +(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2)
2032#if(CXSC_INDEX_CHECK)
2033;
2034#else
2035 noexcept;
2036#endif
2038 INLINE l_rmatrix &operator +=(l_rmatrix &m1,const l_rmatrix &m2)
2039#if(CXSC_INDEX_CHECK)
2040;
2041#else
2042 noexcept;
2043#endif
2045 INLINE l_rmatrix &operator +=(l_rmatrix &m1,const l_rmatrix_slice &ms)
2046#if(CXSC_INDEX_CHECK)
2047;
2048#else
2049 noexcept;
2050#endif
2051
2053 INLINE l_rmatrix operator -(const l_rmatrix &m) noexcept;
2055 INLINE l_rmatrix operator -(const l_rmatrix_slice &ms) noexcept;
2057 INLINE l_rmatrix operator -(const l_rmatrix &m1,const l_rmatrix &m2)
2058#if(CXSC_INDEX_CHECK)
2059;
2060#else
2061 noexcept;
2062#endif
2064 INLINE l_rmatrix operator -(const l_rmatrix &m,const l_rmatrix_slice &ms)
2065#if(CXSC_INDEX_CHECK)
2066;
2067#else
2068 noexcept;
2069#endif
2071 INLINE l_rmatrix operator -(const l_rmatrix_slice &ms,const l_rmatrix &m)
2072#if(CXSC_INDEX_CHECK)
2073;
2074#else
2075 noexcept;
2076#endif
2078 INLINE l_rmatrix operator -(const l_rmatrix_slice &ms1,const l_rmatrix_slice &ms2)
2079#if(CXSC_INDEX_CHECK)
2080;
2081#else
2082 noexcept;
2083#endif
2085 INLINE l_rmatrix &operator -=(l_rmatrix &m1,const l_rmatrix &m2)
2086#if(CXSC_INDEX_CHECK)
2087;
2088#else
2089 noexcept;
2090#endif
2092 INLINE l_rmatrix &operator -=(l_rmatrix &m1,const l_rmatrix_slice &ms)
2093#if(CXSC_INDEX_CHECK)
2094;
2095#else
2096 noexcept;
2097#endif
2098
2100 INLINE l_rmatrix operator *(const l_rmatrix &m1, const l_rmatrix &m2)
2101#if(CXSC_INDEX_CHECK)
2102;
2103#else
2104 noexcept;
2105#endif
2107 INLINE l_rmatrix operator *(const l_rmatrix &m1, const l_rmatrix_slice &ms)
2108#if(CXSC_INDEX_CHECK)
2109;
2110#else
2111 noexcept;
2112#endif
2114 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms, const l_rmatrix &m1)
2115#if(CXSC_INDEX_CHECK)
2116;
2117#else
2118 noexcept;
2119#endif
2121 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms1, const l_rmatrix_slice &ms2)
2122#if(CXSC_INDEX_CHECK)
2123;
2124#else
2125 noexcept;
2126#endif
2128 INLINE l_rmatrix &operator *=(l_rmatrix &m1,const l_rmatrix &m2)
2129#if(CXSC_INDEX_CHECK)
2130;
2131#else
2132 noexcept;
2133#endif
2135 INLINE l_rmatrix &operator *=(l_rmatrix &m1,const l_rmatrix_slice &ms)
2136#if(CXSC_INDEX_CHECK)
2137;
2138#else
2139 noexcept;
2140#endif
2141
2142
2143 //---------- rmatrix-l_rmatrix ------------------
2145 INLINE l_rmatrix operator +(const rmatrix &m1,const l_rmatrix &m2)
2146#if(CXSC_INDEX_CHECK)
2147;
2148#else
2149 noexcept;
2150#endif
2152 INLINE l_rmatrix operator +(const l_rmatrix &m1,const rmatrix &m2)
2153#if(CXSC_INDEX_CHECK)
2154;
2155#else
2156 noexcept;
2157#endif
2159 INLINE l_rmatrix operator +(const rmatrix &m,const l_rmatrix_slice &ms)
2160#if(CXSC_INDEX_CHECK)
2161;
2162#else
2163 noexcept;
2164#endif
2166 INLINE l_rmatrix operator +(const l_rmatrix &m,const rmatrix_slice &ms)
2167#if(CXSC_INDEX_CHECK)
2168;
2169#else
2170 noexcept;
2171#endif
2173 INLINE l_rmatrix operator +(const rmatrix_slice &ms,const l_rmatrix &m)
2174#if(CXSC_INDEX_CHECK)
2175;
2176#else
2177 noexcept;
2178#endif
2180 INLINE l_rmatrix operator +(const l_rmatrix_slice &ms,const rmatrix &m)
2181#if(CXSC_INDEX_CHECK)
2182;
2183#else
2184 noexcept;
2185#endif
2187 INLINE l_rmatrix operator +(const rmatrix_slice &m1,const l_rmatrix_slice &m2)
2188#if(CXSC_INDEX_CHECK)
2189;
2190#else
2191 noexcept;
2192#endif
2194 INLINE l_rmatrix operator +(const l_rmatrix_slice &m1,const rmatrix_slice &m2)
2195#if(CXSC_INDEX_CHECK)
2196;
2197#else
2198 noexcept;
2199#endif
2201 INLINE l_rmatrix &operator +=(l_rmatrix &m1,const rmatrix &m2)
2202#if(CXSC_INDEX_CHECK)
2203;
2204#else
2205 noexcept;
2206#endif
2208 INLINE l_rmatrix &operator +=(l_rmatrix &m1,const rmatrix_slice &ms)
2209#if(CXSC_INDEX_CHECK)
2210;
2211#else
2212 noexcept;
2213#endif
2214
2216 INLINE l_rmatrix operator -(const rmatrix &m1,const l_rmatrix &m2)
2217#if(CXSC_INDEX_CHECK)
2218;
2219#else
2220 noexcept;
2221#endif
2223 INLINE l_rmatrix operator -(const l_rmatrix &m1,const rmatrix &m2)
2224#if(CXSC_INDEX_CHECK)
2225;
2226#else
2227 noexcept;
2228#endif
2230 INLINE l_rmatrix operator -(const rmatrix &m,const l_rmatrix_slice &ms)
2231#if(CXSC_INDEX_CHECK)
2232;
2233#else
2234 noexcept;
2235#endif
2237 INLINE l_rmatrix operator -(const l_rmatrix &m,const rmatrix_slice &ms)
2238#if(CXSC_INDEX_CHECK)
2239;
2240#else
2241 noexcept;
2242#endif
2244 INLINE l_rmatrix operator -(const rmatrix_slice &ms,const l_rmatrix &m)
2245#if(CXSC_INDEX_CHECK)
2246;
2247#else
2248 noexcept;
2249#endif
2251 INLINE l_rmatrix operator -(const l_rmatrix_slice &ms,const rmatrix &m)
2252#if(CXSC_INDEX_CHECK)
2253;
2254#else
2255 noexcept;
2256#endif
2258 INLINE l_rmatrix operator -(const rmatrix_slice &ms1,const l_rmatrix_slice &ms2)
2259#if(CXSC_INDEX_CHECK)
2260;
2261#else
2262 noexcept;
2263#endif
2265 INLINE l_rmatrix operator -(const l_rmatrix_slice &ms1,const rmatrix_slice &ms2)
2266#if(CXSC_INDEX_CHECK)
2267;
2268#else
2269 noexcept;
2270#endif
2272 INLINE l_rmatrix &operator -=(l_rmatrix &m1,const rmatrix &m2)
2273#if(CXSC_INDEX_CHECK)
2274;
2275#else
2276 noexcept;
2277#endif
2279 INLINE l_rmatrix &operator -=(l_rmatrix &m1,const rmatrix_slice &ms)
2280#if(CXSC_INDEX_CHECK)
2281;
2282#else
2283 noexcept;
2284#endif
2285
2287 INLINE l_rmatrix operator *(const rmatrix &m1, const l_rmatrix &m2)
2288#if(CXSC_INDEX_CHECK)
2289;
2290#else
2291 noexcept;
2292#endif
2294 INLINE l_rmatrix operator *(const l_rmatrix &m1, const rmatrix &m2)
2295#if(CXSC_INDEX_CHECK)
2296;
2297#else
2298 noexcept;
2299#endif
2301 INLINE l_rmatrix operator *(const rmatrix &m1, const l_rmatrix_slice &ms)
2302#if(CXSC_INDEX_CHECK)
2303;
2304#else
2305 noexcept;
2306#endif
2308 INLINE l_rmatrix operator *(const l_rmatrix &m1, const rmatrix_slice &ms)
2309#if(CXSC_INDEX_CHECK)
2310;
2311#else
2312 noexcept;
2313#endif
2315 INLINE l_rmatrix operator *(const rmatrix_slice &ms, const l_rmatrix &m1)
2316#if(CXSC_INDEX_CHECK)
2317;
2318#else
2319 noexcept;
2320#endif
2322 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms, const rmatrix &m1)
2323#if(CXSC_INDEX_CHECK)
2324;
2325#else
2326 noexcept;
2327#endif
2329 INLINE l_rmatrix operator *(const rmatrix_slice &ms1, const l_rmatrix_slice &ms2)
2330#if(CXSC_INDEX_CHECK)
2331;
2332#else
2333 noexcept;
2334#endif
2336 INLINE l_rmatrix operator *(const l_rmatrix_slice &ms1, const rmatrix_slice &ms2)
2337#if(CXSC_INDEX_CHECK)
2338;
2339#else
2340 noexcept;
2341#endif
2343 INLINE l_rmatrix &operator *=(l_rmatrix &m1,const rmatrix &m2)
2344#if(CXSC_INDEX_CHECK)
2345;
2346#else
2347 noexcept;
2348#endif
2350 INLINE l_rmatrix &operator *=(l_rmatrix &m1,const rmatrix_slice &ms)
2351#if(CXSC_INDEX_CHECK)
2352;
2353#else
2354 noexcept;
2355#endif
2356
2357
2358//============== Compare Operator ==========================
2359
2360//-------------- Matrix - Matrix -------------------------
2361
2363 INLINE bool operator ==(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2365 INLINE bool operator !=(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2367 INLINE bool operator <(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2369 INLINE bool operator <=(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2371 INLINE bool operator >(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2373 INLINE bool operator >=(const l_rmatrix &m1,const l_rmatrix &m2) noexcept;
2375 INLINE bool operator ==(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2377 INLINE bool operator !=(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2379 INLINE bool operator <(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2381 INLINE bool operator <=(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2383 INLINE bool operator >(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2385 INLINE bool operator >=(const l_rmatrix &m1,const l_rmatrix_slice &ms) noexcept;
2386
2387//---------------- Matrix - Matrix_slice ----------------------
2388
2390 INLINE bool operator ==(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2392 INLINE bool operator !=(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2394 INLINE bool operator <(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2396 INLINE bool operator <=(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2398 INLINE bool operator >(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2400 INLINE bool operator >=(const l_rmatrix_slice &m1,const l_rmatrix_slice &m2) noexcept;
2401
2402//=================== Not Operator =============================
2403
2405 INLINE bool operator !(const l_rmatrix &ms) noexcept;
2407 INLINE bool operator !(const l_rmatrix_slice &ms) noexcept;
2408
2409//======================== Input / Output ========================
2410
2412 INLINE std::ostream &operator <<(std::ostream &s,const l_rmatrix &r) noexcept;
2414 INLINE std::ostream &operator <<(std::ostream &s,const l_rmatrix_slice &r) noexcept;
2416 INLINE std::istream &operator >>(std::istream &s,l_rmatrix &r) noexcept;
2418 INLINE std::istream &operator >>(std::istream &s,l_rmatrix_slice &r) noexcept;
2419
2421 INLINE int RowLen ( const l_rmatrix& );
2423 INLINE int ColLen ( const l_rmatrix& );
2425 INLINE int RowLen ( const l_rmatrix_slice& );
2427 INLINE int ColLen ( const l_rmatrix_slice& );
2429 l_rmatrix Id ( const l_rmatrix& );
2431 l_rmatrix transp ( const l_rmatrix& );
2433 void DoubleSize ( l_rmatrix& );
2434
2435} // namespace cxsc
2436
2437#ifdef _CXSC_INCL_INL
2438#include "matrix.inl"
2439#include "l_rmatrix.inl"
2440#endif
2441
2442#ifdef _CXSC_LIVECTOR_HPP_INCLUDED
2443# ifdef _CXSC_INCL_INL
2444# include "liveclrmat.inl"
2445# else
2446# include "liveclrmat.hpp"
2447# endif
2448#endif
2449
2450#ifdef _CXSC_IVECTOR_HPP_INCLUDED
2451# ifdef _CXSC_INCL_INL
2452# include "iveclrmat.inl"
2453# else
2454# include "iveclrmat.hpp"
2455# endif
2456#endif
2457
2458#ifdef _CXSC_IMATRIX_HPP_INCLUDED
2459# ifdef _CXSC_INCL_INL
2460# include "lrmatimat.inl"
2461# else
2462# include "lrmatimat.hpp"
2463# endif
2464#endif
2465
2466
2467#endif
2468
The Data Type dotprecision.
Definition dot.hpp:112
The Data Type idotprecision.
Definition idot.hpp:48
The Multiple-Precision Data Type l_imatrix.
The Multiple-Precision Data Type l_ivector.
Definition l_ivector.hpp:55
The Multiple-Precision Data Type l_real.
Definition l_real.hpp:78
The Multiple-Precision Data Type l_rmatrix_slice.
l_rmatrix_subv operator[](const int &i) const noexcept
Operator for accessing a single row of the matrix.
l_rmatrix_slice & operator()() noexcept
Operator for accessing the whole matrix.
l_rmatrix_slice(l_rmatrix_slice &a, const int &l1, const int &u1, const int &l2, const int &u2) noexcept
Constructor of class l_rmatrix_slice.
l_rmatrix_slice & operator=(const l_rmatrix &m) noexcept
Implementation of standard assigning operator.
l_rmatrix_slice(l_rmatrix &a, const int &l1, const int &u1, const int &l2, const int &u2) noexcept
Constructor of class l_rmatrix_slice.
l_rmatrix_slice & operator/=(const l_real &c) noexcept
Implementation of division and allocation operation.
l_rmatrix_slice & operator|=(const l_rmatrix &m1) noexcept
Allocates the convex hull of the arguments to the first argument.
l_rmatrix_slice(const l_rmatrix_slice &ms) noexcept
Constructor of class l_rmatrix_slice.
l_rmatrix_slice & operator+=(const l_rmatrix &m1) noexcept
Implementation of addition and allocation operation.
l_rmatrix_slice & operator*=(const l_rmatrix &m) noexcept
Implementation of multiplication and allocation operation.
l_rmatrix_slice & operator-=(const l_rmatrix &m1) noexcept
Implementation of subtraction and allocation operation.
The Multiple-Precision Data Type l_rmatrix_subv.
Definition l_rmatrix.hpp:47
l_rmatrix_subv & operator*=(const l_real &c) noexcept
Implementation of multiplication and allocation operation.
l_rmatrix_subv & operator=(const l_rmatrix_subv &rv) noexcept
Implementation of standard assigning operator.
l_rmatrix_subv(const l_rmatrix_subv &v) noexcept
Constructor of class l_rmatrix_subv.
l_rmatrix_subv & operator()() noexcept
Operator for accessing the whole vector.
friend l_rmatrix_subv Col(l_rmatrix &m, const int &i) noexcept
Returns one column of the matrix as a vector.
l_real & operator[](const int &i) const noexcept
Operator for accessing the single elements of the vector.
friend l_rmatrix_subv Row(l_rmatrix &m, const int &i) noexcept
Returns one row of the matrix as a vector.
friend int Lb(const l_rmatrix_subv &rv) noexcept
Returns the lower bound of the vector.
l_rmatrix_subv & operator+=(const l_real &c) noexcept
Implementation of addition and allocation operation.
l_rmatrix_subv & operator/=(const l_real &c) noexcept
Implementation of division and allocation operation.
l_rmatrix_subv(l_real *d, const int &l, const int &u, const int &s, const int &st, const int &o) noexcept
Constructor of class l_rmatrix_subv.
l_rmatrix_subv & operator-=(const l_real &c) noexcept
Implementation of subtraction and allocation operation.
friend int Ub(const l_rmatrix_subv &rv) noexcept
Returns the upper bound of the vector.
The Multiple-Precision Data Type l_rmatrix.
l_rmatrix & operator=(const l_real &r) noexcept
Implementation of standard assigning operator.
l_rmatrix_subv operator[](const int &i) const noexcept
Operator for accessing a single row of the matrix.
l_rmatrix & operator()() noexcept
Operator for accessing the whole matrix.
l_rmatrix() noexcept
Constructor of class l_rmatrix.
Definition l_rmatrix.inl:31
The Multiple-Precision Data Type l_rvector_slice.
The Multiple-Precision Data Type l_rvector.
Definition l_rvector.hpp:54
l_rvector() noexcept
Constructor of class l_rvector.
Definition l_rvector.inl:31
The Scalar Type real.
Definition real.hpp:114
The Data Type rmatrix_slice.
Definition rmatrix.hpp:1443
The Data Type rmatrix_subv.
Definition rmatrix.hpp:54
The Data Type rmatrix.
Definition rmatrix.hpp:471
The Data Type rvector_slice.
Definition rvector.hpp:1064
The Data Type rvector.
Definition rvector.hpp:58
The namespace cxsc, providing all functionality of the class library C-XSC.
Definition cdot.cpp:29
cdotprecision & operator+=(cdotprecision &cd, const l_complex &lc) noexcept
Implementation of standard algebraic addition and allocation operation.
Definition cdot.inl:251
int ColLen(const cimatrix &)
Returns the column dimension.
civector operator/(const cimatrix_subv &rv, const cinterval &s) noexcept
Implementation of division operation.
Definition cimatrix.inl:730
cimatrix transp(const cimatrix &A)
Returns the transposed matrix.
Definition cimatrix.cpp:74
int Ub(const cimatrix &rm, const int &i) noexcept
Returns the upper bound index.
cimatrix & SetLb(cimatrix &m, const int &i, const int &j) noexcept
Sets the lower bound index.
int RowLen(const cimatrix &)
Returns the row dimension.
void DoubleSize(cimatrix &A)
Doubles the size of the matrix.
Definition cimatrix.cpp:83
cimatrix Id(const cimatrix &A)
Returns the Identity matrix.
Definition cimatrix.cpp:61
cimatrix & operator*=(cimatrix &m, const cinterval &c) noexcept
Implementation of multiplication and allocation operation.
ivector abs(const cimatrix_subv &mv) noexcept
Returns the absolute value of the matrix.
Definition cimatrix.inl:737
civector operator*(const cimatrix_subv &rv, const cinterval &s) noexcept
Implementation of multiplication operation.
Definition cimatrix.inl:731
void Resize(cimatrix &A) noexcept
Resizes the matrix.
l_rmatrix _l_rmatrix(const l_rmatrix &rm) noexcept
Deprecated typecast, which only exist for the reason of compatibility with older versions of C-XSC.
cimatrix & SetUb(cimatrix &m, const int &i, const int &j) noexcept
Sets the upper bound index.
int Lb(const cimatrix &rm, const int &i) noexcept
Returns the lower bound index.
cimatrix & operator/=(cimatrix &m, const cinterval &c) noexcept
Implementation of division and allocation operation.