Source: tests/dense/convert.cpp 
 
 
   22 #include <tests/myratest.h>    26 ADD_TEST(
"convert_sds",
"[dense]")
    32   auto S2 = lower_precision(raise_precision(S1));
    33   NumberS S_error = frobenius(S1-S2);
    34   myra::out() << 
"  |S - float(double(S))| = " << S_error << std::endl;  
    35   REQUIRE(S_error == 0.0f);
    38 ADD_TEST(
"convert_czc",
"[dense]")
    44   auto C2 = lower_precision(raise_precision(C1));
    45   NumberS C_error = frobenius(C1-C2);
    46   myra::out() << 
"  |C - float(double(C))| = " << C_error << std::endl;  
    47   REQUIRE(C_error == 0.0f);
    50 ADD_TEST(
"convert_dsd",
"[dense]")
    56   auto D2 = raise_precision(lower_precision(D1));
    57   NumberD D_error = frobenius(D1-D2);
    58   myra::out() << 
"  |D - double(float(D))| = " << D_error << std::endl;
    59   REQUIRE(D_error < 1.0e-6);
    62 ADD_TEST(
"convert_zcz",
"[dense]")
    68   auto Z2 = raise_precision(lower_precision(Z1));
    69   NumberD Z_error = frobenius(Z1-Z2);
    70   myra::out() << 
"  |Z - double(float(Z))| = " << Z_error << std::endl;
    71   REQUIRE(Z_error < 1.0e-6);
 Interface class for representing subranges of dense Matrix's. 
Routines for copying and lowering the precision of a container. 
Routines for computing Frobenius norms of various algebraic containers. 
static Matrix< Number > random(int I, int J)
Generates a random Matrix of specified size. 
Definition: Matrix.cpp:353
Various utility functions/classes related to scalar Number types. 
General purpose dense matrix container, O(i*j) storage. 
Routines for copying and raising the precision of a container. 
float NumberS
Useful typedefs. 
Definition: Number.h:21
 
 Results:  [PASS] 
 
 
  |S - float(double(S))| = 0
 
 Go back to Summary of /test programs.