Azzera filtri
Azzera filtri

Square of Objective function expression gives an error

1 visualizzazione (ultimi 30 giorni)
Hi experts, I have just started doing optimization in the problem-based workflow. I refer to this documentation page, in order to formulate my own Non-Linear Objective function.
But when I run the following code,
obj = sum(residual.^2);
It produces the following error.
Undefined operator '.^' for input arguments of type 'optim.problemdef.OptimizationExpression'.
I am using MATLAB R2018a. My actual objective function expression is a bit complicated and I need to understand this error before I proceed further.
Your help will be highly appreciated. Thanks in advance!
  2 Commenti
Walter Roberson
Walter Roberson il 11 Nov 2018
The abilities of problem based optimization expanded in R2018b, you might be using too old of a version.
pradeep kumar
pradeep kumar il 11 Nov 2018
@ Walter Roberson, Thank you for your response. I will check that out in R2018b.

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Get Started with Optimization Toolbox in Help Center e File Exchange

Prodotti


Release

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by