LongCalc 0.4.8
LongCalc Arbitrary Precision Float and Complex Number Library
See the version list below for details.
InstallPackage LongCalc Version 0.4.8
dotnet add package LongCalc version 0.4.8
<PackageReference Include="LongCalc" Version="0.4.8" />
paket add LongCalc version 0.4.8
Release Notes
Unsigned Assembly
Throw an error on ('type')x for a bf or bcr x, when x is out of range of type 'type'. The user should be aware that no such error is thrown for an integertype explicit cast ('type')x for an mpz_t x.
The longtompz_t and mpz_ttolong Mpz_tVal and LongVal conversion functions have been redone in such a way that parsing of strings for numeric value is avoided.
Correct an inefficiency in x.toString and x.Round for x very large or x near 1 and Precision large.
Added an optional parameter ZeroOrPiMatchPrecision to the trigonometric functions which, if greater than 0, returns (as appropriate) 1, 0, or 1 if the input matches a multiple of Pi/2 to ZeroOrPiMatchPrecision decimal digits.
A likely natural limitation (of which I am not certain) on the underlying Mpir.NET software is that the bitlength of an mpz_t variable cannot be greater than long.MaxValue. Operating under this assumption, the Bitlength, doBitlength, doIndexofOne are made to be of type long. The shiftLeft and shiftRight functions 'shift' parameter is now of type long.
The bf object is modified such that x.mant is now readonly for a bf x, and an internal long parameter 'BL' equal to x.Bitlength is included and tracked. BL is then recalculated on the conclusion of any bf Add, Subtract, Multiply, or Divide or any 'new bf(...)' (other than 'new bf(x)' for a bf 'x'). This approach turns out to result in increased efficiency since the commonly used functions FloorLog2(x) and Log..(x) (among others) use the bitlength value. Operating under the assumption that an mpz_t Add, Subtract, Multiply or Divide result is (however briefly) fully contained in Process Memory, an estimate of the corresponding bf calculation memory requirements is made. If that estimate indicates the BL limitation would be exceeded, an error is thrown. If the estimate exceeds 3 gigabytes, garbage collection is forced and then memory availability is checked and an error is thrown if available memory is insufficient for the operation. This approach avoids the problem of an impasse which previously occurred in situations such as x.Add(y) when x is very large (or very small) compared to y (for bf 'x' and 'y').
Checks for arithmetic overflow or underflow are again compilerincluded in this release.
Dependencies

 Mpir.NET (>= 0.4.0)
GitHub Usage
This package is not used by any popular GitHub repositories.
Version History
Version  Downloads  Last updated  

0.5.1  236  7/29/2019  
0.4.12  241  6/15/2019  
0.4.11  250  6/10/2019  
0.4.10  253  5/13/2019  
0.4.9  284  4/15/2019  
0.4.8  274  4/7/2019  
0.4.7  270  3/23/2019  
0.4.6  274  3/4/2019  
0.4.5  282  3/4/2019  
0.4.4  281  2/10/2019  
0.4.3  302  1/30/2019  
0.4.2  296  1/29/2019  
0.4.1  301  1/29/2019  
0.3.25  264  3/25/2019  
0.3.24  265  3/4/2019  
0.3.23  315  1/25/2019  
0.3.22  320  1/23/2019  
0.3.21  345  1/12/2019  
0.3.20  353  1/4/2019  
0.3.19  312  1/3/2019  
0.3.18  322  12/30/2018  
0.1.25  269  3/25/2019  
0.1.24  278  3/4/2019  
0.1.23  383  1/12/2019  
0.1.22  320  12/24/2018  
0.1.21  584  4/20/2018  
0.1.16  479  9/2/2017  
0.1.15  455  8/23/2017  
0.1.11  413  8/4/2017  
0.1.10  457  8/1/2017  
0.1.8  410  7/27/2017  
0.1.7  433  6/14/2017  
0.1.6  428  6/14/2017  
0.1.5  481  6/10/2017  
0.1.2  641  11/22/2016  
0.1.1  495  11/12/2016 