public static DMatrix2 extractColumn ( DMatrix2x2 a , int column , DMatrix2 out ) { if ( out == null ) out = new DMatrix2 ( ) ; switch ( column ) { case 0 : out . a1 = a . a11 ; out . a2 = a . a21 ; break ; case 1 : out . a1 = a . a12 ; out . a2 = a . a22 ; break ; default : throw new IllegalArgumentException ( "Out of bounds column. column = " + column ) ; } return out ; }
Extracts the column from the matrix a .