void CoordinatesToSparse ( const Matrix<F>& N, const Matrix<F>& v, Matrix<F>& y ) { DEBUG_ONLY(CSE cse("svp::CoordinatesToSparse")) y = v; Trmv( UPPER, NORMAL, UNIT, N, y ); Round( y ); }
void TransposedCoordinatesToSparse ( const Matrix<F>& NTrans, const Matrix<F>& v, Matrix<F>& y ) { DEBUG_ONLY(CSE cse("svp::TransposedCoordinatesToSparse")) y = v; Trmv( LOWER, TRANSPOSE, UNIT, NTrans, y ); Round( y ); }
void TransposedCoordinatesToSparse ( const Matrix<Field>& NTrans, const Matrix<Field>& v, Matrix<Field>& y ) { EL_DEBUG_CSE y = v; Trmv( LOWER, TRANSPOSE, UNIT, NTrans, y ); Round( y ); }
void CoordinatesToSparse ( const Matrix<Field>& N, const Matrix<Field>& v, Matrix<Field>& y ) { EL_DEBUG_CSE y = v; Trmv( UPPER, NORMAL, UNIT, N, y ); Round( y ); }
Base<Field> TransposedCoordinatesToNorm ( const Matrix<Base<Field>>& d, const Matrix<Field>& NTrans, const Matrix<Field>& v ) { EL_DEBUG_CSE Matrix<Field> z( v ); Trmv( LOWER, TRANSPOSE, UNIT, NTrans, z ); DiagonalScale( LEFT, NORMAL, d, z ); return FrobeniusNorm( z ); }
Base<Field> CoordinatesToNorm ( const Matrix<Base<Field>>& d, const Matrix<Field>& N, const Matrix<Field>& v ) { EL_DEBUG_CSE Matrix<Field> z( v ); Trmv( UPPER, NORMAL, UNIT, N, z ); DiagonalScale( LEFT, NORMAL, d, z ); return FrobeniusNorm( z ); }
Matrix<Base<Field>> BatchTransposedCoordinatesToNorms ( const Matrix<Base<Field>>& d, const Matrix<Field>& NTrans, const Matrix<Field>& V, Int numNested=1 ) { EL_DEBUG_CSE Matrix<Field> Z( V ); // TODO(poulson): Decide whether this branch is necessary or not... if( V.Width() == 1 ) Trmv( LOWER, TRANSPOSE, UNIT, NTrans, Z ); else Trmm( LEFT, LOWER, TRANSPOSE, UNIT, Field(1), NTrans, Z ); DiagonalScale( LEFT, NORMAL, d, Z ); return NestedColumnTwoNorms( Z, numNested ); }