Mercurial > repos > public > sbplib
view spdiag.m @ 856:ee4cfb37534d feature/poroelastic
Merge with feature/d1_staggered to get RK timestepper for discrete data.
author | Martin Almquist <malmquist@stanford.edu> |
---|---|
date | Tue, 02 Oct 2018 13:39:10 -0700 |
parents | e76321b89c1e |
children |
line wrap: on
line source
function A = spdiag(a,i) default_arg('i',0); if isrow(a) a = a'; end n = length(a)+abs(i); A = spdiags(a,i,n,n); end