17
Solution of Optimization Problems Using MATLAB

17.1 Introduction

The solution of most practical optimization problems requires the use of computers. Several commercial software systems are available to solve optimization problems that arise in different engineering areas. MATLAB is a popular software that is used for the solution of a variety of scientific and engineering problems.1 MATLAB has several toolboxes each developed for the solution of problems from a specific scientific area. The specific toolbox of interest for solving optimization and related problems is called the optimization toolbox. It contains a library of programs or m‐files, which can be used for the solution of minimization, equations, least squares curve fitting, and related problems. The basic information necessary for using the various programs can be found in the user's guide for the optimization toolbox [1]. The programs or m‐files, also called functions, available in the minimization section of the optimization toolbox are given in Table 17.1. The use of the programs listed in Table 17.1 is demonstrated in this chapter. Basically, the solution procedure involves three steps after formulating the optimization problem in the format required by the MATLAB program (or function) to be used. In most cases, this involves stating the objective function for minimization and the constraints in “≤” form with zero or constant value on the right hand side of the inequalities. After this, Step 1 involves writing an m‐file for the objective function. Step 2 involves writing an m‐file for the constraints. Step 3 involves setting the various parameters at proper values depending on the characteristics of the problem and the desired output and creating an appropriate file to invoke the desired MATLAB program (and coupling the m‐files created to define the objective and constraints functions of the problem).

Table 17.1 MATLAB Programs or Functions for Solving Optimization Problems.

Type of optimization problem Standard form for solution by MATLAB Name of MATLAB program or function to solve the problem
Function of one variable or scalar minimization Find x to minimize f(x) with x 1 < x < x 2 fminbnd
Unconstrained minimization of function of several variables Find x to minimize f(x) fminunc or fminsearch
Linear programming problem Find x to minimize f T x subject to
  • [A]x ≤ b, [A eq]x = b eq,
  • lxu
linprog
Quadratic programming problem Find x to minimize
  • images x T [H]x + f T x subject to
  • [A]xb, [A eq]x = b eq,
  • lxu
quadprog
Minimization of function of several variables subject to constraints Find x to minimize f(x) subject to
  • c(x) ≤ 0, c eq = 0
  • [A]xb, [A eq]x = b eq,
  • lxu
fmincon
Goal attainment problem Find x and γ to minimize γ such that
  • F(x) – w γgoal,
  • c(x) ≤ 0, c eq = 0
  • [A]xb, [A eq]x = b eq,
  • lxu
fgoalattain
Minimax problem images
such that
  • c(x) ≤ 0, c eq = 0
  • [A]xb, [A eq]x = b eq,
  • lxu
fminimax
Binary integer programming problem Find x to minimize f T x subject to
  • [A]xb, [A eq]x = b eq,
  • each component of x is binary
bintprog

The examples presented in this chapter illustrate the application of MATLAB to solve the problems/methods presented in the previous chapters.

17.2 Solution of General Nonlinear Programming Problems

17.3 Solution of Linear Programming Problems

The solution of linear programming problems, using the simplex method, can be found as illustrated by the following example.

17.4 Solution of LP Problems Using Interior Point Method

The solution of linear programming problems, based on the interior point method, using MATLAB is illustrated by the following example.

17.5 Solution of Quadratic Programming Problems

17.6 Solution of One‐Dimensional Minimization Problems

The solution of one‐dimensional minimization problems, using the MATLAB program optimset, is illustrated by the following example.

17.7 Solution of Unconstrained Optimization Problems

The solution of multivariable unconstrained minimization problems using the MATLAB function fminunc is illustrated in this section.

17.8 Solution of Constrained Optimization Problems

The solution of multivariable minimization problems, with inequality and equality constraints, using the MATLAB function fmincon is illustrated in this section.

17.9 Solution of Binary Programming Problems

The MATLAB function bintprog can be used to solve a binary (or zero–one) programming problem. The following example illustrates the procedure.

17.10 Solution of Multiobjective Problems

The MATLAB function fgoalattain can be used to solve a multiobjective optimization problem using the goal attainment method. The following example illustrates the procedure.

References and Bibliography

  1. 1 (2003). Optimization Toolbox for use with MATLABR, User's Guide, Version 2. The MathWorks.
  2. 2 Foster, N. (2016). MATLAB Optimization Functions and Examples. ISBN: 9781520265025.
  3. 3 Lopez, C.P. (2014). MATLAB Optimization Techniques. Apress. ISBN: 9781484202920.

Problems

  1. 17.1 Find the solution of the optimization problem formulated in Problem 1.32(a) using MATLAB.
  2. 17.2 Find the solution of the optimization problem formulated in Problem 1.33(a) using MATLAB.
  3. 17.3 Find the solution of Problem 1.31 using MATLAB.
  4. 17.4 Find the solution of Problem 1.2(a) using MATLAB.
  5. 17.5 Find the solution of Problem 1.2(b) using MATLAB.
  6. 17.6 Solve Example 3.7 using MATLAB (simplex method).
  7. 17.7 Solve Problem 3.12 using MATLAB (simplex method).
  8. 17.8 Solve Problem 3.24 using MATLAB (simplex method).
  9. 17.9 Find the optimal solution of the LP problem stated in Problem 3.45 using MATLAB (simplex method).
  10. 17.10 Find the optimal solution of the LP problem described in Problem 3.101 using MATLAB.
  11. 17.11 Solve the LP problem stated in Problem 4.9 using MATLAB (interior method).
  12. 17.12 Solve the LP problem stated in Problem 4.12 using MATLAB (interior method).
  13. 17.13 Solve the LP problem stated in Problem 4.13 using MATLAB (interior method).
  14. 17.14 Solve the LP problem stated in Problem 4.36 using MATLAB (interior method).
  15. 17.15 Solve the LP problem stated in Problem 4.37 using MATLAB (interior method).
  16. 17.16 Solve the following quadratic programming problem using MATLAB:
    equation
  17. 17.17 Solve the following quadratic programming problem using MATLAB:
    equation
  18. 17.18 Solve the following quadratic programming problem using MATLAB:
    equation
  19. 17.19 Solve the following quadratic programming problem using MATLAB:
    equation
  20. 17.20 Write a computer program, in the form of a subroutine, to implement the Fibonacci method.
  21. 17.21 Write a computer program, in the form of a subroutine, to implement the golden section method.
  22. 17.22 Write a computer program, in the form of a subroutine, to implement the quadratic interpolation method.
  23. 17.23 Write a computer program, in the form of a subroutine, to implement the cubic interpolation method.
  24. 17.24 Write a computer program, in the form of a subroutine, to implement the secant method.
  25. 17.25 Find the maximum of the function given by Eq. (4) in Problem 5.5 using MATLAB. Assume the bounds on λ as 0 and 3.
  26. 17.26 Find the minimum of the function f (λ) given in Problem 5.16, in the range 0–5, using MATLAB.
  27. 17.27 Find the minimum of f(x) = x(x − 1.5) in the interval (0, 1) using MATLAB.
  28. 17.28 Find the minimum of the function images in the range (0, 10) using MATLAB.
  29. 17.29 Find the minimum of the function f(x) = x 3 + x 2 − x − 2 in the interval −4 and 4 using MATLAB.
  30. 17.30 Find the minimum of the function images in the interval −4 and 4 using MATLAB.
  31. 17.31 Write a computer program to implement Powell's method using the golden section method of one‐dimensional search.
  32. 17.32 Write a computer program to implement the Davidon–Fletcher–Powell method using the cubic interpolation method of one‐dimensional search. Use a finite‐difference scheme to evaluate the gradient of the objective function.
  33. 17.33 Write a computer program to implement the BFGS method using the cubic interpolation method of one‐dimensional minimization. Use a finite‐difference scheme to evaluate the gradient of the objective function.
  34. 17.34 Write a computer program to implement the steepest descent method of unconstrained minimization with the direct root method of one‐dimensional search.
  35. 17.35 Write a computer program to implement the Marquardt method coupled with the direct root method of one‐dimensional search.
  36. 17.36 Find the minimum of the quadratic function given by Eq. (6.141) starting from the solution X 1 = {0, 0}T using MATLAB.
  37. 17.37 Find the minimum of the Powell's quartic function given by Eq. (6.142) starting from the solution X 1 = {3, −1, 0, 1}T using MATLAB.
  38. 17.38 Find the minimum of the Fletcher and Powell's helical valley function given by Eq. (6.143) starting from the solution X 1 = {−1, 0, 0}T using MATLAB.
  39. 17.39 Find the minimum of the nonlinear function given by Eq. (6.144) starting from the solution X 1 = {0, 1, 2}T using MATLAB.
  40. 17.40 Find the minimum of the Wood's function given by Eq. (6.149) starting from the solution X 1 = {−3, −1, −3, −1}T using MATLAB.
  41. 17.41 Write a computer program to implement the interior penalty function method with the DFP method of unconstrained minimization and the cubic interpolation method of one‐dimensional search.
  42. 17.42 Write a computer program to implement the exterior penalty function method with the BFGS method of unconstrained minimization and the direct root method of one‐dimensional search.
  43. 17.43 Write a computer program to implement the augmented Lagrange multiplier method with a suitable method of unconstrained minimization.
  44. 17.44 Write a computer program to implement the sequential linear programming method.
  45. 17.45 Find the solution of the welded beam design problem formulated in Section 7.22.3 using the MATLAB function fmincon with the starting point X 1 = {0.4, 6.0, 9.0, 0.5}T
  46. 17.46 Find the solution of the following problem (known as Rosen–Suzuki problem) using the MATLAB function fmincon with the starting point X 1 = {0, 0, 0, 0}T:

    Minimize

    equation

    subject to

    equation
  47. 17.47 Find the solution of the following problem using the MATLAB function fmincon with the starting point X 1 = {0.5, 1.0}T:

    Minimize

    equation

    subject to

    equation
  48. 17.48 Find the solution of the following problem using the MATLAB function fmincon with the starting point: X 1 = {0.5, 1.0, 1.0}:
    equation

    subject to

    equation
  49. 17.49 Find the solution of the following problem using the MATLAB function fmincon with the starting point: X 1 = {1.0, 1.0}T:
    equation

    subject to

    equation
  50. 17.50 Find the solution of the following binary programming problem using the MATLAB function bintprog:
    equation

    where

    equation
  51. 17.51 Find the solution of the following binary programming problem using the MATLAB function bintprog:
    equation

    where

    equation
    equation
    equation
  52. 17.52 Consider the following two‐objective optimization problem:

    Find X = {x 1 x 2 x 3 x 4 x 5 x 6}T

    to minimize

    equation

    subject to

    equation

    Find the minima of the individual objective functions under the stated constraints using the MATLAB function fmincon.

  53. 17.53 Find the solution of the two‐objective optimization problem stated in Problem 17.52 using the weighting function method with the weights w 1 = w 2 = 1. Use the MATLAB function fmincon for the solution.
  54. 17.54 Find the solution of the two‐objective optimization problem stated in Problem 17.52 using the global criterion method with p = 2. Use the MATLAB function fmincon for the solution.
  55. 17.55 Find the solution of the two‐objective optimization problem stated in Problem 17.52 using the bounded objective function method. Take the lower and upper bounds on f 2 as 80 and 120% of the optimum value images found in Problem 17.52. Use the MATLAB function fmincon for the solution.
  56. 17.56 Find the solution of the two‐objective optimization problem stated in Problem 17.52 using the goal attainment method. Use the MATLAB function fgoalattain for the solution. Use suitable goals for the objectives.
  57. 17.57 Consider the following three‐objective optimization problem:

    Find X = {x 1 x 2}T to minimize

    equation

    subject to

    equation

    Find the minima of the individual objectives under the stated constraints using the MATLAB function fmincon.

  58. 17.58 Find the solution of the three‐objective problem stated in Problem 17.57 using the weighting function method with the weights w 1 = w 2 = w 3 = 1. Use the MATLAB function fmincon for the solution.
  59. 17.59 Find the solution of the multiobjective problem stated in Problem 17.57 using the goal attainment method.

    Use the MATLAB function fgoalattain for the solution. Use suitable goals for the objectives.

Note

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.118.150.80