public static SparseGradient createVariable(final int idx,final double value){
  return new SparseGradient(value,Collections.singletonMap(idx,1.0));
}

public static SparseGradient createVariable ( final int idx , final double value ) { return new SparseGradient ( value , Collections . singletonMap ( idx , 1.0 ) ) ; }
factory method creating an independent variable .
