public double [ ] [ ] getU ( ) { double [ ] [ ] X = new double [ n ] [ n ] ; double [ ] [ ] U = X ; for ( int i = 0 ; i < n ; i ++ ) { for ( int j = 0 ; j < n ; j ++ ) { if ( i <= j ) { U [ i ] [ j ] = LU [ i ] [ j ] ; } else { U [ i ] [ j ] = 0.0 ; } } } return X ; }
Get the Upper triangular factor .