Mercurial > repos > public > sbplib
view spdiag.m @ 1347:ac54767ae1fb feature/poroelastic tip
Add interface, not fully compatible.
author | Martin Almquist <martin.almquist@it.uu.se> |
---|---|
date | Tue, 30 Apr 2024 14:58:35 +0200 |
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