gitinore *.txt files
[wrf-fire-matlab.git] / femwind / vertical_sweeps.m
blobb9e6b0170777061c45e06799ce1ed612e2880b5e
1 function [x]=vertical_sweeps(K,F,X,x)
3 n = size(X{1});
5 for rb1=1:2
6     for rb2=1:2
7         for i1=rb1:2:n(1)
8             for i2=rb2:2:n(2)
9             % solving horizontal location i1 i2 and vertical line
10                 for i3=1:n(3)
11                     ix = sub2ind(n,i1,i2,i3); 
12                     x(ix) = x(ix) - K(ix,ix)\(K(:,ix)'*x - F(ix));
13                 end
14             end
15         end
16     end
17 end
18 end