{"id":45572,"date":"2025-07-01T08:37:48","date_gmt":"2025-07-01T08:37:48","guid":{"rendered":"https:\/\/gaviki.com\/blog\/?p=45572"},"modified":"2025-07-01T08:37:50","modified_gmt":"2025-07-01T08:37:50","slug":"find-a-qr-factorization-for-the-matrix-a","status":"publish","type":"post","link":"https:\/\/gaviki.com\/blog\/find-a-qr-factorization-for-the-matrix-a\/","title":{"rendered":"Find a QR factorization for the matrix A."},"content":{"rendered":"\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"700\" height=\"306\" src=\"https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/image-14.png\" alt=\"\" class=\"wp-image-45573\" srcset=\"https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/image-14.png 700w, https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/image-14-300x131.png 300w\" sizes=\"auto, (max-width: 700px) 100vw, 700px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\"><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-cyan-blue-color\">The Correct Answer and Explanation is:<\/mark><\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">To find the QR factorization of the matrix A, we need to find an orthogonal matrix Q and an upper triangular matrix R such that A = QR. We can achieve this using the Gram-Schmidt process on the columns of A.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Let the columns of A be&nbsp;a\u2081,&nbsp;a\u2082, and&nbsp;a\u2083:<br>a\u2081 = [4, 1, 3]<br>a\u2082 = [2, 5, -3]<br>a\u2083 = [0, -5, 3]<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Step 1: Find the columns of Q (an orthonormal basis)<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>First column:<\/strong><br>Let&nbsp;u\u2081 = a\u2081 = [4, 1, 3].<br>The norm is&nbsp;||u\u2081|| = \u221a(4\u00b2 + 1\u00b2 + 3\u00b2) = \u221a(16 + 1 + 9) = \u221a26.<br>The first column of Q is&nbsp;q\u2081 = u\u2081 \/ ||u\u2081|| = (1\/\u221a26) * [4, 1, 3].<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Second column:<\/strong><br>First, we find an orthogonal vector&nbsp;u\u2082.<br>u\u2082 = a\u2082 &#8211; proj_u\u2081(a\u2082)&nbsp;where&nbsp;proj_u\u2081(a\u2082) = ((a\u2082 \u22c5 u\u2081) \/ (u\u2081 \u22c5 u\u2081)) * u\u2081.<br>a\u2082 \u22c5 u\u2081 = (2)(4) + (5)(1) + (-3)(3) = 8 + 5 &#8211; 9 = 4.<br>u\u2081 \u22c5 u\u2081 = ||u\u2081||\u00b2 = 26.<br>u\u2082 = a\u2082 &#8211; (4\/26) * u\u2081 = [2, 5, -3] &#8211; (2\/13) * [4, 1, 3]<br>u\u2082 = [2 &#8211; 8\/13, 5 &#8211; 2\/13, -3 &#8211; 6\/13] = [18\/13, 63\/13, -45\/13].<br>To simplify, we can use a scaled vector, for example&nbsp;(13\/9) * u\u2082 = [2, 7, -5]. Let&#8217;s call this simplified vector&nbsp;u\u2082&#8217;.<br>The norm is&nbsp;||u\u2082&#8217;|| = \u221a(2\u00b2 + 7\u00b2 + (-5)\u00b2) = \u221a(4 + 49 + 25) = \u221a78.<br>The second column of Q is&nbsp;q\u2082 = u\u2082&#8217; \/ ||u\u2082&#8217;|| = (1\/\u221a78) * [2, 7, -5].<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Third column:<\/strong><br>First, we find an orthogonal vector&nbsp;u\u2083.<br>u\u2083 = a\u2083 &#8211; proj_u\u2081(a\u2083) &#8211; proj_u&#8217;\u2082(a\u2083).<br>a\u2083 \u22c5 u\u2081 = (0)(4) + (-5)(1) + (3)(3) = -5 + 9 = 4.<br>a\u2083 \u22c5 u\u2082&#8217; = (0)(2) + (-5)(7) + (3)(-5) = -35 &#8211; 15 = -50.<br>u\u2083 = a\u2083 &#8211; (4\/26)u\u2081 &#8211; (-50\/78)u\u2082&#8217; = [0,-5,3] &#8211; (2\/13)[4,1,3] + (25\/39)[2,7,-5].<br>u\u2083 = [0-24\/39+50\/39, -195\/39-6\/39+175\/39, 117\/39-18\/39-125\/39] = [26\/39, -26\/39, -26\/39] = [2\/3, -2\/3, -2\/3].<br>Again, we can use a scaled vector,&nbsp;3 * u\u2083 = [2, -2, -2], or even simpler,&nbsp;[1, -1, -1]. Let&#8217;s call this&nbsp;u\u2083&#8217;.<br>The norm is&nbsp;||u\u2083&#8217;|| = \u221a(1\u00b2 + (-1)\u00b2 + (-1)\u00b2) = \u221a3.<br>The third column of Q is&nbsp;q\u2083 = u\u2083&#8217; \/ ||u\u2083&#8217;|| = (1\/\u221a3) * [1, -1, -1].<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">So, the matrix Q is:<br>Q = [ 4\/\u221a26 2\/\u221a78 1\/\u221a3 ]<br>[ 1\/\u221a26 7\/\u221a78 -1\/\u221a3 ]<br>[ 3\/\u221a26 -5\/\u221a78 -1\/\u221a3 ]<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Step 2: Find the matrix R<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Since&nbsp;A = QR&nbsp;and&nbsp;Q&nbsp;is orthogonal (Q\u1d40Q = I), we have&nbsp;R = Q\u1d40A. The entries of R are&nbsp;r\u1d62\u2c7c = q\u1d62 \u22c5 a\u2c7c.<br>r\u2081\u2081 = q\u2081 \u22c5 a\u2081 = ||u\u2081|| = \u221a26<br>r\u2081\u2082 = q\u2081 \u22c5 a\u2082 = 4\/\u221a26<br>r\u2081\u2083 = q\u2081 \u22c5 a\u2083 = 4\/\u221a26<br>r\u2082\u2081 = q\u2082 \u22c5 a\u2081 = 0&nbsp;(by orthogonality)<br>r\u2082\u2082 = q\u2082 \u22c5 a\u2082 = ((1\/\u221a78)[2,7,-5]) \u22c5 [2,5,-3] = (4+35+15)\/\u221a78 = 54\/\u221a78<br>r\u2082\u2083 = q\u2082 \u22c5 a\u2083 = ((1\/\u221a78)[2,7,-5]) \u22c5 [0,-5,3] = (-35-15)\/\u221a78 = -50\/\u221a78<br>r\u2083\u2081 = q\u2083 \u22c5 a\u2081 = 0&nbsp;(by orthogonality)<br>r\u2083\u2082 = q\u2083 \u22c5 a\u2082 = 0&nbsp;(by orthogonality)<br>r\u2083\u2083 = q\u2083 \u22c5 a\u2083 = ((1\/\u221a3)[1,-1,-1]) \u22c5 [0,-5,3] = (5-3)\/\u221a3 = 2\/\u221a3<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">So, the matrix R is:<br>R = [ \u221a26 4\/\u221a26 4\/\u221a26 ]<br>[ 0 54\/\u221a78 -50\/\u221a78 ]<br>[ 0 0 2\/\u221a3 ]<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Final Answer:<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Q =<br>[[ 4\/sqrt(26), 2\/sqrt(78), 1\/sqrt(3) ],<br>[ 1\/sqrt(26), 7\/sqrt(78), -1\/sqrt(3) ],<br>[ 3\/sqrt(26), -5\/sqrt(78), -1\/sqrt(3) ]]<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">R =<br>[[ sqrt(26), 4\/sqrt(26), 4\/sqrt(26) ],<br>[ 0, 54\/sqrt(78), -50\/sqrt(78) ],<br>[ 0, 0, 2\/sqrt(3) ]]thumb_upthumb_down<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"1024\" src=\"https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/learnexams-banner5-42.jpeg\" alt=\"\" class=\"wp-image-45574\" srcset=\"https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/learnexams-banner5-42.jpeg 1024w, https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/learnexams-banner5-42-300x300.jpeg 300w, https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/learnexams-banner5-42-150x150.jpeg 150w, https:\/\/gaviki.com\/blog\/wp-content\/uploads\/2025\/07\/learnexams-banner5-42-768x768.jpeg 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>The Correct Answer and Explanation is: To find the QR factorization of the matrix A, we need to find an orthogonal matrix Q and an upper triangular matrix R such that A = QR. We can achieve this using the Gram-Schmidt process on the columns of A. Let the columns of A be&nbsp;a\u2081,&nbsp;a\u2082, and&nbsp;a\u2083:a\u2081 = [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-45572","post","type-post","status-publish","format-standard","hentry","category-quiz-questions"],"_links":{"self":[{"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/posts\/45572","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/comments?post=45572"}],"version-history":[{"count":1,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/posts\/45572\/revisions"}],"predecessor-version":[{"id":45575,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/posts\/45572\/revisions\/45575"}],"wp:attachment":[{"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/media?parent=45572"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/categories?post=45572"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gaviki.com\/blog\/wp-json\/wp\/v2\/tags?post=45572"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}