# \[ANN\] NonlinearOptimization TestFunctions.jl: A comprehensive collection of test functions for nonlinear optimization

**URL:** https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384
**Category:** Package Announcements
**Tags:** announcement, optimization, nonlinear-optimizati
**Created:** [August 5, 2025, 7:30pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384 "2025-08-05T19:30:38Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [August 5, 2025, 7:30pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/1 "2025-08-05T19:30:38Z")

</div>

Hello Julia Community,

I am excited to announce my new package, **`NonlinearOptimizationTestFunctionsInJulia.jl`**. It is designed to be a comprehensive collection of test functions for benchmarking nonlinear optimization algorithms. Each function comes with an analytical gradient and detailed metadata to ensure efficient and reliable testing.

**Key Features:**

- **Standardized Test Functions:** Includes well-known functions like Rosenbrock, Ackley, and Branin, all with consistent interfaces.
- **Analytical Gradients:** Accelerates testing and benchmarking processes.
- **Detailed Metadata:** Each function is supplied with information on its starting points, global minima, and properties (e.g., unimodal, multimodal).
- **Compatibility:** Seamless integration with popular optimization packages such as `Optim.jl`, `NLopt.jl`, and tools like `ForwardDiff.jl`.

This package is a tool for anyone looking to develop, test, or compare optimization algorithms.

You can find the repository here: [GitHub - UweAlex/NonlinearOptimizationTestFunctions.jl: NonlinearOptimizationTestFunctionsInJulia is a Julia package designed for testing and benchmarking nonlinear optimization algorithms. It provides a comprehensive collection of standard test functions, each equipped with analytical gradients, metadata, and validation mechanisms.](https://github.com/UweAlex/NonlinearOptimizationTestFunctions.jl)

---

<div class="post-metadata">

### Author: ![ForceBru](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/forcebru/32/21389_2.png) [@ForceBru](https://discourse.julialang.org/u/ForceBru)
#### Post date: [August 5, 2025, 9:00pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/2 "2025-08-05T21:00:23Z")

</div>

Cool! Looks similar to CUTEst ([GitHub - JuliaSmoothOptimizers/CUTEst.jl: Julia's CUTEst Interface](https://github.com/JuliaSmoothOptimizers/CUTEst.jl); has [286 unconstrained problems](https://jso.dev/tutorials/introduction-to-cutest/)) and [GitHub - JuliaSmoothOptimizers/OptimizationProblems.jl: Optimization Problems for Julia](https://github.com/JuliaSmoothOptimizers/OptimizationProblems.jl).

More test functions:

- [Test Functions Index — AMPGO 0.1.0 documentation](https://infinity77.net/global_optimization/test_functions.html)
- [The bbob Test Suite – \<b\>CO\</b\>mparing \<b\>C\</b\>ontinuous \<b\>O\</b\>ptimizers](https://coco-platform.org/testsuites/bbob/overview.html)

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [August 5, 2025, 9:42pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/3 "2025-08-05T21:42:28Z")

</div>

Can you make sure to support the Optimization.jl form? Then we’ll add it to the SciMLBenchmarks.jl server.

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [August 5, 2025, 9:54pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/5 "2025-08-05T21:54:16Z")

</div>

(post deleted by author)

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [August 5, 2025, 9:59pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/6 "2025-08-05T21:59:24Z")

</div>

Thanks for the great feedback! You’re right that our project shares vibes with CUTEst.jl and OptimizationProblems.jl, but we’re carving out a niche with a pure-Julia, lightweight suite starting with Molga & Smutnicki (2005) functions like Cross-in-Tray. We’re excited to expand with AMPGO and BBOB functions, like Alpine, to test algorithms across dimensions. Unlike CUTEst.jl, we avoid Fortran dependencies for stability.

---

<div class="post-metadata">

### Author: ![dpo](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dpo/32/3335_2.png) [@dpo](https://discourse.julialang.org/u/dpo)
#### Post date: [August 6, 2025, 12:36am UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/7 "2025-08-06T00:36:00Z")

</div>

There’s no Fortran in OptimizationProblems.jl. Why not contribute new problems there?

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [August 6, 2025, 6:17am UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/8 "2025-08-06T06:17:56Z")

</div>

I am new to GitHub, and I am not really experienced with Julia, so I thought it’s better to start something for myself first. Try to create Problems without making problems^^. The plan is to learn enough to be able to support other projects in the future

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [September 26, 2025, 12:01pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/9 "2025-09-26T12:01:24Z")

</div>

Update: The first 100 test functions are now implemented! Here’s the link to the current state on GitHub: [GitHub - UweAlex/NonlinearOptimizationTestFunctions.jl: NonlinearOptimizationTestFunctions is a Julia package designed for testing and benchmarking nonlinear optimization algorithms. It provides a comprehensive collection of standard test functions, each equipped with analytical gradients, metadata, and validation mechanisms.](https://github.com/UweAlex/NonlinearOptimizationTestFunctions.jl). Feedback is welcome! ![😊](https://global.discourse-cdn.com/julialang/original/3X/4/a/4a59e37d56ff78a50b211aab0c8f68cb73ec4032.svg "Lächelndes Gesicht mit lächelnden Augen")

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [November 16, 2025, 7:41am UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/10 "2025-11-16T07:41:01Z")

</div>

I’m excited to share an update on **NonlinearOptimizationTestFunctions.jl**!

I have now implemented **over 200 test functions** , including the full sets from **Jamil & Yang (2013)** and **Molga, Marcin, and Smutnicki (2005)**. All functions – and their analytical gradients where available – can now be evaluated in **high precision** , enabling reliable benchmarking for both standard and arbitrary-precision optimization workflows.

In addition, **100+ more unconstrained test functions** are already in the pipeline. I’ve also completed the initial groundwork for incorporating **constrained optimization problems** , which will significantly expand the package’s applicability in future releases.

More updates soon — and as always, contributions, feedback, and ideas are welcome!

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [December 17, 2025, 7:38pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/11 "2025-12-17T19:38:48Z")

</div>

I’m currently polishing up the documentation and experimenting with a few more demos to make the package even more user-friendly. One feature I’m particularly excited about is the `with_box_constraints` wrapper, which turns bounded test functions into unconstrained ones using a domain-safe modified exact L1 penalty method.

Unlike traditional L1 penalties that might evaluate the objective or gradient outside bounds (risking domain errors or instability), this wrapper clamps points to the feasible region before evaluation while adding a penalty term (with fixed ρ=10^6) to pull violations inward. This ensures safe, stable runs—especially for benchmarks where bounds define the valid domain—and works seamlessly with **any** unconstrained optimizer (e.g., LBFGS, BFGS, etc.), not just specific ones like Optim.jl’s Fminbox.

A quick benchmark across all 155 bounded functions (10 random feasible starts each) shows it’s often more robust and efficient than Fminbox: higher success rates on tricky cases (e.g., non-differentiable or ill-conditioned functions) and fewer calls when both converge. Check out the updated docs for usage examples and the full comparison

Feedback welcome—let me know if you’d like more details or to try it out!

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [December 17, 2025, 7:46pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/12 "2025-12-17T19:46:00Z")

</div>

@amontoison may be interested in this

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [December 28, 2025, 2:15pm UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/13 "2025-12-28T14:15:51Z")

</div>

# SHGO.jl: Global Optimization for Test Function Analysis

Quick update on [NonlinearOptimizationTestFunctions.jl](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384): I’m building **SHGO.jl** (Simplicial Homology Global Optimization) to automatically characterize multimodal test functions.

## Status

Working prototype finds all local minima + basin count:

```julia
using SHGO, NonlinearOptimizationTestFunctions

tf = fixed(TEST_FUNCTIONS["sixhumpcamelback"]; n=2)
result = analyze(tf; n_div=15)

println("$(result.num_basins) basins, global min: $(get_global_value(result))")
# Output: 6 basins, global min: -1.031628

```

[https://github.com/UweAlex/SHGO.jl](https://github.com/UweAlex/SHGO.jl)

## Next: PyCall Benchmark vs SciPy

This week I’ll validate against `scipy.optimize.shgo` to check correctness and performance. Goal is to add multimodality metrics to the test function collection automatically.

Feedback welcome! 🚀

---

<div class="post-metadata">

### Author: ![Aoxo\_MoxoA](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@Aoxo\_MoxoA](https://discourse.julialang.org/u/Aoxo_MoxoA)
#### Post date: [February 14, 2026, 9:37am UTC](https://discourse.julialang.org/t/ann-nonlinearoptimization-testfunctions-jl-a-comprehensive-collection-of-test-functions-for-nonlinear-optimization/131384/14 "2026-02-14T09:37:26Z")

</div>

"Update: **SHGO.jl** is now outperforming the Python version on several NOTF test cases, though `shgo.py` still covers more edge cases.

To achieve full feature parity, I am currently building a pure-Julia **SLSQP.jl**. As a first milestone, I’ve released **CoreNNLS.jl**.

While other NNLS packages exist, CoreNNLS.jl is designed for **numerical forensics** :

- **High Precision:** Fully generic to support `BigFloat` and `Double64`.
- **Robustness:** Solves pathologically ill-conditioned problems where standard `Float64` legacy-wrappers (Fortran/C) typically diverge.

This provides the stable, reproducible foundation needed for the upcoming SLSQP solver."
