[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [eigen] SVD Help.
- From: Benoit Jacob <jacob.benoit.1@xxxxxxxxx>
- Date: Fri, 9 Oct 2009 08:01:06 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=CT8uckDiqUx3RltxaQB5ff6RcBiYFAviv63ZSLI4hTA=; b=A1AsoO33IgupVQQrP0DIyEC8KrrTmEncFRbGD0zPcsjKtllnVxBsxFIEi+n8Bl841l hspCZ5VKRw89on/3jXOmJlvFlhyxTIAzvc3DJYzCjv2AKRwxtaxwywAQA47b6EriN5A0 a+GSF1jEdQg4SaBIBga4mBKo8B1YTTy2M0ndU=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=nPHVAUioRxhRCrkivSO2YtHX3YhxHoaJ4hHJzzCoscOUifwd3p/niI26LzieJ/uSUW Up9IE4ZraTBC5J0Ybp81aq1DsWta175Qjog6/+dZNbDOoKZPS7/b+di484B1PlSynXli B1B+aw8+zguVfK7cC8OiiFR9DyFknKcOD8tyY=
Eigen 2.0 doesn't support complex SVD.
The development branch has a JacobiSVD that already supports complex
SVD. The goal before the next release is to also make SVD support
complex, yes.
Benoit
2009/10/9 Tim Hutt <tdhutt@xxxxxxxxx>:
> Hi, I'm having some problems with SVDs:
>
> MatrixXcd K = ...;
> SVD<MatrixXcd> svdres = K.svd();
> MatrixXcd U = svdres.matrixU();
> VectorXd s = svdres.singularValues();
> double d = s(1);
>
> Gives the error:
>
> Error 5 error C2678: binary '<' : no operator found which takes a
> left-hand operand of type 'std::complex<double>' (or there is no
> acceptable conversion) c:\documents and settings\administrator\my
> documents\visual studio
> 2008\projects\images\images\eigen\src\SVD\SVD.h 136 Images
>
> The offending code:
>
>
> // Compute the transformation for the k-th column and
> // place the k-th diagonal in m_sigma[k].
> m_sigma[k] = matA.col(k).end(m-k).norm();
> if (m_sigma[k] != 0.0) // FIXME
> {
> if (matA(k,k) < 0.0) <-------- Error here.
> m_sigma[k] = -m_sigma[k];
> matA.col(k).end(m-k) /= m_sigma[k];
> matA(k,k) += 1.0;
> }
> m_sigma[k] = -m_sigma[k];
>
> Does Eigen2 not support SVDs of complex matrices?
>
>
>