if (exponent instanceof LongNaturalNumber) {
LongIntegerNumber exp = (LongIntegerNumber) ((LongNaturalNumber) exponent).toInteger();
if (exp.value == 0) {
if (value != 0) {
return new LongNaturalNumber(1);
} else {
throw new ArithmeticException(
String.format("Result is undefined: %s", new Exponentiation(this, exponent)));
}
} else if (exp.value == 1) {