code: public static DMatrix3 extractRow( DMatrix3x3 a , int row , DMatrix3 out ) {
          if( out == null) out = new DMatrix3();
          switch( row ) {
              case 0:
                  out.a1 = a.a11;
                  out.a2 = a.a12;
                  out.a3 = a.a13;
              break;
              case 1:
                  out.a1 = a.a21;
                  out.a2 = a.a22;
                  out.a3 = a.a23;
              break;
              case 2:
                  out.a1 = a.a31;
                  out.a2 = a.a32;
                  out.a3 = a.a33;
              break;
              default:
                  throw new IllegalArgumentException("Out of bounds row.  row = "+row);
          }
          return out;
      }
docs: Extracts the row from the matrix a.
  @param a Input matrix
  @param row Which row is to be extracted
  @param out output. Storage for the extracted row. If null then a new vector will be returned.
  @return The extracted row.