DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: ┃ B T

⟦08b140d8e⟧ TextFile

    Length: 1240 (0x4d8)
    Types: TextFile
    Names: »B«

Derivation

└─⟦5f3412b64⟧ Bits:30000745 8mm tape, Rational 1000, ENVIRONMENT 12_6_5 TOOLS 
    └─ ⟦91c658230⟧ »DATA« 
        └─⟦458657fb6⟧ 
            └─⟦1472c4407⟧ 
                └─⟦this⟧ 
└─⟦d10a02448⟧ Bits:30000409 8mm tape, Rational 1000, ENVIRONMENT, D_12_7_3
    └─ ⟦fc9b38f02⟧ »DATA« 
        └─⟦9b46a407a⟧ 
            └─⟦2e03b931c⟧ 
                └─⟦this⟧ 

TextFile

separate (Generic_Elementary_Functions)

function Arccoth (X : Float_Type) return Float_Type is

-- On input, X is a floating-point value in Float_Type;
-- On output, the value of Arccoth(X) (the inverse hyperbolic cotangent of X)
--            is returned.

-- The definition of Arccoth(Y) is log((Y+1)/(Y-1)) / 2, which is also
-- equivalent to the following three formulas:
--      1.  ( log(Y+1) - log(Y-1) ) / 2
--      2.  ( log(Y+1) - log(Y+1-2) ) / 2.
--      3.  log( 1 + ( 2 / (Y-1) ) ) / 2.
-- but computationally, the last formula is better.

   Z, Sign_Y : Common_Float;

   Y, Abs_Y, Temp : Common_Float;

   Log2 : constant Common_Float := 16#0.B17217F7D1CF79ABC9E3B39803F2F6AF40#;

   Log2_Times_2 : constant Common_Float := (2.0 * Log2);


begin

-- Filter out exceptional cases.

   Y     := Common_Float (X);
   Abs_Y := abs (Y);

   if (Abs_Y = 1.0) then
      raise Constraint_Error;
   end if;

   if (Abs_Y < 1.0) then
      raise Argument_Error;
   end if;

-- Calculate Arccoth(Y) by using KF_L1p.

   if (Y >= 0.0) then
      Sign_Y := 1.0;
   else
      Sign_Y := -1.0;
   end if;

   Temp := 2.0 / (Abs_Y - 1.0);
   Temp := Kf_L1p (Temp);
   Z    := Sign_Y * 0.5 * Temp;
   return (Float_Type (Z));

end Arccoth;