private void reallocate(final int row){
  final int size=this.cols[row].length;
  final int[] newCols=new int[size * 2];
  final double[] newValues=new double[size * 2];
  System.arraycopy(this.cols[row],0,newCols,0,size);
  System.arraycopy(this.values[row],0,newValues,0,size);
  this.cols[row]=newCols;
  this.values[row]=newValues;
}

private void reallocate ( final int row ) { final int size = this . cols [ row ] . length ; final int [ ] newCols = new int [ size * 2 ] ; final double [ ] newValues = new double [ size * 2 ] ; System . arraycopy ( this . cols [ row ] , 0 , newCols , 0 , size ) ; System . arraycopy ( this . values [ row ] , 0 , newValues , 0 , size ) ; this . cols [ row ] = newCols ; this . values [ row ] = newValues ; }
reallocate the value and column arrays of a row
