# Optimizing over real matrices with eigenvalues in $(0,1)$

**URL:** <https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630>\
**Category:** Optimization (Mathematical)\
**Tags:** linearalgebra\
**Created:** [November 5, 2020, 4:10pm UTC](https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630 "2020-11-05T16:10:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![marcus](https://avatars.discourse-cdn.com/v4/letter/m/85e7bf/32.png) [@marcus](https://discourse.julialang.org/u/marcus)\
**Post date:** [November 5, 2020, 4:10pm UTC](https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630/1 "2020-11-05T16:10:49Z")

</div>

I’m trying to optimize a function with respect to a real matrix M with all eigenvalues real and lying in the open interval (0,1).

I know that for a real symmetric positive-definite matrix S, we can use the Cholesky factorization S = L L^T where elements of L are free parameters.

Is there a similar way of enforcing the above eigenvalue constraint?

---

<div class="post-metadata">

**Author:** ![mohamed82008](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mohamed82008/32/18171_2.png) [@mohamed82008](https://discourse.julialang.org/u/mohamed82008)\
**Post date:** [November 5, 2020, 5:14pm UTC](https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630/2 "2020-11-05T17:14:11Z")

</div>

Use semidefinite programming with the following constraints:

1. S \succcurlyeq 0
2. T = I - S
3. T \succcurlyeq 0

where I is the identity matrix and S and T are matrix decision variables.

---

<div class="post-metadata">

**Author:** ![marcus](https://avatars.discourse-cdn.com/v4/letter/m/85e7bf/32.png) [@marcus](https://discourse.julialang.org/u/marcus)\
**Post date:** [November 5, 2020, 5:27pm UTC](https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630/3 "2020-11-05T17:27:04Z")

</div>

Thank you for your reply. So to optimize over matrices M which satisfy my eigenvalue constraint, I should equivalently optimize over general positive (semi-) definite matrices T and S, subject to the linear constraint that T=I-S?

---

<div class="post-metadata">

**Author:** ![mohamed82008](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mohamed82008/32/18171_2.png) [@mohamed82008](https://discourse.julialang.org/u/mohamed82008)\
**Post date:** [November 5, 2020, 5:35pm UTC](https://discourse.julialang.org/t/optimizing-over-real-matrices-with-eigenvalues-in-0-1/49630/4 "2020-11-05T17:35:58Z")

</div>

Yes. S will be your M.
