# Obtaining Step Norm in KNITRO.jl

**URL:** https://discourse.julialang.org/t/obtaining-step-norm-in-knitro-jl/107577
**Category:** Optimization (Mathematical)
**Created:** [December 13, 2023, 5:38pm UTC](https://discourse.julialang.org/t/obtaining-step-norm-in-knitro-jl/107577 "2023-12-13T17:38:04Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![frapac](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/frapac/32/6879_2.png) [@frapac](https://discourse.julialang.org/u/frapac)
#### Post date: [December 14, 2023, 4:30pm UTC](https://discourse.julialang.org/t/obtaining-step-norm-in-knitro-jl/107577/3 "2023-12-14T16:30:29Z")

</div>

I am not aware of any obvious solution to query the norm of the current step.

A workaround would to query the current primal-dual solution (x\_k, \lambda\_k) with `KN_get_solution`:  
[https://www.artelys.com/app/docs/knitro/3\_referenceManual/callableLibraryAPI.html#KN\_get\_solution](https://www.artelys.com/app/docs/knitro/3_referenceManual/callableLibraryAPI.html#KN_get_solution)

and to evaluate yourself the increment between two iterations :

{\tt step}\_k = (x\_{k+1}, \lambda\_{k+1}) - (x\_k , \lambda\_k)

---

_[View the full topic](https://discourse.julialang.org/t/obtaining-step-norm-in-knitro-jl/107577)._
