Constraint Optimisation
f(x,y) = 5 - (x-2)^2 -2(y-1)^2; Constrain: x + 4y -3 = 0
g(x,y) = f(x,y) + K*(x + 4y -3) where K is the lagrangian Multiplier
dg/dx = -2x + 4 + K = 0 (1)
dg/dy = -4y+4+ 4K = 0 (2)
dg/dK = x + 4y -3 = 0 (3)
Solving (1) & (2), we get
y-2x + 3 = 0 (4)
Solving (3) & (4), we get,
y = -1; x = 7.
Thus for the above values of x and y, we get the optimised value for the above constrained problem