Rescaling ODE optimization problem with fmincon
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hi everyone. I'm trying to find a best fitting set of parameters for a three dimensional ODE using fmincon. My problem is that most of the parameters are ~0 - 50, but one very small (~10^-10) and another very large (~10^9), which is causing fmincon to end prematurely. I'm only using bound constraints.
I'm trying to do something similar to item 5 here: https://www.mathworks.com/help/optim/ug/when-the-solver-fails.html
But I don't know how to go about this for my problem. My objective funciton calls ode15s and calculates SSE with a time series of data.
Not neccisarily looking for a complete answer, just something to get me on the right track. Appreciate any advice.
1 Kommentar
Torsten
am 15 Feb. 2022
For the small parameter, use 1e10*p1, for the large parameter, use 1e-9*p2. Then p1 and p2 will be in the order of 1.
Antworten (1)
Ravi
am 24 Jan. 2024
Hi Peter Uhl,
When handling data that spans a broad range of magnitudes, optimization can become challenging. To address this, applying logarithmic transformations or normalization techniques can be highly effective strategies.
In logarithmic transformation, we consider the logarithms of the parameters rather than the parameters themselves. This way, multiplicative changes in the parameters become additive changes in the log space, which can be easier for the optimizer to handle. We can also try normalizing the parameters such that all values lie in the range [0, 1].
In case of logarithmic transformation, once ‘fmincon’ finds a solution, we transform the logarithm space back to the original space by applying exponentiation.
To solve the premature termination, you can also set the “MaxIter” and “MaxFunEvals” options using “optimset” function to a large number and pass that as parameter to the “fmincon” function. That would also help!
To learn more about the fmincon function and optimset, please refer to the following link.
Hope this approach helps you in fixing the issue that you are facing.
0 Kommentare
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!