0% found this document useful (0 votes)
46 views

Quiz1 Py

This document outlines the details of a quiz for a process optimization course at IIT Madras. It contains 4 questions worth a total of 15 marks. For question 1, students are asked to rewrite a function in standard form, find its minimum, and determine directions of decrease and no change. Question 2 involves sketching the feasible space and objective function contours for an optimization problem. Question 3 asks students to formulate determining the sum of the largest elements of a vector as an optimization problem. Question 4 asks students to show that any two non-collinear eigenvectors of a real symmetric matrix are conjugate with respect to that matrix. The quiz allows open notes but requires answers be written concisely and in the students' own handwriting

Uploaded by

Nohan Joemon
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
46 views

Quiz1 Py

This document outlines the details of a quiz for a process optimization course at IIT Madras. It contains 4 questions worth a total of 15 marks. For question 1, students are asked to rewrite a function in standard form, find its minimum, and determine directions of decrease and no change. Question 2 involves sketching the feasible space and objective function contours for an optimization problem. Question 3 asks students to formulate determining the sum of the largest elements of a vector as an optimization problem. Question 4 asks students to show that any two non-collinear eigenvectors of a real symmetric matrix are conjugate with respect to that matrix. The quiz allows open notes but requires answers be written concisely and in the students' own handwriting

Uploaded by

Nohan Joemon
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Monday, 10 Sep, 8 AM- 8.50 AM. Total marks: 15.


• Open notes. All notes in your own handwriting. No photocopies, print-outs, scanned, printed
items of any kind.
• Be concise.
• xT denotes transpose of x.

.
1. (Minima, 5 marks.) Given the following function:

f (x1 , x2 ) = x21 + x22 + x1 x2 − 3x1 − 3x2 + 2012

(a) Rewrite it in the form


1
f (x) = c0 + aT x + xT Hx,
2
where x, a, H are of appropriate sizes.
(b) Determine the minimum and verify the first and second order conditions of optimality.
(c) Starting from the initial point [2, 1]T , find the direction in which f decreases most (locally)
and a direction in which there is no change in f (locally).

2. (Feasible space, 3 marks.) Consider the following optimization problem:



 2x + 3y ≤ 6,



2 2
 y ≤ 2,
min f (x, y) = (x − 2) + (y − 3.5) , subject to


 x ≥ 0,

 y ≥ 0.

Sketch the feasible space and the contours of the objective function. Interpret the problem
geometrically.

3. (Formulation, 4 marks.) Given an n dimensional real vector v = [v1 , v2 , . . . , vn ]T , define


the function σk (v) to be the sum of the k largest elements of v, where k is an integer not greater
than n. Obviously, given a vector v, it is possible to determine σk (v) by sorting and inspection.
Show that it is also possible to determine it by solving an optimization problem:
n
( Pn
i=1 ui = k,
X
max ui vi , subject to
i=1
0 ≤ ui ≤ 1 i = 1, . . . , n.

4. (Conjugate directions, 3 marks.) Given a real, symmetric matrix H, two non-zero vectors
v1 and v2 are said to be H conjugate v1T Hv2 = 0. Show that any two non-collinear eigenvectors
of H are H conjugate.

THE END
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Thursday, 12 Sep, 8 AM- 8.50 AM. Total marks: 15.


• Closed book, closed notes.
• xT denotes transpose of x.
• Be concise. Do not rewrite the questions.

.
1. (Short questions. No partial marking, 0.5 mark each) Which of the following are true,
false or undecidable. Do not rewrite the questions. Simply write the answers. The optimization
is unconstrained and you may assume that the function is sufficiently smooth.

(a) A concave function can have a global minimum.


(b) All convex functions have a global minimum.

2. (Quadratic functions) Given the following function:

f (x1 , x2 ) = 2013 − 2x1 − 2x2 + 1.25x21 − 1.5x1 x2 + 1.25x22

(a) (0.5 mark) Rewrite it in the form


1
f (x) = c + aT x + xT Hx,
2
where x, a, H, c are of appropriate sizes.
(b) (0.5 mark) The eigenvectors of H are known to be:
   
−1 1
,
−1 −1

Determine the corresponding eigenvalues.


(c) (0.5 mark) Is the function convex, concave, neither or both?
(d) (2 marks) Determine any and all stationary points and their character by verifying the
first and second order conditions.
(e) (2 marks) Sketch the contours of the objective function. Pay careful attention to sta-
tionary points (if any), orientation and aspect ratios of the contours.
(f) (0.5 mark) Starting from the initial point x0 = [2, 1]T , find a direction p in which f
decreases most (locally).
(g) (0.5 mark) Sketch how the function f behaves as you go along p.
(h) (1.5 marks) How far can you go along this direction p till the function starts to increase
again?
2

3. (Coin changers, 4 marks) Recall the coin changing problem: how can a given amount of
money W be made with the least number of coins of given denominations? Given an infinite
supply of 50 paise, Re. 1, Rs. 2 and Rs. 5 coins, formulate the coin changing problem as an
optimization problem with a twist: If a Re. 1 coin is selected, at least one Rs.2 coin should
also be selected. NB! The formulation may contain integer variables, algebraic inequalities,
equalities, but no logical conditions or statements!

4. (FONC and SONC, 2 marks) Given the following function:


  
1 1 2 x1
f (x) = [x1 , x2 ] − x31 ,
2 2 4 x2

verify that [0, 0]T satisfies the first and second order conditions of optimality. However, is this a
minimum? Explain why.

THE END
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


Department of Chemical Engineering

CH 517: Process optimization


Quiz 1

Thursday, February 19, 2009 Duration: 8:00-8:50 AM

• Open book and open notes. However, all notes should be in your own handwriting.
• Read each question carefully and answer ALL questions.
• All answers should be written legibly in the answer book. Do not rewrite the questions.
• 0 denotes transpose.

Total Marks: 30

[18 + 4 + 4 +4 = 30 Marks]

1. Given the following function:


f (x) = x21 + x1 x2 + x22 + 3x1 + 300
(a) Determine if the function f is concave, convex, neither or both.
(b) Determine all stationary points and their character.
(c) Starting from the initial point [0, 0]0 , if the steepest descent method is used to minimize f
determine the direction of search.
(d) Find analytically, the optimum step length along the direction obtained in part(c) which
minimizes the objective function.
(e) Let H be the Hessian of the objective function. Determine a direction that is H conjugate
with respect to the direction chosen in part (c).
(f) Determine the eigenvectors of H and show that they form a set of H conjugate directions.

2. Given a quadratic function f (x) = 12 x0 Ax − b0 x where x is a n × 1 dimensional vector, b is a


n × 1 vector, A is a symmetric positive definite matrix of size n × n, show that the eigenvectors
form a set of A conjugate directions. Why don’t we use these directions in a conjugate gradient
type algorithm?

3. Does the following function have a global minimum or maximum? Explain with reasons.
f (x) = 1 + 2x + 3x2 + 4x3 + . . . + 2010x2009

4. Let f (x) = 21 x0 Qx + b0 x, where b, x are vectors of appropriate dimensions and Q is a symmetric


positive semi-definite matrix of appropriate dimension. Show that f has a global minimum if
and only if b is in the column space of Q. Further, show that any vector x satisfying Qx = −b
is a global minimum.

THE END
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Monday, 10 Sep, 8 AM- 8.50 AM. Total marks: 15.


• Open notes. All notes in your own handwriting. No photocopies, print-outs, scanned, printed
items of any kind.
• Be concise.
• xT denotes transpose of x.

.
1. (Minima, 5 marks.) Given the following function:

f (x1 , x2 ) = x21 + x22 + x1 x2 − 3x1 − 3x2 + 2012

(a) Rewrite it in the form


1
f (x) = c0 + aT x + xT Hx,
2
where x, a, H are of appropriate sizes.
(b) Determine the minimum and verify the first and second order conditions of optimality.
(c) Starting from the initial point [2, 1]T , find the direction in which f decreases most (locally)
and a direction in which there is no change in f (locally).

2. (Feasible space, 3 marks.) Consider the following optimization problem:



 2x + 3y ≤ 6,



2 2
 y ≤ 2,
min f (x, y) = (x − 2) + (y − 3.5) , subject to


 x ≥ 0,

 y ≥ 0.

Sketch the feasible space and the contours of the objective function. Interpret the problem
geometrically.

3. (Formulation, 4 marks.) Given an n dimensional real vector v = [v1 , v2 , . . . , vn ]T , define


the function σk (v) to be the sum of the k largest elements of v, where k is an integer not greater
than n. Obviously, given a vector v, it is possible to determine σk (v) by sorting and inspection.
Show that it is also possible to determine it by solving an optimization problem:
n
( Pn
i=1 ui = k,
X
max ui vi , subject to
i=1
0 ≤ ui ≤ 1 i = 1, . . . , n.

4. (Conjugate directions, 3 marks.) Given a real, symmetric matrix H, two non-zero vectors
v1 and v2 are said to be H conjugate v1T Hv2 = 0. Show that any two non-collinear eigenvectors
of H are H conjugate.

THE END
CH 5170 Process Optimization
Quiz 1

• Monday, 12 Sep, 8 AM- 8.50 AM. Total marks: 30.


• One handwritten A4 sheet (written on both sides) allowed. It should be in your own handwriting.
• All answers should be written legibly in the answer book. Do not rewrite the questions.
• Be concise.

1. (Short questions. No partial marking, 4 marks) Which of the following are true, false or undecid-
able. The optimization is unconstrained and you may assume that the function is sufficiently
smooth.

(a) At a stationary point, the gradient is zero.


(b) At a minimum, the Hessian is always positive definite.
(c) A convex function has a global minimum.
(d) If the function is convex, it is sufficient to set the gradient to zero to determine the minima.

2. (Stationary points, 8 marks.) Given the following function:

f (x) = 4x21 + x22 − 2x1 x2

(a) Determine if the function f is concave, convex, neither or both.


(b) Determine all stationary points and their character.
(c) Starting from the initial point [1, 1]0 , find the direction in which f decreases most.
(d) Suppose you go along the direction determined in part(c), how far can you go before f
starts to increase.

3. (Formulation 8 marks.)We are planning to buy sensors that can detect the presence of poi-
sonous gases G1 , G2 , G3 , G4 , G5 , G6 , G7 , G8 in a room. However, not every sensor is affected
by any given gas, e.g., S1 is sensitive only to G1 , G2 , G3 and G4 and hence can only detect
any of them. Following is a list of sensors and the gases that they can detect and their cost.

Table 1: Sensors
Sensor Detectability Cost (in Rs.)
S1 G1 , G2 , G3 , G4 10000
S2 G1 , G5 10000
S3 G2 , G6 50000
S4 G3 , G7 30000
S5 G4 , G8 20000

We will connect each sensor to a bulb that is fit outside the room. Thus, there are as many
bulbs outside as there are sensors inside. If any of the bulbs goes off, we can infer that
some poisonous gas is present and we say that a gas has been detected. IF we can exactly
determine which gas is present, we say that a gas has been distinguished.
(a) We want to buy a set of sensors that can detect any of the gases G1 , . . . , G8 and has
minimum cost. Formulate this problem. Do not solve!
(b) What kind of an optimization problem is this?
(c) Assume that not more than one poisonous gas can be present in the room. Formulate
an optimization problem to minimize the cost of buying sensors that is able to distinguish
all gases. Again, do not SOLVE!

4. (Feasible space, 5 marks) Consider the following optimization problem:

min f (x, y) = (x − 1)2 + (y − 2.5)2 , subjec to

x − 2y + 2 ≥ 0,
−x − 2y + 6 ≥ 0
−x + 2y + 2 ≥ 0
x ≥ 0,
y ≥ 0.

Sketch the contours of the objective function and the feasible space. Interpret the problem
geometrically.

5. (Interpreting a contour plot, 5 marks.) Refer to Fig.1. It is a partial contour plot of a real valued
function of two variables x1 and x2 . The numbers along the curves represent the function
values. Based on the given plots, how many stationary points do you think are possible?
What is the nature and approximate location of each stationary point?

6
3.5
8
2.
4.5

5
2

4.5
2.8 2
3.5
1 .5

4
1 .5

3
2 .8

5
3 .5

4.
2.8 3.5 4 .5 2

x2 2 1.5 2 3.5
2.8
5
4.5

4.

2.8
1.5 2
3.5
2.8

1 3. 5
-0.4

1.5 2 4.5
0
2.8
4 .5 3.5

-1
-2 -1.5 -1 -0.5 0 0.5 1 1.5 2 2.5 3

x1

Figure 1: Contour plot for question


1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Monday, 8 Sep, 8 AM- 8.50 AM. Total marks: 15. Closed book, closed notes.
• xT denotes transpose of x.
• Be concise. Do not reproduce the questions.

.
1. (Quadratic functions) Given the following function:
[ ] [ ]
1 −2 3 −1
f (x) = 2014 + aT x + xT Hx, with a = , H=
2 −2 −1 3
[ ]
−1
(a) (1 mark) One of the eigenvectors of H is known to be: . Determine the other
−1
eigenvector and the corresponding eigenvalues with minimal calculations.
(b) (0.5 mark) Hence, show that the function is convex.
(c) (2 marks) Determine any and all possible minima. Verify the first and second order
conditions of optimality.
(d) (0.5 mark) Is (Are) the minimum (minima) global? Explain.
(e) (2 marks) Sketch the contours of the objective function. Pay careful attention to minima
(if any), orientation and aspect ratios of the contours.
(f) ( 0.5 mark) Starting from any point x0 , show that
1
f (x0 + αp) = f (x0 ) + αpT ∇f (x0 ) + α2 pT Hp
2
(g) (1 mark) Hence, show that for x0 = [0, 0]T , p = −∇f (x0 ) is a descent direction, i.e, if
you go along p from x0 , f will decrease initially.
(h) (2.5 marks) Will f continue to decrease indefinitely? If not, how far can you go (or
equivalently upto what point can you go) such that f continues to decrease?

2. (FONC and SONC, 2 marks) Given the following function:


[ ][ ]
1 1 3 x1
f (x) = [x1 , x2 ] − (x2 )3 ,
2 3 9 x2
verify that [0, 0]T satisfies the first and second order conditions of optimality. However, is this a
minimum? Explain why.

3. (Coin changers, 3 marks) Recall the coin changing problem: how can a given amount of
money W be made with the least number of coins of given denominations? Given an infinite
supply of 50 paise, Re. 1, Rs. 2 and Rs. 5 coins, formulate the coin changing problem as an
optimization problem with a twist: the final collection may contain either coins of Re. 1 or coins
of Rs.2, but not both. There is no restriction on the other denominations. NB! The formulation
may contain integer variables, algebraic inequalities, equalities, but no logical conditions or
statements!

THE END
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Thursday, 10 Sep, 8 AM- 8.50 AM. Total marks: 20. Closed book, closed notes.
• xT denotes transpose of x.
• Be concise. Do not reproduce the questions.

.
1. (Quadratic functions) In each subquestion, there are several choices provided. It is possible that
none, one or more than one may be correct. Answer accordingly with justification (but be concise!)
Most require minimal calculations. Given the following function:
" # " #
T 1 T −8 6 2
f (x) = 2015 + c x + x Hx, with c = , H=
2 −11 2 9

(a) (1.5
" marks)
# Which
" # of the" following
# "are #eigenvectors?
2 1 4 1
a) , b) , c) , d)
−1 1 −2 2
e) none of the above
(b) (1 mark) The eigenvalues are
a) 5, b) 10, c) − 5, d) − 10, e) none of these.
(c) (1 mark) The stationary point [1, 1]T is a
a) local maximum, b) local minimum, c) global minimum d) global maximum, e) none of the
above.
(d) (1 mark) The contours of the objective function are
a) ellipses, b) hyperbolae, c) parabolae, d) straight lines, e) None of these.
T
(e) (2 "marks)# At the
" point
# [1, " −1] #, which
" of the
# following vectors are descent directions:
−4 4 6 −6
a) , b) , c) , d)
−18 18 17 −17
e) none of the above
(f) (2 marks) Which of the following vectors are tangential to the contours of the objective
function
" passing
# " through
# the " point
# [1, "−1]T#:
9 −9 −9 9
a) , b) , c) , d)
−2 −2 2 2
e) none of the above

2. (General descent directions, 2.5 marks) Given an arbitrary function f (x) and a positive
definite matrix B, show that −B∇f (x) is a (locally) descent direction at x.

3. (Water distribution network, 9 marks) Consider the network shown in Figure 1. The water
distribution network consists of a source node 0 and three demand nodes 1,2 and 3. Node 0 and
2

II
2
I
III
0 1
0

Figure 1

Figure 1: Water distribution network

node 1 are connected by link I. Likewise, link II connects nodes 1 and 2. Link III connects nodes
1 and 3. The diameters of the pipes are D1 , D2 , D3 respectively (in mm). Flow is by gravity and it is
possible to achieve a head of 100 m at source node 0. Minimum head values at nodes 1, 2 and 3 are
80, 85 and 80 m respectively. Lengths of links I, II and III are 300, 500 and 400 m respectively.
Flow rates in links I, II and III are 9,3 and 2 m3 /min respectively. Commercially available pipes
are available only in certain diameters, e.g., 80 mm, 100mm, 125 mm etc. Table 1 contains a list
of the commercially available pipes and their unit costs. You may use the following expression for

Table 1: Commercially available pipe diameters


Sr no Pipe dia (mm) Unit costs (Rs./m)
1 200 1431
2 250 1924
3 300 2451
4 350 3008

estimating head loss in a pipe:


LQ1.85
HA − HB = ∆H = 4.457 × 108 , (1)
D4.87
where Q is the flow rate in m3 /min, HA , HB , ∆H are the heads in meters, L is the length of pipe in
meter, D is the inner diameter of the pipe in mm. You have to formulate an optimization problem for
design of a pipe network with least cost while satisfying the minimum pressure constraints at nodes
1, 2 and 3 under different conditions/constraints using continuous and integer variables, algebraic
inequalities, equalities, but no logical conditions or statements.

(a) (3 marks) A link can have a pipe of a single diameter that appears in Table 1.
(b) (3 marks) A link can have upto two pipes of commercially available sizes.
(c) (3 marks) A link can have upto two pipes of commercially available sizes, but they have to be
adjacent diameters, i.e., if you choose a pipe of diameter 250 mm for a link, you may choose
another pipe of diameter 200 or 300 mm, but not 350 mm. If you choose 200 mm, you may
choose 250 mm and so on.
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• Friday, 9 Sep, 8 AM- 8.50 AM. Total marks: 15. Closed book, closed notes.
• xT denotes transpose of x.
• Be concise. Do not reproduce the questions. In case of any doubts, state any assumptions that
you need to make and proceed.

.
1. (Quadratic functions) Given the following function:
" # " #
1 −8 6 2
f (x) = 2016 + a x + xT Hx, with a =
T
, H=
2 −11 2 9
#"
1
(a) (2 marks) One of the eigenvectors of H is known to be: . Determine the other
2
eigenvector and the corresponding eigenvalues with minimal calculations.
(b) (3 marks) Determine stationary point(s) x∗ . Classify the stationary point(s) as precisely
as you can.
(c) (2 marks) Sketch the contours of the objective function. Pay careful attention to sta-
tionary point(s), orientation, shape and sizes of the contours.
(d) (0.5 mark) Show that
1
f (x) − f (x∗ ) = (x − x∗ )T H(x − x∗ )
2

(e) ( 0.5 mark) Starting from any point x0 , show that


1
f (x0 + αp) = f (x0 ) + αpT ∇f (x0 ) + α2 pT Hp
2

(f) (1 mark) Hence, show that for x0 = [0, 0]T , p = −∇f (x0 ) is a descent direction, i.e, if
you go along p from x0 , f will decrease initially.
(g) (3 marks) If p = −B∇f (x0 ), where B is a square symmetric matrix of size 2 × 2, does
there exist B such that if you start from x0 and go along p, you will reach x∗ .

2. (Classification of stationary points, 2 marks) Given a function f (x), where x ∈ Rn ,


there exists a stationary point x∗ and the Hessian is positive semi-definite at x∗ . What is the
precise nature of the stationary point when f is
a) linear b) quadratic c) general convex and d) non-convex, non-quadratic.

3. (Global Minimum, 1 mark) Does the following function have a global miniminum. Explain.

f (x) = 1 + 2x + 3x2 + 4x3 + . . . + 2016x2015

THE END
1

INDIAN INSTITUTE OF TECHNOLOGY MADRAS


CH 5170: Process optimization
Quiz 1

• 8 AM- 8.50 AM. Total marks: 15. Closed book, closed notes.
• xT denotes transpose of x.
• If and when in doubt, clearly state your assumptions and proceed.

1. (Quadratic functions) Consider the following quadratic function


1
f (x) = 2017 + aT x + xT Hx,
2
(a) (2 marks) What are the necessary and sufficient conditions for existence of a stationary point
x∗ ?
(b) (2 marks) If a stationary point x∗ exists, show that
1
f (x) − f (x∗ ) = (x − x∗ )T H(x − x∗ )
2
For parts c, d and e use the following
" # " #
2 8 −6
a= , H=
11 −6 17

(c) (2 marks) One of the eigenvectors is known to be [1, −2]T . Determine the other eigenvector
and both eigenvalues.
(d) (2 mark) Determine all stationary points and classify them as precisely as you can.
(e) (2 marks) Sketch the contours of f .

2. (Duopoly ) Consider a company manufacturing Q units of a product. The market price per unit
product is inversely proportional to supply and can be expressed as a−bQ. The cost of manufacturing
(per unit product) is c.

(a) (1 mark) Set up a simple optimization problem to maximize profit and show that the optimal
production is (a − c)/2b.
(b) (4 marks) Now, assume that there are two competing, rational manufacturers who do not
co-operate with each other. Show that ideally, each should manufacture (a − c)/3b units.

THE END

You might also like