optimizer for complex?
![](https://secure.gravatar.com/avatar/0b7d465c9e16b93623fd6926775b91eb.jpg?s=120&d=mm&r=g)
Do any of the optimizers (n-dim nonlinear minimizer) handle complex values? It seems not, I seem to get good results by converting to a real vector That is, instead of calling fmin (f, x0=cmplx_array) convert x0 to a real array (real(x0), imag (x0), real (x1), imag (x1)....) And convert back inside the function f from real to complex.
![](https://secure.gravatar.com/avatar/612395b66b3e7959997007b342b3688a.jpg?s=120&d=mm&r=g)
On Wed, 19 Nov 2008 08:43:44 -0500 Neal Becker <ndbecker2@gmail.com> wrote:
Do any of the optimizers (n-dim nonlinear minimizer) handle complex values? It seems not, I seem to get good results by converting to a real vector
That is, instead of calling fmin (f, x0=cmplx_array)
convert x0 to a real array (real(x0), imag (x0), real (x1), imag (x1)....)
And convert back inside the function f from real to complex.
_______________________________________________ SciPy-user mailing list SciPy-user@scipy.org http://projects.scipy.org/mailman/listinfo/scipy-user
Just curious. Where does that problem appear ? Nils
![](https://secure.gravatar.com/avatar/0b7d465c9e16b93623fd6926775b91eb.jpg?s=120&d=mm&r=g)
Nils Wagner wrote:
On Wed, 19 Nov 2008 08:43:44 -0500 Neal Becker <ndbecker2@gmail.com> wrote:
Do any of the optimizers (n-dim nonlinear minimizer) handle complex values? It seems not, I seem to get good results by converting to a real vector
That is, instead of calling fmin (f, x0=cmplx_array)
convert x0 to a real array (real(x0), imag (x0), real (x1), imag (x1)....)
And convert back inside the function f from real to complex.
_______________________________________________ SciPy-user mailing list SciPy-user@scipy.org http://projects.scipy.org/mailman/listinfo/scipy-user
Just curious. Where does that problem appear ?
I'm trying to optimize an FIR filter (for a rather special application)
![](https://secure.gravatar.com/avatar/764323a14e554c97ab74177e0bce51d4.jpg?s=120&d=mm&r=g)
On Wed, Nov 19, 2008 at 07:43, Neal Becker <ndbecker2@gmail.com> wrote:
Do any of the optimizers (n-dim nonlinear minimizer) handle complex values?
Nope.
It seems not, I seem to get good results by converting to a real vector
Yup. -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco
participants (3)
-
Neal Becker
-
Nils Wagner
-
Robert Kern