Returns the the maximum of two {@link BigFloat} values.

@param value1 the first {@link BigFloat} value to compare
@param value2 the second {@link BigFloat} value to compare

@return the maximum {@link BigFloat} value
187898
public static BigFloat max(BigFloat value1, BigFloat value2) {
		return value1.compareTo(value2) >= 0 ? value1 : value2;
	}
391050
@Pure
	public static double max(double... values) {
		if (values == null || values.length == 0) {
			return Double.NaN;
		}
		double max = values[0];
		for (final double v : values) {
			if (v > max) {
				max = v;
			}
		}
		return max;
	}
78061
public static float max(final float a, final float b) {
        if (a > b) {
            return a;
        }
        if (a < b) {
            return b;
        }
        /* if either arg is NaN, return NaN */
        if (a != b) {
            return Float.NaN;
        }
        /* min(+0.0,-0.0) == -0.0 */
        /* 0x80000000 == Float.floatToRawIntBits(-0.0d) */
        int bits = Float.floatToRawIntBits(a);
        if (bits == 0x80000000) {
            return b;
        }
        return a;
    }
863183
double findMax() {
		double max = exploded.stream().reduce(Double.MIN_VALUE, (x, y) -> x > y ? x : y);
		return max;
	}
939051
protected function min(float $value1 = null, float $value2 = null) {
        $temp1 = $value1 ?: 0;
        $temp2 = $value2 ?: 0;

        $tempmin = min($temp1, $temp2);

        if (!$tempmin && $value1 !== 0 && $value2 !== 0) {
            $min = null;
        } else {
            $min = $tempmin;
        }

        return $min;
    }
926712
public static BigFloat min(BigFloat value1, BigFloat... values) {
		BigFloat result = value1;

		for (BigFloat other : values) {
			result = min(result, other);
		}

		return result;
	}
556644
public static int max(int a, int b, int c) {
    int ma;
    ma = a;
    if (b > ma) {
      ma = b;
    }
    if (c > ma) {
      ma = c;
    }
    return ma;
  }
316180
public static BigFloat min(BigFloat value1, BigFloat value2) {
		return value1.compareTo(value2) < 0 ? value1 : value2;
	}
973498
public static BigRational valueOf(double value) {
		if (value == 0.0) {
			return ZERO;
		}
		if (value == 1.0) {
			return ONE;
		}
		if (Double.isInfinite(value)) {
			throw new NumberFormatException("Infinite");
		}
		if (Double.isNaN(value)) {
			throw new NumberFormatException("NaN");
		}
		return valueOf(new BigDecimal(String.valueOf(value)));
	}
192090
public FloatPoint Subtract(FloatPoint point1, FloatPoint point2) {
        FloatPoint result = new FloatPoint(point1);
        result.Subtract(point2);
        return result;
    }
329990
public FloatPoint Add(FloatPoint point1, FloatPoint point2) {
        FloatPoint result = new FloatPoint(point1);
        result.Add(point2);
        return result;
    }
890284
public static int getMaxValue (int[] values)
    {
        int max = Integer.MIN_VALUE;
        int vcount = (values == null) ? 0 : values.length;
        for (int ii = 0; ii < vcount; ii++) {
            if (values[ii] > max) {
                // new max
                max = values[ii];
            }
        }
        return max;
    }
427353
public static double elementMax( DMatrix2 a ) {
        double max = a.a1;
        if( a.a2 > max ) max = a.a2;

        return max;
    }
1344822
public final double distance(final double[] value1, final double[] value2) {
        double agg = 0;
        for (int i = 0; i < value1.length; i++) {
            agg += (value1[i] - value2[i]) * (value1[i] - value2[i]);
        }
        return Math.sqrt(agg);
    }
1090453
public static int calculateQuotientScale(int precision1, int scale1,int precision2,  int scale2)
    {
        return Math.max(scale1 + precision2 -scale2 + 1, 6);        
    }
708108
private static ByteBuffer max(ByteBuffer b1, ByteBuffer b2, AbstractType<?> comparator)
    {
        if (b1 == null)
            return b2;
        if (b2 == null)
            return b1;

        if (comparator.compare(b1, b2) >= 0)
            return b1;
        return b2;
    }
211958
static MonetaryAmount max(MonetaryAmount a, MonetaryAmount b) {
        MoneyUtils.checkAmountParameter(Objects.requireNonNull(a), Objects.requireNonNull(b.getCurrency()));
        return a.isGreaterThan(b) ? a : b;
    }