SlideShare a Scribd company logo
3
Most read
4
Most read
7
Most read
Quadratic Programming
Dr. Varun Kumar
Dr. Varun Kumar Lecture 2 1 / 12
Outlines
1 Introduction to Quadratic Programming
2 Problem and Solution by Graphical Method
3 Karush Kuhn Tucker (KKT) Condition
Dr. Varun Kumar Lecture 2 2 / 12
Introduction to Quadratic Programming
⇒ Quadratic programming problem (QPP) is special case of non-linear
programming problem (NLPP).
⇒ Objective function is quadratic in nature.
⇒ All constraints (in-equality and equality) are linear in nature.
⇒ General mathematical formulation for QPP
min{f (x)} =xT
Qx + cT
x
s.t Ax ≤ b
x ≥ 0
⇒ Q = [qij ]n×n → Symmetric positive semi-definite matrix.
⇒ c, x ∈ Rn → Vector of size n × 1 (Contain real number).
⇒ A = [aij ]m×n → Matrix of size m × n
Dr. Varun Kumar Lecture 2 3 / 12
Example:
⇒ Let objective function f (x) = 3x2
1 + 4x2
2 + 2x1x2 − 2x1 − 3x2
⇒ Constraint:
3x1 + 2x2 ≤ 6
x1 + x2 ≤ 2
x1, x2 ≥ 0
⇒ Problem representation
min{f (x)} = [x1 x2]

3 1
1 4
 
x1
x2

+ [−2 − 3]

x1
x2


3 2
1 1
 
x1
x2

≤

6
2

⇒ x =

x1
x2

, Q =

3 1
1 4

, b =

6
2

, A =

3 2
1 1

, c =

−2
−3

Dr. Varun Kumar Lecture 2 4 / 12
Solution by the graphical method:
Positive semi-definite and symmetric
⇒ Q =

3 1
1 4

→ [qij ]2×2, if qij = qji → Symmetric
⇒ If det|Q| ≥ 0 → Positive semi-definite
Solution by graphical method:
⇒ Let objective function f (x) = (x1 − 2)2 + (x2 − 1)2
⇒ Constraint:
x1 + x2 ≤ 2
x1, x2 ≥ 0
Dr. Varun Kumar Lecture 2 5 / 12
Karush Kuhn Tucker KKT condition:
QPP should be written in this form
⇒ min{f (x)} = xT
Qx + cT
x
⇒ Ax ≤ b (1)
⇒ −x ≤ 0 (2)
Let KKT multiplier associated with the constraints (1) and (2) be u ∈ Rm
and v ∈ Rn, respectively. Hence,
cT
+ 2xT
Q + uT
A − vT
= 0
uT
(Ax − b) − vT
x = 0
Ax − b = 0
x ≥ 0, u ≥ 0, v ≥ 0
Note: Total number of KKT multiplier for solving QPP is m + n.
Dr. Varun Kumar Lecture 2 6 / 12
General KKT condition
General KKT condition
⇒ ∇f (x) +
PN
i=1 λi ∇gi (x) = 0
⇒ λi gi (x) = 0 ∀ i
⇒ gi (x) ≤ 0
⇒ λi ≥ 0
Here,
∇f (x) =
∂f (x)
∂x1
,
∂f (x)
∂x2
, ......,
∂f (x)
∂xn

Example
⇒ f (x) = 3x2
1 + 2x2
2 + x1x2 − 4x1 − 2x2
s.t x1 + 2x2 ≤ 6 → u
−x1 ≤ 0 → v1
−x2 ≤ 0 → v2
Dr. Varun Kumar Lecture 2 7 / 12
Continued–
As per the question f (x) = 3x2
1 + 2x2
2 + x1x2 − 4x1 − 2x2, s.t
x1 + 2x2 ≤ 6 → u, −x1 ≤ 0 → v1, −x2 ≤ 0 → v2. Hence,
Applying KKT condition:
6x1 + x2 − 4, 4x2 + x1 − 2

+ u 1, 2

+ v1(−1, 0) + v2(0, −1) = (0, 0)
6x1 + x2 − 4 + u − v1 = 0
x1 + 4x2 − 2 + 2u − v2 = 0
General KKT condition for QPP
2xT
Q + cT
+ uT
A + vT
(−I) = 0
uT
(Ax − b) − vT
x = 0
Ax − b ≤ 0
x ≥ 0, u ≥ 0, v ≥ 0
Dr. Varun Kumar Lecture 2 8 / 12
Continued–
Taking transpose operation in 1st KKT expression
2Qx + c + AT
u + v(−I) = 0
uT
(Ax − b) − vT
x = 0
Ax − b + s = 0
x ≥ 0, u ≥ 0, v ≥ 0
Here, 0s0 is called as the slack variable. ⇒ uT (−s) − vT x = 0
⇒ uT s = 0 ⇒ u1s1 + u2s2 + ... + umsm = 0
⇒ ; vT x = 0 ⇒ v1x1 + v2x2 + ..... + vnxn = 0
⇒ ui si = 0 ∀ i = 1, 2, ...., m and vj xj = 0 ∀ j = 1, 2, ...n




2Qx + c + AT u − v = 0
Ax + s = b
ui si = 0 ∀ i = 1, 2, ...., m
vj xj = 0 ∀ j = 1, 2, ...n




Dr. Varun Kumar Lecture 2 9 / 12
Continued–
The matrix form of KKT conditions are

2Q AT In 0
A 0 0 In





x
u
v
s





−c
b

Theorem
Let Q be a +ve semi-definite matrix of order n. Then for any x, y ∈ Rn
2xT
Qy ≤ xT
Qx + yT
Qy
Problem: Show that f (x) = xT Qx + cT x, x ∈ Rn (in QPP) is a convex
function, if Q is a semi-definite symmetric matrix.
Dr. Varun Kumar Lecture 2 10 / 12
Continued–
Condition for +ve semi-definite matrix
zT
Qz ≥ 0 ∀ z ∈ Rn
⇒ (x − y)T Q(x − y) ≥ 0 ∀ x, y ∈ Rn
⇒ xT Qx + yT Qy − yT Qx − xT Qy ≥ 0
⇒ yT Qx + xT Qy ≤ xT Qx + yT Qy
⇒ 2xT Qy ≤ xT Qx + yT Qy
Dr. Varun Kumar Lecture 2 11 / 12
Dr. Varun Kumar Lecture 2 12 / 12

More Related Content

PDF
Numerical analysis kuhn tucker eqn
PDF
Jacobi and gauss-seidel
PDF
Lesson 17: The Method of Lagrange Multipliers
PPT
Null space, Rank and nullity theorem
PDF
Mathematical Modeling for Practical Problems
PPTX
Systems Of Differential Equations
PPTX
Unit 5: All
PDF
Stability of Differential Equations
Numerical analysis kuhn tucker eqn
Jacobi and gauss-seidel
Lesson 17: The Method of Lagrange Multipliers
Null space, Rank and nullity theorem
Mathematical Modeling for Practical Problems
Systems Of Differential Equations
Unit 5: All
Stability of Differential Equations

What's hot (20)

PPTX
presentation on Euler and Modified Euler method ,and Fitting of curve
PPTX
Probability Density Function (PDF)
PPTX
Lu Decomposition
PPTX
Quadratic Programming : KKT conditions with inequality constraints
PPT
Lu decomposition
PDF
Fixed point iteration
DOCX
Numerical Integration Project Report
PPTX
Innerproductspaces 151013072051-lva1-app6892 (1)
PPTX
Presentation on Numerical Integration
PPTX
Jacobi method
PPTX
vector space and subspace
PDF
Interpolation with Finite differences
PPTX
Vector space
PPT
Z transfrm ppt
PPTX
Runge kutta
PPTX
Euler and improved euler method
PPTX
Laplace transform
PPTX
Mathematical Optimisation - Fundamentals and Applications
PDF
Stochastic Processes - part 1
PDF
Lesson02 Vectors And Matrices Slides
presentation on Euler and Modified Euler method ,and Fitting of curve
Probability Density Function (PDF)
Lu Decomposition
Quadratic Programming : KKT conditions with inequality constraints
Lu decomposition
Fixed point iteration
Numerical Integration Project Report
Innerproductspaces 151013072051-lva1-app6892 (1)
Presentation on Numerical Integration
Jacobi method
vector space and subspace
Interpolation with Finite differences
Vector space
Z transfrm ppt
Runge kutta
Euler and improved euler method
Laplace transform
Mathematical Optimisation - Fundamentals and Applications
Stochastic Processes - part 1
Lesson02 Vectors And Matrices Slides
Ad

Similar to Quadratic programming (Tool of optimization) (20)

PPTX
PPT
Neural network P algorithms powerpoint presentation
PPT
Neural network P algorithms powerpoint presentation
PDF
Paper Study: Melding the data decision pipeline
PDF
A method for solving quadratic programming problems having linearly factoriz...
PDF
Optimum Engineering Design - Day 2b. Classical Optimization methods
PDF
Chapter 05
PDF
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
PDF
Fractional programming (A tool for optimization)
PDF
5 Kuhn-Tucker Conditions explained for optimization
PDF
Paper Study: OptNet: Differentiable Optimization as a Layer in Neural Networks
PPTX
Kalman filter for object tracking
PDF
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
PPTX
A New SR1 Formula for Solving Nonlinear Optimization.pptx
PDF
Sawinder Pal Kaur PhD Thesis
PDF
Least squares support Vector Machine Classifier
PDF
Lecture 2: linear SVM in the dual
PDF
Lecture 2: linear SVM in the Dual
PDF
Lecture6 svdd
Neural network P algorithms powerpoint presentation
Neural network P algorithms powerpoint presentation
Paper Study: Melding the data decision pipeline
A method for solving quadratic programming problems having linearly factoriz...
Optimum Engineering Design - Day 2b. Classical Optimization methods
Chapter 05
ObjectiveQuestionsonEngineeringMathematicsForGATE2022.pdf
Fractional programming (A tool for optimization)
5 Kuhn-Tucker Conditions explained for optimization
Paper Study: OptNet: Differentiable Optimization as a Layer in Neural Networks
Kalman filter for object tracking
Optimum Solution of Quadratic Programming Problem: By Wolfe’s Modified Simple...
A New SR1 Formula for Solving Nonlinear Optimization.pptx
Sawinder Pal Kaur PhD Thesis
Least squares support Vector Machine Classifier
Lecture 2: linear SVM in the dual
Lecture 2: linear SVM in the Dual
Lecture6 svdd
Ad

More from VARUN KUMAR (20)

PDF
Distributed rc Model
PDF
Electrical Wire Model
PDF
Interconnect Parameter in Digital VLSI Design
PDF
Introduction to Digital VLSI Design
PDF
Challenges of Massive MIMO System
PDF
E-democracy or Digital Democracy
PDF
Ethics of Parasitic Computing
PDF
Action Lines of Geneva Plan of Action
PDF
Geneva Plan of Action
PDF
Fair Use in the Electronic Age
PDF
Software as a Property
PDF
Orthogonal Polynomial
PDF
Patent Protection
PDF
Copyright Vs Patent and Trade Secrecy Law
PDF
Property Right and Software
PDF
Investigating Data Trials
PDF
Gaussian Numerical Integration
PDF
Censorship and Controversy
PDF
Romberg's Integration
PDF
Introduction to Censorship
Distributed rc Model
Electrical Wire Model
Interconnect Parameter in Digital VLSI Design
Introduction to Digital VLSI Design
Challenges of Massive MIMO System
E-democracy or Digital Democracy
Ethics of Parasitic Computing
Action Lines of Geneva Plan of Action
Geneva Plan of Action
Fair Use in the Electronic Age
Software as a Property
Orthogonal Polynomial
Patent Protection
Copyright Vs Patent and Trade Secrecy Law
Property Right and Software
Investigating Data Trials
Gaussian Numerical Integration
Censorship and Controversy
Romberg's Integration
Introduction to Censorship

Recently uploaded (20)

PDF
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PPTX
Geodesy 1.pptx...............................................
PPTX
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
PDF
Automation-in-Manufacturing-Chapter-Introduction.pdf
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
PDF
composite construction of structures.pdf
PPTX
web development for engineering and engineering
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PDF
R24 SURVEYING LAB MANUAL for civil enggi
PPT
Mechanical Engineering MATERIALS Selection
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PDF
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
PPTX
OOP with Java - Java Introduction (Basics)
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
bas. eng. economics group 4 presentation 1.pptx
PPTX
Construction Project Organization Group 2.pptx
BMEC211 - INTRODUCTION TO MECHATRONICS-1.pdf
Model Code of Practice - Construction Work - 21102022 .pdf
UNIT-1 - COAL BASED THERMAL POWER PLANTS
Geodesy 1.pptx...............................................
IOT PPTs Week 10 Lecture Material.pptx of NPTEL Smart Cities contd
Automation-in-Manufacturing-Chapter-Introduction.pdf
Operating System & Kernel Study Guide-1 - converted.pdf
composite construction of structures.pdf
web development for engineering and engineering
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
R24 SURVEYING LAB MANUAL for civil enggi
Mechanical Engineering MATERIALS Selection
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
OOP with Java - Java Introduction (Basics)
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
UNIT 4 Total Quality Management .pptx
bas. eng. economics group 4 presentation 1.pptx
Construction Project Organization Group 2.pptx

Quadratic programming (Tool of optimization)

  • 1. Quadratic Programming Dr. Varun Kumar Dr. Varun Kumar Lecture 2 1 / 12
  • 2. Outlines 1 Introduction to Quadratic Programming 2 Problem and Solution by Graphical Method 3 Karush Kuhn Tucker (KKT) Condition Dr. Varun Kumar Lecture 2 2 / 12
  • 3. Introduction to Quadratic Programming ⇒ Quadratic programming problem (QPP) is special case of non-linear programming problem (NLPP). ⇒ Objective function is quadratic in nature. ⇒ All constraints (in-equality and equality) are linear in nature. ⇒ General mathematical formulation for QPP min{f (x)} =xT Qx + cT x s.t Ax ≤ b x ≥ 0 ⇒ Q = [qij ]n×n → Symmetric positive semi-definite matrix. ⇒ c, x ∈ Rn → Vector of size n × 1 (Contain real number). ⇒ A = [aij ]m×n → Matrix of size m × n Dr. Varun Kumar Lecture 2 3 / 12
  • 4. Example: ⇒ Let objective function f (x) = 3x2 1 + 4x2 2 + 2x1x2 − 2x1 − 3x2 ⇒ Constraint: 3x1 + 2x2 ≤ 6 x1 + x2 ≤ 2 x1, x2 ≥ 0 ⇒ Problem representation min{f (x)} = [x1 x2] 3 1 1 4 x1 x2 + [−2 − 3] x1 x2 3 2 1 1 x1 x2 ≤ 6 2 ⇒ x = x1 x2 , Q = 3 1 1 4 , b = 6 2 , A = 3 2 1 1 , c = −2 −3 Dr. Varun Kumar Lecture 2 4 / 12
  • 5. Solution by the graphical method: Positive semi-definite and symmetric ⇒ Q = 3 1 1 4 → [qij ]2×2, if qij = qji → Symmetric ⇒ If det|Q| ≥ 0 → Positive semi-definite Solution by graphical method: ⇒ Let objective function f (x) = (x1 − 2)2 + (x2 − 1)2 ⇒ Constraint: x1 + x2 ≤ 2 x1, x2 ≥ 0 Dr. Varun Kumar Lecture 2 5 / 12
  • 6. Karush Kuhn Tucker KKT condition: QPP should be written in this form ⇒ min{f (x)} = xT Qx + cT x ⇒ Ax ≤ b (1) ⇒ −x ≤ 0 (2) Let KKT multiplier associated with the constraints (1) and (2) be u ∈ Rm and v ∈ Rn, respectively. Hence, cT + 2xT Q + uT A − vT = 0 uT (Ax − b) − vT x = 0 Ax − b = 0 x ≥ 0, u ≥ 0, v ≥ 0 Note: Total number of KKT multiplier for solving QPP is m + n. Dr. Varun Kumar Lecture 2 6 / 12
  • 7. General KKT condition General KKT condition ⇒ ∇f (x) + PN i=1 λi ∇gi (x) = 0 ⇒ λi gi (x) = 0 ∀ i ⇒ gi (x) ≤ 0 ⇒ λi ≥ 0 Here, ∇f (x) = ∂f (x) ∂x1 , ∂f (x) ∂x2 , ......, ∂f (x) ∂xn Example ⇒ f (x) = 3x2 1 + 2x2 2 + x1x2 − 4x1 − 2x2 s.t x1 + 2x2 ≤ 6 → u −x1 ≤ 0 → v1 −x2 ≤ 0 → v2 Dr. Varun Kumar Lecture 2 7 / 12
  • 8. Continued– As per the question f (x) = 3x2 1 + 2x2 2 + x1x2 − 4x1 − 2x2, s.t x1 + 2x2 ≤ 6 → u, −x1 ≤ 0 → v1, −x2 ≤ 0 → v2. Hence, Applying KKT condition: 6x1 + x2 − 4, 4x2 + x1 − 2 + u 1, 2 + v1(−1, 0) + v2(0, −1) = (0, 0) 6x1 + x2 − 4 + u − v1 = 0 x1 + 4x2 − 2 + 2u − v2 = 0 General KKT condition for QPP 2xT Q + cT + uT A + vT (−I) = 0 uT (Ax − b) − vT x = 0 Ax − b ≤ 0 x ≥ 0, u ≥ 0, v ≥ 0 Dr. Varun Kumar Lecture 2 8 / 12
  • 9. Continued– Taking transpose operation in 1st KKT expression 2Qx + c + AT u + v(−I) = 0 uT (Ax − b) − vT x = 0 Ax − b + s = 0 x ≥ 0, u ≥ 0, v ≥ 0 Here, 0s0 is called as the slack variable. ⇒ uT (−s) − vT x = 0 ⇒ uT s = 0 ⇒ u1s1 + u2s2 + ... + umsm = 0 ⇒ ; vT x = 0 ⇒ v1x1 + v2x2 + ..... + vnxn = 0 ⇒ ui si = 0 ∀ i = 1, 2, ...., m and vj xj = 0 ∀ j = 1, 2, ...n     2Qx + c + AT u − v = 0 Ax + s = b ui si = 0 ∀ i = 1, 2, ...., m vj xj = 0 ∀ j = 1, 2, ...n     Dr. Varun Kumar Lecture 2 9 / 12
  • 10. Continued– The matrix form of KKT conditions are 2Q AT In 0 A 0 0 In     x u v s     −c b Theorem Let Q be a +ve semi-definite matrix of order n. Then for any x, y ∈ Rn 2xT Qy ≤ xT Qx + yT Qy Problem: Show that f (x) = xT Qx + cT x, x ∈ Rn (in QPP) is a convex function, if Q is a semi-definite symmetric matrix. Dr. Varun Kumar Lecture 2 10 / 12
  • 11. Continued– Condition for +ve semi-definite matrix zT Qz ≥ 0 ∀ z ∈ Rn ⇒ (x − y)T Q(x − y) ≥ 0 ∀ x, y ∈ Rn ⇒ xT Qx + yT Qy − yT Qx − xT Qy ≥ 0 ⇒ yT Qx + xT Qy ≤ xT Qx + yT Qy ⇒ 2xT Qy ≤ xT Qx + yT Qy Dr. Varun Kumar Lecture 2 11 / 12
  • 12. Dr. Varun Kumar Lecture 2 12 / 12