ts_smoke.py runs
[wrf-fire-matlab.git] / quicwind / adj_mat_test.m
blobbcbed310a01d2acc67043ef63b428625b3e89092
1 function err=adj_mat_test
2 disp('adj_mat_test')
3 % disp('creating matrix representation of div3 and grad3')
4 n=[2,2,2];
5 h=rand(1,3);
6 g=@(u)cell2vec(grad3z(u,h));
7 u=zeros(n);t=grad3z(u,h);  % size template
8 d=@(u)div3(vec2cell(u,t),h);
9 gm=fun2mat(g,n);  % gradient matrix
10 dm=fun2mat(d,[size(gm,1),1,1]);
11 err=big(dm+gm')