Ticket #9432: fix_typo.patch

File fix_typo.patch, 5.5 KB (added by oss.2012.team+2013D@…, 9 years ago)

Patch for multiprecision.qbk

  • libs/multiprecision/doc/multiprecision.qbk

     
    711711The final template parameters determine the type and range of the exponent: parameter `Exponent` can be
    712712any signed integer type, but note that `MinExponent` and `MaxExponent` can not go right up to the limits
    713713of the `Exponent` type as there has to be a little extra headroom for internal calculations.  You will
    714 get a compile time error if if this is the case.  In addition if MinExponent or MaxExponent are zero, then
     714get a compile time error if this is the case.  In addition if MinExponent or MaxExponent are zero, then
    715715the library will choose suitable values that are as large as possible given the constraints of the type
    716 and need for extra headhoom for internal calculations.
     716and need for extra headroom for internal calculations.
    717717
    718718There is full standard library and `numeric_limits` support available for this type.
    719719
     
    729729Narrowing conversions round to nearest and are `explicit`.
    730730* Conversion from a string results in a `std::runtime_error` being thrown if the string can not be interpreted
    731731as a valid floating point number.
    732 * All arithmetic operations are correctly rounded to nearest.  String comversions and the `sqrt` function
     732* All arithmetic operations are correctly rounded to nearest.  String conversions and the `sqrt` function
    733733are also correctly rounded, but transcendental functions (sin, cos, pow, exp etc) are not.
    734734
    735735[h5 cpp_bin_float example:]
     
    22042204* If a `double` floating-point number is converted to a decimal string
    22052205with at least 17 decimal digits
    22062206and then converted back to `double`,
    2207 then the result will be binary indentical to the original `double` value.
     2207then the result will be binary identical to the original `double` value.
    22082208
    22092209For most purposes, you will much more likely want
    22102210`std::numeric_limits<>::max_digits10`,
     
    24652465[round_error_1]
    24662466
    24672467There are, of course, many occasions when much bigger loss of precision occurs,
    2468 for exampe, caused by
     2468for example, caused by
    24692469[@http://en.wikipedia.org/wiki/Loss_of_significance Loss of significance or cancellation error]
    24702470or very many iterations.
    24712471
     
    26522652
    26532653   std::numeric_limits<T>::is_exact == false
    26542654
    2655 This is because these types are in essense a rational type with a fixed denominator.
     2655This is because these types are in essence a rational type with a fixed denominator.
    26562656
    26572657[h4 Floating Point Types]
    26582658
     
    27672767for the current rounding direction."]]
    27682768
    27692769So not only is correct rounding for the full number of digits not required,
    2770 but even if the *optional* recomended practice is followed,
     2770but even if the *optional* recommended practice is followed,
    27712771then the value of these last few digits is unspecified
    27722772as long as the value is within certain bounds.
    27732773
     
    30373037[[Backend][The actual arithmetic back-end that does all the work.]]
    30383038[[ExpressionTemplates][A Boolean value: when `et_on`, then expression templates are enabled, otherwise when set to `et_off` they are disabled.
    30393039   The default for this parameter is computed via the traits class `expression_template_default` whose member `value` defaults to `et_on` unless
    3040    the the traits class is specialized for a particular backend.]]
     3040   the traits class is specialized for a particular backend.]]
    30413041]
    30423042
    30433043   number();
     
    37073707
    37083708[variablelist
    37093709[[Digits][The number of digits precision the type
    3710 should support.  This is normally expresed as base-10 digits, but that can be changed via the second template parameter.]]
     3710should support.  This is normally expressed as base-10 digits, but that can be changed via the second template parameter.]]
    37113711[[base][An enumerated value (either `digit_base_10` or `digit_base_2`) that indicates whether `Digits` is base-10 or base-2]]
    37123712[[Allocator][The allocator used: defaults to type `void`, meaning all storage is within the class, and no dynamic
    37133713allocation is performed, but can be set to a standard library allocator if dynamic allocation makes more sense.]]
     
    37613761Binary to decimal conversion proceeds very similarly to the above, our aim is to calculate
    37623762`mantissa * 2^shift * 10^E` where `E` is the decimal exponent and `shift` is calculated
    37633763so that the result is an N bit integer assuming we want N digits printed in the result.
    3764 As before we use limitted precision arithmetic to calculate the result and up the
     3764As before we use limited precision arithmetic to calculate the result and up the
    37653765precision as necessary until the result is unambiguously correctly rounded.  In addition
    37663766our initial calculation of the decimal exponent may be out by 1, so we have to correct
    37673767that and loop as well in the that case.
     
    42764276[[detail/generic_interconvert.hpp][Generic interconversion routines.]]
    42774277[[detail/number_base.hpp][All the expression template code, metaprogramming, and operator overloads for `number`.]]
    42784278[[detail/no_et_ops.hpp][The non-expression template operators.]]
    4279 [[defail/functions/constants.hpp][Defines constants used by the floating point functions.]]
     4279[[detail/functions/constants.hpp][Defines constants used by the floating point functions.]]
    42804280[[detail/functions/pow.hpp][Defines default versions of the power and exponential related floating point functions.]]
    42814281[[detail/functions/trig.hpp][Defines default versions of the trigonometric related floating point functions.]]
    42824282]