@Override public Operand executeOperation(Stack<Expression> operands) throws ExpressionException { if (operands.size() < this.getCurrentOperands()) throw new ExpressionException("Wrong number of given parameters"); Apfloat value1 = Operand.extractNumber(operands.pop()); return new Operand(new Apfloat(value1.intValue())); }
@Override public Operand executeOperation(Stack<Expression> operands) throws ExpressionException { if (operands.size() < this.getCurrentOperands()) throw new ExpressionException("Wrong number of given parameters"); Apfloat value1 = Operand.extractNumber(operands.pop()); Apfloat radians = this.toRadians(value1); return new Operand(ApfloatMath.sinh(radians)); }