Question: How I avoid

 

I am using the codgen package to get gradient of a function GRADK := codegen[GRADIENT](SK)

where SK is a very lengthy term with variables x1 to x18

And then I use

GRADKopt := codegen[optimize](GRADK);

I need to convert this to  C++. The problem is the codgen of the gradient is creating the differentiation function D() in the RHS which makes it hard for me to covret it to Matlab or C++. Is there any way I can fix this

 

 

Please Wait...