Subject: Re: [boost] [GSoC 2014] [ Hypergeometric functions ] [ Complex Numbers Calculations ]
From: Christopher Kormanyos (e_float_at_[hidden])
Date: 2014-03-11 17:36:08
> I am Cosmin Boaca and I want to work during GSoC 2014 at
> the hypergeometric functions project.
Thank you for your interest in the project and also for the work
you have already put in while researching and prototyping
> My first question is : is there a way to do this operations using
> boost::multiprecision types such as cpp_dec_float and cpp_bin_float in
> order to store the real and the imaginary part of the complex number ?
That is a good question. The C++ standard specifies the behavior
of <complex> for the built-in types float, double, and long double,
and *only* for these types.
At the same time, Boost does not yet have an extended complex
class for supporting complex calculations with user-defined
floating-point types such as those in Boost.Multiprecision.
There is a proposal for an extended complex class, but we have
not had the opportunity to review it yet.
So if complex calculations are to be used in Boost.Math, then
we would need to find some sensible way to do these --- and
I am not talking about breaking the complex numbers into real
and imaginary constituents and performing the operations manually.
This would not be a sensible use of development time.
> The second question is : Can I use the complex functions from
> the cstdfloat branch of Boost.math ?
This is another good question --- and one on the cutting edge
of Boost.Math. The experimental support of <complex> in
Boost.Math is intended to be used for *exemplary* purposes
only when evaluating and assessing the behavior of certain
128-bit floating-point types. We decided to put this support
in namespace std because this is where it belongs for these
exemplary purposes. But it is not really in the spirit of Boost
to extend the std namespace.
So even though the template support you find in the
cstdfloat branch can handle complex calculations with all
extended user-defined floating-point types, it is nopt intended
to be used for this in other public areas of Boost.
So we might have to find another solution.
This is something that I will keep in mind for this upcoming
Keep up the good work!
On Monday, March 10, 2014 9:59 PM, Cosmin Boaca <boost.cosmin.boaca_at_[hidden]> wrote:
I am Cosmin Boaca and I want to work during GSoC 2014 at the hypergeometric
functions project. The project aims to approximate some hypergeometric
functions for real values of their parameters.
Even though the final result of the computation will be a real floating
point number, some intermediate results would require complex numbers
calculations such as the real power of a negative number, the square root
of a negative number and also basic operations with complex numbers.
My first question is : is there a way to do this operations using
boost::multiprecision types such as cpp_dec_float and cpp_bin_float in
order to store the real and the imaginary part of the complex number ?
The second question is : Can I use the complex functions from the cstdfloat
branch of Boost.math ?
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost