# How to optimize trace of matrix inverse with JuMP or Convex?

**URL:** <https://discourse.julialang.org/t/how-to-optimize-trace-of-matrix-inverse-with-jump-or-convex/94167>\
**Category:** Optimization (Mathematical)\
**Tags:** question, optimization\
**Created:** [February 6, 2023, 9:25pm UTC](https://discourse.julialang.org/t/how-to-optimize-trace-of-matrix-inverse-with-jump-or-convex/94167 "2023-02-06T21:25:24Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![biona001](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/biona001/32/16497_2.png) [@biona001](https://discourse.julialang.org/u/biona001)\
**Post date:** [February 8, 2023, 2:08am UTC](https://discourse.julialang.org/t/how-to-optimize-trace-of-matrix-inverse-with-jump-or-convex/94167/6 "2023-02-08T02:08:36Z")

</div>

@lkapelevich Thank you for the suggestion.

I tried your approach on the same problem. Answers agree, and when `p=50`, your solution took ~120 seconds on my machine, while my original solution took ~960 seconds. So it’s definitely worth looking into, although I’m not really sure what you are doing. I’ll have to spend more time on it. Thank you so much!!

---

_[View the full topic](https://discourse.julialang.org/t/how-to-optimize-trace-of-matrix-inverse-with-jump-or-convex/94167)._
