[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Toon-members] TooN linoperators.hh
From: |
Edward Rosten |
Subject: |
[Toon-members] TooN linoperators.hh |
Date: |
Wed, 17 Oct 2007 00:13:07 +0000 |
CVSROOT: /cvsroot/toon
Module name: TooN
Changes by: Edward Rosten <edrosten> 07/10/17 00:13:07
Modified files:
. : linoperators.hh
Log message:
Make Matrix<> += Matrix<> work.
I should have done something with vaccessors, but I can't figure it
out.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/TooN/linoperators.hh?cvsroot=toon&r1=1.17&r2=1.18
Patches:
Index: linoperators.hh
===================================================================
RCS file: /cvsroot/toon/TooN/linoperators.hh,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -b -r1.17 -r1.18
--- linoperators.hh 23 Aug 2007 16:19:14 -0000 1.17
+++ linoperators.hh 17 Oct 2007 00:13:07 -0000 1.18
@@ -847,9 +847,9 @@
DynamicMatrix<MAccessor1>& operator += ( DynamicMatrix<MAccessor1>& lhs,
const DynamicMatrix<MAccessor2>& rhs){
assert(lhs.num_rows() == rhs.num_rows() && lhs.num_cols() == rhs.num_cols());
- for(int r=0; r<lhs.num_rows(); r++){
- lhs[r] += rhs[r];
- }
+ for(int r=0; r<lhs.num_rows(); r++)
+ for(int c=0; c <lhs.num_cols(); c++)
+ lhs[r][c] += rhs[r][c];
return lhs;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Toon-members] TooN linoperators.hh,
Edward Rosten <=