none
Status of improved Decimal support? RRS feed

All replies

  • To extend Daniel's question, in some applications the precision of double is not enough and therefore just casting back and forth between double and decimal won't cut it either. 

    Sure it is possible to use Newton-Raphson with the value from the double-base equivalent as starting point or use expansion series (in combination with a Horner scheme) for both exp and log, but is it extremely inefficient for large value sets. 

    A "pure" decimal based version would be preferable if possible :D

    Monday, July 23, 2012 11:38 AM
  • Hi Daniel,

    Welcome to the MSDN Forum.

    Since this is a feature request, I changed it to discussion. Thank you for your understanding and support.

    Best regards,


    Mike Feng
    MSDN Community Support | Feedback to us
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Tuesday, July 24, 2012 9:11 AM
    Moderator
  • Since this is a feature request, I changed it to discussion. Thank you for your understanding and support.

    Actually it was a question to the BCL team if they have it on their agenda at all?

    But your are right that it is also a request for them to add it to their todo list or bump it up a notch since having full "decimal128" support (the iso/ecma standard allows decimal to conform to decimal128, but the msdn specs limits both the precision and usefullness).


    /Daniel Svensson

    Thursday, July 26, 2012 12:01 PM
  • A pure decimal based version is absolutely a requirement here, and one based on the work currently in progress in the C library via TR24732 and the _Decimal fundamental types. Implementations without support from underlying types are many and various. One approach I have used, which is suitable for scientific number crunching but not financial number crunching, is MPFR+GMP (or MPIR instead of GMP for Windows). This is the basis of GMPY2, a general precision numeric library for python. The GMPY2 project has ported these libraries to Visual Studio 2017 via the github forks by Brian Gladman.

    Saturday, February 16, 2019 11:57 AM