Supplying gradient for the subset of parameters
3 次查看(过去 30 天)
显示 更早的评论
Hi, I would like to ask if it is possible to supply analytical gradient for some parameters when optimising, using let's say fmincon. Support pages as well as documentation provide examples where user specifies analytical gradient for every parameter over which some function is optimised. In my problem, it is likely that analytical gradients are easy just for some parameters, therefore, I would like to help the optimisation by including this information and then rely on optimisation toolboxes to compute gradients for other parameters.
I may have a simple questions but I could not find the answer to.
Appreciate your help
0 个评论
采纳的回答
Alan Weiss
2022-8-11
The short answer is no: there is no provision to provide analytic gradients for a subset of the parameters. I cannot think of a workaround, either.
Alan Weiss
MATLAB mathematical toolbox documentation
更多回答(1 个)
Bruno Luong
2022-8-11
May be you could provide the gradient interface for all, but compute the subset derivative analytically and the complement by finite difference, providing you know ho to chose the step size (which might not be trivial).
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Genetic Algorithm 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!