[
https://issues.apache.org/jira/browse/MATH-1290?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Eric Barnhill updated MATH-1290:
--------------------------------
Attachment: ComplexUtilsTest.java
In the statement you are quoting, which threw an error:
TestUtils.assertEquals(msg, ansArrayc1r, ComplexUtils.real2Complex(d, 3, 7),
Math.ulp(1));
the 1 is in your case not being cast to a double when the test is run. I am not
getting this error so I am only guessing, but I changed all unit tests
requiring a double to use
Math.ulp(1.0)
and all requiring float to use
Math.ulp(1.0f)
And have uploaded a further patch for ComplexUtilsTest . Hopefully this fixes
the compile errors.
> Additions to Complex Utils; creation of conversion methods between Complex[],
> double[], float[], and interleaved arrays
> -----------------------------------------------------------------------------------------------------------------------
>
> Key: MATH-1290
> URL: https://issues.apache.org/jira/browse/MATH-1290
> Project: Commons Math
> Issue Type: Improvement
> Affects Versions: 3.5
> Reporter: Eric Barnhill
> Priority: Minor
> Labels: newbie, patch
> Fix For: 4.0
>
> Attachments: ComplexUtils.java, ComplexUtils.java,
> ComplexUtilsTest.java, ComplexUtilsTest.java, ComplexUtilsTest.java,
> LaguerreSolver.java
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> I propose to add several new methods to the ComplexUtils class enabling easy
> conversion between Complex[] arrays, real or imaginary double[] or float[]
> arrays, and interleaved complex double[] or float[] arrays. The last two in
> particular are beneficial to have for OpenCL implementations and the
> JTransforms library.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)