{"id":426,"date":"2017-09-14T12:17:05","date_gmt":"2017-09-14T15:17:05","guid":{"rendered":"http:\/\/www.professores.uff.br\/diomarcesarlobao\/?page_id=426"},"modified":"2017-09-14T12:17:05","modified_gmt":"2017-09-14T15:17:05","slug":"slu-m","status":"publish","type":"page","link":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/slu-m\/","title":{"rendered":"slu.m"},"content":{"rendered":"<pre>function [L, U] = slu(A)\r\n\r\n% slu  LU factorization of a square matrix using *no row exchanges*.\r\n%\r\n% [L, U] = slu(A) uses Gaussian elimination to compute a unit \r\n% lower triangular L and an upper triangular U so that L*U = A.\r\n% The algorithm will stop if a pivot entry is very small.\r\n%\r\n% See also slv, plu, lu.\r\n\r\n[n, n] = size(A);\r\n\r\nfor k = 1:n\r\n   if abs(A(k, k)) &lt; sqrt(eps)\r\n      disp(['Small pivot encountered in column ' int2str(k) '.'])\r\n   end\r\n   L(k, k) = 1;\r\n   for i = k+1:n\r\n      L(i,k) = A(i, k) \/ A(k, k);\r\n      for j = k+1:n\r\n         A(i, j) = A(i, j) - L(i, k)*A(k, j);\r\n      end\r\n   end\r\n   for j = k:n\r\n      U(k, j) = A(k, j);\r\n   end\r\nend<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>function [L, U] = slu(A) % slu LU factorization of a square matrix using *no row exchanges*. % % [L, U] = slu(A) uses Gaussian elimination to compute a unit % lower triangular L and an upper triangular U so that L*U = A. % The algorithm will stop if a pivot entry is very [&hellip;]<\/p>\n","protected":false},"author":22,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"categories":[],"tags":[],"class_list":["post-426","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/426","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/users\/22"}],"replies":[{"embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/comments?post=426"}],"version-history":[{"count":1,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/426\/revisions"}],"predecessor-version":[{"id":427,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/426\/revisions\/427"}],"wp:attachment":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/media?parent=426"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/categories?post=426"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/tags?post=426"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}