[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
standalone application (octave to c++): define anonymous function for no
From: |
ola |
Subject: |
standalone application (octave to c++): define anonymous function for nonlin_curvefit() |
Date: |
Mon, 28 Jan 2019 03:31:45 -0600 (CST) |
Currently I try to use nonlin_curvefit() from octave optim package in my
standalone c++ code.
Unfortunatelly, I can't find any information how to declare octave-type
anonymous function in standalone application to prepare my model function.
Directly in octave I can do f = @(p,x)1-exp(p(1)*x), but in c++ I need to
declare a type of f; here function or octave::function doesn't work.
I can only use the feval to call nonlin_curvefit, and I don't know how put
there my model function, f:
octave_value_list result = octave::feval("nonlin_curvefit", ovl("@(p,x)
1-exp(p(1)*x)", init, t_points, y_val, opt(0)), 4); # also doesn't work
Could you help me?
-----
ola
--
Sent from: http://octave.1599824.n4.nabble.com/Octave-General-f1599825.html
- standalone application (octave to c++): define anonymous function for nonlin_curvefit(),
ola <=
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), Kai Torben Ohlhus, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), ola, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), Doug Stewart, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), Kai Torben Ohlhus, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), ola, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), mmuetzel, 2019/01/28
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), ola, 2019/01/31
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), mmuetzel, 2019/01/31
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), ola, 2019/01/31
- Re: standalone application (octave to c++): define anonymous function for nonlin_curvefit(), mmuetzel, 2019/01/31