{"id":4814,"date":"2022-12-19T17:25:46","date_gmt":"2022-12-19T09:25:46","guid":{"rendered":"https:\/\/fanyuzhao.com\/?p=4814"},"modified":"2022-12-19T19:29:31","modified_gmt":"2022-12-19T11:29:31","slug":"kkt-for-optimisation","status":"publish","type":"post","link":"https:\/\/fanyuzhao.com\/?p=4814","title":{"rendered":"KKT for Optimisation"},"content":{"rendered":"\n<h4 class=\"wp-block-heading\">Optimisation<\/h4>\n\n\n\n<p>Suppose <span class=\"katex math inline\">f, g_1, g_2, &#8230;, g_m<\/span> are differentiable.<\/p>\n\n\n\n<p>$$ \\max_{x_1, x_2,&#8230;, x_n} f(x_1, x_2, &#8230;, x_n) $$<\/p>\n\n\n\n<p>$$s.t. g_1(x_1, x_2, &#8230;, x_n)\\geq 0 $$<\/p>\n\n\n\n<p>$$\\quad g_2(x_1, x_2, &#8230;, x_n)\\geq 0 $$<\/p>\n\n\n\n<p>$$\\quad &#8230;&#8230;$$<\/p>\n\n\n\n<p>$$\\quad g_m(x_1, x_2, &#8230;, x_n)\\geq 0 $$<\/p>\n\n\n\n<p>There are <span class=\"katex math inline\">m<\/span> constraints <span class=\"katex math inline\">g_i, i \\in (1,m)<\/span>, and one object function <span class=\"katex math inline\">f<\/span> to maximum. <span class=\"katex math inline\">n<\/span> variables. <\/p>\n\n\n\n<h4 class=\"wp-block-heading\">KKT Conditions<\/h4>\n\n\n\n<p><strong>Suppose the constraint qualification is satisfied. <\/strong>A local maximiser of the above problem <span class=\"katex math inline\">\\bar{x} = (\\bar{x_1}, \\bar{x_2},&#8230; \\bar{x_n})<\/span> together with some <span class=\"katex math inline\">\\bar{lambda_1}, \\bar{lambda_2}, &#8230;, \\bar{lambda_m} \\geq 0<\/span> satisfies the following:<\/p>\n\n\n\n<p>$$ \\frac{\\partial f}{\\partial x_i}(\\bar{x}) + \\lambda_1 \\frac{\\partial g_1}{\\partial x_i}(\\bar{x})+ \\lambda_2 \\frac{\\partial g_2}{\\partial x_i}(\\bar{x}) +&#8230;+ \\lambda_{m} \\frac{\\partial g_m}{\\partial x_i}(\\bar{x}) = 0$$<\/p>\n\n\n\n<p>for <span class=\"katex math inline\">i=1,2,&#8230;,n<\/span>, <strong>and<\/strong> <\/p>\n\n\n\n<p>$$\\bar{\\lambda_k} g_k(\\bar{x})=0$$<\/p>\n\n\n\n<p>for <span class=\"katex math inline\">k=1,2,&#8230;,m<\/span><\/p>\n\n\n\n<ul><li>We have state &#8220;Suppose the constraint qualification is satisfied&#8221; in the beginning. <strong>What is the qualification?<\/strong><\/li><\/ul>\n\n\n\n<p>See step 4 in the next section.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Solve the Maximisation Problem<\/h4>\n\n\n\n<ul><li>Step 1. Step up the Lagrangian<\/li><li>Step 2. Write down the KKT conditions and constraints.<\/li><li>Step 3. Solve the equation set. (P.S. Discuss the complementary slackness, and confirm the possible solutions)<\/li><li>Step 4. Check constraint qualification.<\/li><\/ul>\n\n\n\n<ul><li><strong>Step 4.<\/strong><\/li><\/ul>\n\n\n\n<p>Constraint Set, <span class=\"katex math inline\">C=\\{ (x_1, x_2, &#8230;, x_n)\\in \\mathbb{R}^n | g_k(x_1, x_2, &#8230;, x_m) \\geq 0 \\}<\/span> for <span class=\"katex math inline\">k=1,2,&#8230;,m<\/span>.<\/p>\n\n\n\n<p>The constraint qualification is satisfied at <span class=\"katex math inline\">\\bar{x} in C<\/span>, if the constraints that hold at <span class=\"katex math inline\">\\bar{x}<\/span> with equality are independent. That is, if the <span class=\"katex math inline\">m<\/span> vectors <\/p>\n\n\n\n<p>$$ \\nabla g_k(\\bar{x})=\\bigg(  \\frac{\\partial g_k}{\\partial x_1}(\\bar{x}), \\frac{\\partial g_k}{\\partial x_2}(\\bar{x}),&#8230;,\\frac{\\partial g_k}{\\partial x_n}(\\bar{x})  \\bigg)&#8217; $$<\/p>\n\n\n\n<p>for <span class=\"katex math inline\">k=1,2,&#8230;,m<\/span> are independent.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Optimisation Suppose f, g_1, g_2, &#8230;, g_m are differentiable. $$ \\max_{x_1, x_2,&#8230;, x_n} f(x_1, x_2, &#8230;, x_n) $$ $$s.t. g_1(x_1, x_2, &#8230;, x_n)\\geq 0 $$ $$\\quad g_2(x_1, x_2, &#8230;, x_n)\\geq 0 $$ $$\\quad &#8230;&#8230;$$ $$\\quad g_m(x_1, x_2, &#8230;, x_n)\\geq 0 $$ There are m constraints g_i, i \\in (1,m), and one object function f to &hellip; <a href=\"https:\/\/fanyuzhao.com\/?p=4814\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">KKT for Optimisation<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,18],"tags":[],"_links":{"self":[{"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/posts\/4814"}],"collection":[{"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4814"}],"version-history":[{"count":32,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/posts\/4814\/revisions"}],"predecessor-version":[{"id":4849,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=\/wp\/v2\/posts\/4814\/revisions\/4849"}],"wp:attachment":[{"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4814"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4814"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fanyuzhao.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4814"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}