new file: ts_smoke_xr.py
[wrf-fire-matlab.git] / femwind / sweeps_fortran.m
blob1ecd23e5f3564c50265c73ce87ce987dbc47b83b
1 function err=sweeps_fortran(K,K14,n1,n2,n3,F,X,x)
3 % compare the result of matlab ndt_mult and fortran ndt_mult
4 y=vertical_sweeps(K,F,X,x);
6 % x_size = size(x,1);
7 % F_size = size(F,1);
8
9 x_r = reshape(x,n1,n2,n3);
10 F_r = reshape(F,n1,n2,n3);
12 write_array_nd(K14,'Kmat');
13 write_array_nd(F_r,'Fmat');
14 write_array_nd(x_r,'x_sweeps');
16 system('./fortran/sweeps_test.exe');
18 y_f=read_array_nd('x_sweeps');
20 err=norm(y(:)-y_f(:),inf);
23 end