title: Why is ArrayUtils.add not adding the element here
body: <p>I use <code>ArrayUtils.add(double[], double)</code> with some frequency. Apparently I have a blind spot for why it's not working here. Can anyone help?</p>
  
  <pre><code>double[] reliableNeighborValues = new double[1];
  for (int j = 0; j &lt; 8; j++) {
      if (pixelInfo[j] &gt; 0) {
          System.out.println("pre add array length "+reliableNeighborValues.length);
          for (int k = 0; k &lt; reliableNeighborValues.length; k++) {
              System.out.println("-- "+reliableNeighborValues[k]);
          }
          ArrayUtils.add(reliableNeighborValues, pixelInfo[j]);
          System.out.println("reliable neighbor "+j+" "+pixelInfo[j]+" array length "+reliableNeighborValues.length);
          for (int k = 0; k &lt; reliableNeighborValues.length; k++) {
              System.out.println("-- "+reliableNeighborValues[k]);
          }
      }
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>pre add array length 1
  
  -- 0.0
  
  reliable neighbor 0 5.3364882 array length 1
  
  -- 0.0
  </code></pre>