diff spdiagsVariablePeriodic.m @ 683:50e77b15d841 feature/poroelastic

Bugfix in spdiagsVariablePeriodic
author Martin Almquist <malmquist@stanford.edu>
date Thu, 08 Feb 2018 16:02:20 -0800
parents 7368affc8f78
children 8c65ef13df89
line wrap: on
line diff
--- a/spdiagsVariablePeriodic.m	Wed Feb 07 15:42:50 2018 -0800
+++ b/spdiagsVariablePeriodic.m	Thu Feb 08 16:02:20 2018 -0800
@@ -27,7 +27,7 @@
         % Super-diagonals
         elseif d > 0
             a_bulk = a(1:end-d);
-            a_corner = a(end-d+1,end);
+            a_corner = a(end-d+1:end);
             corner_diag = -m + d;
             A = A + spdiagVariable(a_bulk, d); 
             A = A + spdiagVariable(a_corner, corner_diag);