<p>Performs the following operation:<br>
<br>
a = a + b <br>
a<sub>i</sub> = a<sub>i</sub> + b<sub>i</sub> <br>
</p>

@param a A Vector. Modified.
@param b A Vector. Not modified.
480553
public static void addEquals( DMatrix3 a , DMatrix3 b ) {
        a.a1 += b.a1;
        a.a2 += b.a2;
        a.a3 += b.a3;
    }
357042
public static final void shift(Atom a, Atom b){

		Atom natom = add(a,b);
		double x = natom.getX();
		double y = natom.getY() ;
		double z = natom.getZ();
		a.setX(x);
		a.setY(y);
		a.setZ(z);
	}
79259
public Vector4f fma(Vector4fc a, Vector4fc b) {
        return fma(a, b, thisOrNew());
    }
680480
public static void fill( DMatrix2x2 a , double v  ) {
        a.a11 = v; a.a12 = v;
        a.a21 = v; a.a22 = v;
    }
64194
public Vector3d fma(Vector3dc a, Vector3dc b) {
        return fma(a, b, thisOrNew());
    }
1361608
public static void addEquals( DMatrix6x6 a , DMatrix6x6 b ) {
        a.a11 += b.a11;
        a.a12 += b.a12;
        a.a13 += b.a13;
        a.a14 += b.a14;
        a.a15 += b.a15;
        a.a16 += b.a16;
        a.a21 += b.a21;
        a.a22 += b.a22;
        a.a23 += b.a23;
        a.a24 += b.a24;
        a.a25 += b.a25;
        a.a26 += b.a26;
        a.a31 += b.a31;
        a.a32 += b.a32;
        a.a33 += b.a33;
        a.a34 += b.a34;
        a.a35 += b.a35;
        a.a36 += b.a36;
        a.a41 += b.a41;
        a.a42 += b.a42;
        a.a43 += b.a43;
        a.a44 += b.a44;
        a.a45 += b.a45;
        a.a46 += b.a46;
        a.a51 += b.a51;
        a.a52 += b.a52;
        a.a53 += b.a53;
        a.a54 += b.a54;
        a.a55 += b.a55;
        a.a56 += b.a56;
        a.a61 += b.a61;
        a.a62 += b.a62;
        a.a63 += b.a63;
        a.a64 += b.a64;
        a.a65 += b.a65;
        a.a66 += b.a66;
    }
152408
public void add(Vector v)
	{
		x += v.x;
		y += v.y;
		z += v.z;
	}
706130
public void updateRow(int i, double c, Vec b)
    {
        if(b.length() != this.cols())
            throw new ArithmeticException("vector is not of the same column length");
        if (b.isSparse())
            for (IndexValue iv : b)
                this.increment(i, iv.getIndex(), c * iv.getValue());
        else
            for (int j = 0; j < b.length(); j++)
                this.increment(i, j, c * b.get(j));
    }
347105
static Vector2d sum(final Tuple2d a, final Tuple2d b) {
        return new Vector2d(a.x + b.x, a.y + b.y);
    }
1167245
public void setRange(double A, double B)
    {
        if(A == B)
            throw new RuntimeException("Values must be different");
        else if(B > A)
        {
            double tmp = A;
            A = B;
            B = tmp;
        }
        this.A = A;
        this.B = B;
    }
132654
public static void elementPower(DMatrixD1 A , DMatrixD1 B , DMatrixD1 C ) {

        if( A.numRows != B.numRows || A.numRows != C.numRows ||
                A.numCols != B.numCols || A.numCols != C.numCols ) {
            throw new MatrixDimensionException("All matrices must be the same shape");
        }

        int size = A.getNumElements();
        for( int i = 0; i < size; i++ ) {
            C.data[i] = Math.pow(A.data[i], B.data[i]);
        }
    }
168242
@javax.annotation.Nonnull
  public static double[] op(@javax.annotation.Nonnull final double[] a, @javax.annotation.Nonnull final double[] b, @javax.annotation.Nonnull final DoubleBinaryOperator fn) {
    assert a.length == b.length;
    @javax.annotation.Nonnull final double[] c = new double[a.length];
    for (int j = 0; j < a.length; j++) {
      c[j] = fn.applyAsDouble(a[j], b[j]);
    }
    return c;
  }
1014441
public static void subtractEquals( DMatrix3 a , DMatrix3 b ) {
        a.a1 -= b.a1;
        a.a2 -= b.a2;
        a.a3 -= b.a3;
    }
734919
public static void elementDiv( DMatrix3 a , DMatrix3 b) {
        a.a1 /= b.a1;
        a.a2 /= b.a2;
        a.a3 /= b.a3;
    }
1112233
public static IsNullValue merge(IsNullValue a, IsNullValue b) {
        if (a == b) {
            return a;
        }
        if (a.equals(b)) {
            return a;
        }
        int aKind = a.kind & 0xff;
        int bKind = b.kind & 0xff;
        int aFlags = a.getFlags();
        int bFlags = b.getFlags();

        int combinedFlags = aFlags & bFlags;

        if (!(a.isNullOnSomePath() || a.isDefinitelyNull()) && b.isException()) {
            combinedFlags |= EXCEPTION;
        } else if (!(b.isNullOnSomePath() || b.isDefinitelyNull()) && a.isException()) {
            combinedFlags |= EXCEPTION;
        }

        // Left hand value should be >=, since it is used
        // as the first dimension of the matrix to index.
        if (aKind < bKind) {
            int tmp = aKind;
            aKind = bKind;
            bKind = tmp;
        }
        assert aKind >= bKind;
        int result = mergeMatrix[aKind][bKind];

        IsNullValue resultValue = (result == NO_KABOOM_NN) ? noKaboomNonNullValue(a.locationOfKaBoom)
                : instanceByFlagsList[combinedFlags >> FLAG_SHIFT][result];

        return resultValue;
    }
276066
public static int addExact(int a, int b) {
        long result = (long) a + b;
        checkNoOverflow(result == (int) result);
        return (int) result;
    }
1162832
public void add(IVector b, IVector result) {
        if ((b == null) || (size != b.size)) return;

        if (result.size != size) result.reshape(size);

        int i;
        for (i = 0; i < size; i++) {
            result.realvector[i] = realvector[i] + b.realvector[i];
            result.imagvector[i] = imagvector[i] + b.imagvector[i];
        }
    }