Optimization with absolute values: Difference between revisions

From Cornell University Computational Optimization Open Textbook - Optimization Wiki
Jump to navigation Jump to search
(Formatting)
No edit summary
 
(31 intermediate revisions by 4 users not shown)
Line 1: Line 1:
Authors: Matthew Chan (mdc297), Yilian Yin (yy896), Brian Amado (ba392), Peter (pmw99), Dewei Xiao (dx58) - SYSEN 5800 Fall 2020
Authors: Matthew Chan (mdc297), Yilian Yin (yy896), Brian Amado (ba392), Peter Williams (pmw99), Dewei Xiao (dx58) (SysEn 5800 Fall 2020)
 
Steward: Fengqi You


== Introduction ==
== Introduction ==
Absolute values can make it relatively difficult to determine the optimal solution when handled without first converting to standard form. This conversion of the objective function is a good first step in solving optimization problems with absolute values. As a result, one can go on to solve the problem using linear programing techniques.
Absolute values can make it relatively difficult to determine the optimal solution when handled without first converting to standard form. This conversion of the objective function is a good first step in solving optimization problems with absolute values. As a result, one can go on to solve the problem using linear programing techniques. With the addition of a new variable (ex: <math>\textstyle X^a </math>) in the objective function the problem is considered nonlinear. Additional constraints must be added to find the optimal solution.


== Method ==
== Method ==


=== Defining Absolute Values ===
=== Defining Absolute Values ===
An absolute value of a real number can be described as its distance away from zero, or the non-negative magnitude of the number. Thus,
An absolute value of a real number can be described as its distance away from zero, or the non-negative magnitude of the number. <ref> Mendelson, Elliott, Schaum's Outline of Beginning Calculus, McGraw-Hill Professional, 2008. https://books.google.com/books?id=A8hAm38zsCMC&pg=PA2#v=onepage&q&f=false </ref> Thus,


<math>\displaystyle |x|={\begin{cases}-x,&{\text{if }}x<0\\x,&{\text{if }}x\geq 0\end{cases}}</math>
<math>\displaystyle |x|={\begin{cases}-x,&{\text{if }}x<0\\x,&{\text{if }}x\geq 0\end{cases}}</math>


Absolute values can exist in linear optimization problems in two primary instances: in constraints and in the objective function.
Absolute values can exist in linear optimization problems in two primary instances: in constraints and in the objective function. <ref> "Absolute Values." ''lp_solve'', http://lpsolve.sourceforge.net/. Accessed 20 Nov. 2020. </ref>


=== Absolute Values in Constraints ===
=== Absolute Values in Constraints ===
Line 49: Line 47:
\end{align} </math>
\end{align} </math>


As seen visually, the feasible region has a gap and thus non-convex. The expressions also make it impossible for both to simultaneously hold true. This means that it is not possible to transform constraints in this form to linear equations.  
As seen visually, the feasible region has a gap and thus non-convex. The expressions also make it impossible for both to simultaneously hold true. This means that it is not possible to transform constraints in this form to linear equations. <ref> ''Optimization Methods in Management Science / Operations Research.'' Massachusetts Institute of Technology, Spring 2013, https://ocw.mit.edu/courses/sloan-school-of-management/15-053-optimization-methods-in-management-science-spring-2013/tutorials/MIT15_053S13_tut04.pdf. Accessed 20 Nov. 2020. </ref>


An approach to reach a solution for this particular case exists in the form of Mixed-Integer Linear Programming, where only one of the equations above is “active”.
An approach to reach a solution for this particular case exists in the form of Mixed-Integer Linear Programming, where only one of the equations above is “active”.
Line 113: Line 111:


As <math>\textstyle N</math> is sufficiently large (<math>\textstyle N</math> must be at least <math>\textstyle 2|X|</math> for this approach), the second constraint must be satisfied. Since <math>\textstyle Z</math> is non-negative, the fourth constraint must also be satisfied. The remaining constraints, <math>\textstyle X \ge Z</math> and <math>\textstyle X \le Z</math> can only be satisfied when <math>\textstyle Z = X</math> and is of non-negative signage. Together, these constraints will allow for the selection of the largest <math>\textstyle |X|</math> for maximization problems (or smallest for minimization problems).
As <math>\textstyle N</math> is sufficiently large (<math>\textstyle N</math> must be at least <math>\textstyle 2|X|</math> for this approach), the second constraint must be satisfied. Since <math>\textstyle Z</math> is non-negative, the fourth constraint must also be satisfied. The remaining constraints, <math>\textstyle X \ge Z</math> and <math>\textstyle X \le Z</math> can only be satisfied when <math>\textstyle Z = X</math> and is of non-negative signage. Together, these constraints will allow for the selection of the largest <math>\textstyle |X|</math> for maximization problems (or smallest for minimization problems).
=== Absolute Values in Nonlinear Optimization Problems ===
The addition of a new variable <math> (X_a) </math> to an objective function with absolute value quantities forms a nonlinear optimization problem. The absolute value quantities would require that the problem be reformatted before proceeding. Additional constraints must be added to account for the added variable.


==Numerical Example==
==Numerical Example==
* '''Example when all sign constraints are satisfied'''
'''Example when All Sign Constraints are Satisfied'''
 
<math>  \begin{align}
<math>  \begin{align}
\min \quad &{2|x_1| + 3|x_2| + |x_3|}  \\
\min \quad &{2|x_1| + 3|x_2| + |x_3|}  \\
Line 139: Line 141:


The problem has now been reformulated as a linear programming problem that can be solved normally:
The problem has now been reformulated as a linear programming problem that can be solved normally:


<math>  \begin{align}
<math>  \begin{align}
Line 152: Line 153:
The optimum value for the objective function is <math>3.5</math>, which occurs when <math>x_1 = 0 </math> and <math>x_2 = 0 </math> and <math>x_3 = 3.5 </math>.
The optimum value for the objective function is <math>3.5</math>, which occurs when <math>x_1 = 0 </math> and <math>x_2 = 0 </math> and <math>x_3 = 3.5 </math>.


* '''Example when some sign constraints are not satisfied'''
'''Example when Sign Constraints are not Satisfied'''
 
<math>  \begin{align}
<math>  \begin{align}
\min \quad &{2|x_1| + 3|x_2| - |x_3|}  \\
\min \quad &{2|x_1| + 3|x_2| - |x_3|}  \\
Line 180: Line 182:


The problem has now been reformulated as a linear programming problem that can be solved normally:
The problem has now been reformulated as a linear programming problem that can be solved normally:
 
<ref> Shanno, David F., and Roman L. Weil. “'Linear' Programming with Absolute-Value Functionals.” Operations Research, vol. 19, no. 1, 1971, pp. 120–124. Accessed 13 Dec. 2020. JSTOR, www.jstor.org/stable/168871. </ref>


<math>  \begin{align}
<math>  \begin{align}
Line 206: Line 208:
By reformulating the original problem into a Mixed-Integer Linear Program (MILP), we can utilize known programs to solve for the optimal solution(s).  
By reformulating the original problem into a Mixed-Integer Linear Program (MILP), we can utilize known programs to solve for the optimal solution(s).  


* '''Application in Financial:''' '''Portfolio Selection'''
=== Application in Financial: Portfolio Selection===
Under this topic, the same tricks played in the Numerical Example section to perform '''Reduction to a Linear Programming Problem''' will be applied here again, to reform the problem into a MILP in order to solve the problem. An example is given as below.  
Under this topic, the same tricks played in the Numerical Example section to perform '''Reduction to a Linear Programming Problem''' will be applied here again, to reform the problem into a MILP in order to solve the problem. An example is given as below.  






A portfolio is determined by what fraction of one's assets to put into each investment. It can be denoted as a collection of nonnegative numbers <math>\textstyle x_j</math>, where <math> j = 1, 2,...,n </math>. Because each <math> \textstyle x_j </math>stands for a portion of the assets, it sums to one. In order to get a highest reward through finding a right mix of assets, let <math>\mu</math>, the positive parameter, denote the importance of risk relative to the return, and <math>/textstyle Rj</math> denote the return in the next time period on investment <math>j, j = 1, 2,..., n</math>.  The total return one would obtain from the investment is <math>R = \sum_{j}\!x_j\!R_j </math>. The expected return is <math>\mathbb{E}\!R = \sum_{j}\!x_j\mathbb{E}\!R_j </math>.  And the Mean Absolute Deviation from the Mean (MAD) is <math>\mathbb{E}\left\vert \!R - \mathbb{E}\!R \right\vert =  \mathbb{E}\left\vert \sum_{j}\!x_j\tilde{R}_j  \right\vert </math>.   
A portfolio is determined by what fraction of one's assets to put into each investment. <ref>  Vanderbei R.J. (2008) Financial Applications. In: Linear Programming. International Series in Operations Research & Management Science, vol 114. Springer, Boston, MA. <nowiki>https://doi.org/10.1007/978-0-387-74388-2_13</nowiki> https://link.springer.com/chapter/10.1007/978-0-387-74388-2_13 </ref> It can be denoted as a collection of nonnegative numbers <math>\textstyle x_j</math>, where <math> j = 1, 2,...,n </math>. Because each <math> \textstyle x_j </math>stands for a portion of the assets, it sums to one. In order to get a highest reward through finding a right mix of assets, let <math>\mu</math>, the positive parameter, denote the importance of risk relative to the return, and <math>/textstyle Rj</math> denote the return in the next time period on investment <math>j, j = 1, 2,..., n</math>.  The total return one would obtain from the investment is <math>R = \sum_{j}\!x_j\!R_j </math>. The expected return is <math>\mathbb{E}\!R = \sum_{j}\!x_j\mathbb{E}\!R_j </math>.  And the Mean Absolute Deviation from the Mean (MAD) is <math>\mathbb{E}\left\vert \!R - \mathbb{E}\!R \right\vert =  \mathbb{E}\left\vert \sum_{j}\!x_j\tilde{R}_j  \right\vert </math>.   
 


maximize     <math display="inline">\mu\sum_j\!x_j\mathbb{E}\!R_j - \mathbb{E}\left\vert  \sum_j \!x_j\tilde{R}_j  \right\vert </math>
maximize       <math display="inline">\mu\sum_j\!x_j\mathbb{E}\!R_j - \mathbb{E}\left\vert  \sum_j \!x_j\tilde{R}_j  \right\vert </math>  


subject to    <math>\sum_j\!x_j = 1</math>
subject to    <math>\sum_j\!x_j = 1</math>  


<math>x_j \geq 0</math>     <math> j  = 1,2,..n.</math>
<math>x_j \geq 0</math> <math> j  = 1,2,..n.</math>  


where          <math>\tilde{R}_j  = \!R_j - \mathbb{E}\!R_j </math>
where          <math>\tilde{R}_j  = \!R_j - \mathbb{E}\!R_j </math>
Line 255: Line 258:




*'''data transfer rate'''
===Data Transfer Rate===
Faster-than-nyquist, or FTNS, is a framework to transmit signals beyond the Nyquist rate. The refence to this section proposed a 24.7% faster symbol rate by utilizing Sum-of-Absolute-Values optimization.
Another application of optimization with absolute values is data transfer rate. Faster-than-nyquist, or FTNS, is a framework to transmit signals beyond the Nyquist rate. The refence to this section proposed a 24.7% faster symbol rate by utilizing Sum-of-Absolute-Values optimization. <ref>Sasahara, Hampei & Hayashi, Kazunori & Nagahara, Masaaki. (2016). Symbol Detection for Faster-Than-Nyquist Signaling by Sum-of-Absolute-Values Optimization. IEEE Signal Processing Letters. PP. 1-1. 10.1109/LSP.2016.2625839.  https://www.researchgate.net/publication/309745511_Symbol_Detection_for_Faster-Than-Nyquist_Signaling_by_Sum-of-Absolute-Values_Optimization </ref>


The initial model is defined as follows:
The initial model is defined as follows:
<math>\displaystyle x_0 (t) = \sum^N_{n=1} x_{n,0} h_n (t), t \in [0,T] </math>
<math>\displaystyle x_0 (t) = \sum^N_{n=1} x_{n,0} h_n (t), t \in [0,T] </math>


where t ∈ R denotes the continuous time index, N ∈ N is the number of transmitted symbols in each transmission period, T > 0 is the interval of one period, xn,0 ∈ {+1, −1} are independent and identically distributed (i.i.d.) binary symbols [i.e., binary phase shift keying (BPSK)], and hn (t) (n = 1,...,N) are the modulation pulses.
where t ∈ R denotes the continuous time index, N ∈ N is the number of transmitted symbols in each transmission period, T > 0 is the interval of one period, <math>x_{n,0}</math>  ∈ {+1, −1} are independent and identically distributed (i.i.d.) binary symbols [i.e., binary phase shift keying (BPSK)], and <math>h_n (t) (n = 1,...,N) </math> are the modulation pulses.


Reformulated as a convex optimization problem and repeating Newton’s method with absolute values, the solution approximates can be achieved.
Reformulated as a convex optimization problem and repeating Newton’s method with absolute values, the solution approximates can be achieved:
<math>\displaystyle \min_{z \in R^N} (\lambda \Vert y - Hz \Vert^2_2 + \frac{1}{2} \Vert z - 1_N \Vert_1 + \frac{1}{2} \Vert z + 1_N \Vert_1 ) </math>
<math>\displaystyle \min_{z \in R^N} (\lambda \Vert y - Hz \Vert^2_2 + \frac{1}{2} \Vert z - 1_N \Vert_1 + \frac{1}{2} \Vert z + 1_N \Vert_1 ) </math>


== Conclusion ==
== Conclusion ==
The presence of an absolute value within the objective function prevents the use of certain optimization methods. Solving these problems requires that the function be manipulated in order to continue with linear programming techniques like the simplex method.
The presence of an absolute value within the objective function prevents the use of certain optimization methods. Solving these problems requires that the function be manipulated in order to continue with linear programming techniques like the simplex method. The applications of optimization with absolute values range from the financial sector to the digital world where data transfer rates can be improved as well as improving portfolio returns. The way these problems are formulated, must take absolute values into account in order to model the problem correctly. The absolute values inherently make these problems non-linear so determining the most optimal solutions is only achievable after reformulating them into linear programs.


== References ==
== References ==
# "Absolute Values." ''lp_solve'', http://lpsolve.sourceforge.net/5.1/absolute.htm. Accessed 20 Nov. 2020.
<references />
# ''Optimization Methods in Management Science / Operations Research.'' Massachusetts Institute of Technology, Spring 2013, https://ocw.mit.edu/courses/sloan-school-of-management/15-053-optimization-methods-in-management-science-spring-2013/tutorials/MIT15_053S13_tut04.pdf. Accessed 20 Nov. 2020.
# https://www.ise.ncsu.edu/fuzzy-neural/wp-content/uploads/sites/9/2019/08/LP-Abs-Value.pdf
# Vanderbei R.J. (2008) Financial Applications. In: Linear Programming. International Series in Operations Research & Management Science, vol 114. Springer, Boston, MA. <nowiki>https://doi.org/10.1007/978-0-387-74388-2_13</nowiki>

Latest revision as of 06:31, 21 December 2020

Authors: Matthew Chan (mdc297), Yilian Yin (yy896), Brian Amado (ba392), Peter Williams (pmw99), Dewei Xiao (dx58) (SysEn 5800 Fall 2020)

Introduction

Absolute values can make it relatively difficult to determine the optimal solution when handled without first converting to standard form. This conversion of the objective function is a good first step in solving optimization problems with absolute values. As a result, one can go on to solve the problem using linear programing techniques. With the addition of a new variable (ex: ) in the objective function the problem is considered nonlinear. Additional constraints must be added to find the optimal solution.

Method

Defining Absolute Values

An absolute value of a real number can be described as its distance away from zero, or the non-negative magnitude of the number. [1] Thus,

Absolute values can exist in linear optimization problems in two primary instances: in constraints and in the objective function. [2]

Absolute Values in Constraints

Within constraints, absolute value relations can be transformed into one of the following forms:

Where is a linear combination ( where are constants) and is a constant .

Form when

In this form, the only possible solution is if simplifying the constraint. Note that this solution also occurs if the constraint is in the form due to the same conclusion that the only possible solution is .

Form when

The second form a linear constraint can exist in is . In this case, an equivalent feasible solution can be described by splitting the constraint into two:

The solution can be understood visually since must lie between and , as shown below:

Form when

Visually, the solution space for the last form is the complement of the second solution above, resulting in the following representation:

In expression form, the solutions can be written as:

As seen visually, the feasible region has a gap and thus non-convex. The expressions also make it impossible for both to simultaneously hold true. This means that it is not possible to transform constraints in this form to linear equations. [3]

An approach to reach a solution for this particular case exists in the form of Mixed-Integer Linear Programming, where only one of the equations above is “active”.

The inequality can be reformulated into the following:

With this new set of constraints, a large constant is introduced, along with a binary variable . So long as is sufficiently larger than the upper bound of , the large constant multiplied with the binary variable ensures that one of the constraints must be satisfied. For instance, if , the new constraints will resolve to:

Since is sufficiently large, the latter constraint will always be satisfied, leaving only one relation active: . Functionally, this allows for the XOR logical operation of and .

Absolute Values in Objective Functions

In objective functions, to leverage transformations of absolute functions, all constraints must be linear.

Similar to the case of absolute values in constraints, there are different approaches to the reformation of the objective function, depending on the satisfaction of sign constraints. The satisfaction of sign constraints is when the coefficient signs of the absolute terms must all be either:

  • Positive for a minimization problem
  • Negative for a maximization problem

Sign Constraints are Satisfied

At a high level, the transformation works similarly to the second case of absolute value in constraints – aiming to bound the solution space for the absolute value term with a new variable, .

If is the absolute value term in our objective function, two additional constraints are added to the linear program:

The term in the objective function is then replaced by , relaxing the original function into a collection of linear constraints.

Sign Constraints are Not Satisfied

In order to transform problems where the coefficient signs of the absolute terms do not fulfill the conditions above, a similar conclusion is reached to that of the last case for absolute values in constraints – the use of integer variables is needed to reach an LP format.

The following constraints need to be added to the problem:

Again, is a large constant, is a replacement variable for in the objective function, and is a binary variable. The first two constraints ensure that one and only one constraint is active while the other will be automatically satisfied, following the same logic as above. The third and fourth constraints ensure that must be equal to and has either a positive or negative value. For instance, for the case of , the new constraints will resolve to:

As is sufficiently large ( must be at least for this approach), the second constraint must be satisfied. Since is non-negative, the fourth constraint must also be satisfied. The remaining constraints, and can only be satisfied when and is of non-negative signage. Together, these constraints will allow for the selection of the largest for maximization problems (or smallest for minimization problems).

Absolute Values in Nonlinear Optimization Problems

The addition of a new variable to an objective function with absolute value quantities forms a nonlinear optimization problem. The absolute value quantities would require that the problem be reformatted before proceeding. Additional constraints must be added to account for the added variable.

Numerical Example

Example when All Sign Constraints are Satisfied

The absolute value quantities will be replaced with single variables:

We must introduce additional constraints to ensure we do not lose any information by doing this substitution:

The problem has now been reformulated as a linear programming problem that can be solved normally:

The optimum value for the objective function is , which occurs when and and .

Example when Sign Constraints are not Satisfied

The absolute value quantities will be replaced with single variables:

We must introduce additional constraints to ensure we do not lose any information by doing this substitution:

The problem has now been reformulated as a linear programming problem that can be solved normally: [4]

The optimum value for the objective function is , which occur when and and .

Applications

Consider the problem . This problem cannot, in general, be solved with the simplex method. The problem has a simplex method solution (with unrestricted basis entry) only if c, are nonpositive (non-negative for minimizing problems).

The primary application of absolute-value functionals in linear programming has been for absolute-value or L(i)-metric regression analysis. Such application is always a minimization problem with all C(j) equal to 1 so that the required conditions for valid use of the simplex method are met.

By reformulating the original problem into a Mixed-Integer Linear Program (MILP), we can utilize known programs to solve for the optimal solution(s).

Application in Financial: Portfolio Selection

Under this topic, the same tricks played in the Numerical Example section to perform Reduction to a Linear Programming Problem will be applied here again, to reform the problem into a MILP in order to solve the problem. An example is given as below.


A portfolio is determined by what fraction of one's assets to put into each investment. [5] It can be denoted as a collection of nonnegative numbers , where . Because each stands for a portion of the assets, it sums to one. In order to get a highest reward through finding a right mix of assets, let , the positive parameter, denote the importance of risk relative to the return, and denote the return in the next time period on investment . The total return one would obtain from the investment is . The expected return is . And the Mean Absolute Deviation from the Mean (MAD) is .


maximize

subject to

,

where


Very obviously, this problem is not a linear programming problem yet. Similar to the numerical example showed above, the right thing to do is to replace each absolute value with a new variable and impose inequality constraints to ensure that the new variable is the appropriate absolute value once an optimal value is obtained. To simplify the program, an average of the historical returns can be taken in order to get the mean expected return: . Thus the objective function is turned into:

Now, replace with a new variable and thus the problem can be rewrote as:


maximize

subject to . t = 1, 2,...,T

where

. j = 1, 2,...,n

. t = 1, 2,...,T


So finally, after some simplifications methods and some tricks applied, the original problem is converted into a linear programming which is easier to be solved further.


Data Transfer Rate

Another application of optimization with absolute values is data transfer rate. Faster-than-nyquist, or FTNS, is a framework to transmit signals beyond the Nyquist rate. The refence to this section proposed a 24.7% faster symbol rate by utilizing Sum-of-Absolute-Values optimization. [6]

The initial model is defined as follows:

where t ∈ R denotes the continuous time index, N ∈ N is the number of transmitted symbols in each transmission period, T > 0 is the interval of one period, ∈ {+1, −1} are independent and identically distributed (i.i.d.) binary symbols [i.e., binary phase shift keying (BPSK)], and are the modulation pulses.

Reformulated as a convex optimization problem and repeating Newton’s method with absolute values, the solution approximates can be achieved:

Conclusion

The presence of an absolute value within the objective function prevents the use of certain optimization methods. Solving these problems requires that the function be manipulated in order to continue with linear programming techniques like the simplex method. The applications of optimization with absolute values range from the financial sector to the digital world where data transfer rates can be improved as well as improving portfolio returns. The way these problems are formulated, must take absolute values into account in order to model the problem correctly. The absolute values inherently make these problems non-linear so determining the most optimal solutions is only achievable after reformulating them into linear programs.

References

  1. Mendelson, Elliott, Schaum's Outline of Beginning Calculus, McGraw-Hill Professional, 2008. https://books.google.com/books?id=A8hAm38zsCMC&pg=PA2#v=onepage&q&f=false
  2. "Absolute Values." lp_solve, http://lpsolve.sourceforge.net/. Accessed 20 Nov. 2020.
  3. Optimization Methods in Management Science / Operations Research. Massachusetts Institute of Technology, Spring 2013, https://ocw.mit.edu/courses/sloan-school-of-management/15-053-optimization-methods-in-management-science-spring-2013/tutorials/MIT15_053S13_tut04.pdf. Accessed 20 Nov. 2020.
  4. Shanno, David F., and Roman L. Weil. “'Linear' Programming with Absolute-Value Functionals.” Operations Research, vol. 19, no. 1, 1971, pp. 120–124. Accessed 13 Dec. 2020. JSTOR, www.jstor.org/stable/168871.
  5. Vanderbei R.J. (2008) Financial Applications. In: Linear Programming. International Series in Operations Research & Management Science, vol 114. Springer, Boston, MA. https://doi.org/10.1007/978-0-387-74388-2_13 https://link.springer.com/chapter/10.1007/978-0-387-74388-2_13
  6. Sasahara, Hampei & Hayashi, Kazunori & Nagahara, Masaaki. (2016). Symbol Detection for Faster-Than-Nyquist Signaling by Sum-of-Absolute-Values Optimization. IEEE Signal Processing Letters. PP. 1-1. 10.1109/LSP.2016.2625839. https://www.researchgate.net/publication/309745511_Symbol_Detection_for_Faster-Than-Nyquist_Signaling_by_Sum-of-Absolute-Values_Optimization