FLA_Apply_Q_UT_inc_internal_check.c File Reference

(r)


Functions

FLA_Error FLA_Apply_Q_UT_inc_internal_check (FLA_Side side, FLA_Trans trans, FLA_Store storev, FLA_Obj A, FLA_Obj TW, FLA_Obj W1, FLA_Obj B, fla_apqutinc_t *cntl)

Function Documentation

FLA_Error FLA_Apply_Q_UT_inc_internal_check ( FLA_Side  side,
FLA_Trans  trans,
FLA_Store  storev,
FLA_Obj  A,
FLA_Obj  TW,
FLA_Obj  W1,
FLA_Obj  B,
fla_apqutinc_t cntl 
)

References FLA_Check_conformal_dims(), FLA_Check_identical_object_elemtype(), FLA_Check_matrix_matrix_dims(), FLA_Check_null_pointer(), FLA_Check_object_length_equals(), FLA_Check_object_width_equals(), FLA_Obj_length(), and FLA_Obj_width().

Referenced by FLA_Apply_Q_UT_inc_internal().

00036 {
00037     FLA_Error e_val;
00038 
00039     // Abort if the control structure is NULL.
00040     e_val = FLA_Check_null_pointer( ( void* ) cntl );
00041     FLA_Check_error_code( e_val );
00042 
00043     // Verify that the object element types are identical.
00044     e_val = FLA_Check_identical_object_elemtype( A, TW );
00045     FLA_Check_error_code( e_val );
00046 
00047     e_val = FLA_Check_identical_object_elemtype( A, W1 );
00048     FLA_Check_error_code( e_val );
00049 
00050     e_val = FLA_Check_identical_object_elemtype( A, B );
00051     FLA_Check_error_code( e_val );
00052 
00053     // Verify conformality between all the objects. This check works regardless
00054     // of whether the element type is FLA_MATRIX or FLA_SCALAR because the
00055     // element length and width are used instead of scalar length and width.
00056     if ( side == FLA_LEFT )
00057     {
00058         e_val = FLA_Check_conformal_dims( FLA_NO_TRANSPOSE, A, TW );
00059         FLA_Check_error_code( e_val );
00060 
00061         e_val = FLA_Check_matrix_matrix_dims( FLA_NO_TRANSPOSE, FLA_NO_TRANSPOSE, A, B, B );
00062         FLA_Check_error_code( e_val );
00063 
00064         e_val = FLA_Check_object_width_equals( W1, FLA_Obj_width( B ) );
00065         FLA_Check_error_code( e_val );
00066     }
00067     else
00068     {
00069         e_val = FLA_Check_conformal_dims( FLA_NO_TRANSPOSE, A, TW );
00070         FLA_Check_error_code( e_val );
00071 
00072         e_val = FLA_Check_matrix_matrix_dims( FLA_NO_TRANSPOSE, FLA_NO_TRANSPOSE, B, A, B );
00073         FLA_Check_error_code( e_val );
00074 
00075         e_val = FLA_Check_object_length_equals( W1, FLA_Obj_length( B ) );
00076         FLA_Check_error_code( e_val );
00077     }
00078 
00079     return FLA_SUCCESS;
00080 }


Generated on Mon Jul 6 05:45:51 2009 for libflame by  doxygen 1.5.9