Esempio n. 1
0
 public void REPORT_FAILURE_2(String greekName, BasketType basketType, PlainVanillaPayoff payoff, Exercise exercise,
                              double s1, double s2, double q1, double q2, double r, Date today, double v1, double v2, double rho,
                              double expected, double calculated, double error, double tolerance)
 {
     Assert.Fail(Utilities.exerciseTypeToString(exercise) + " "
                 + payoff.optionType() + " option on "
                 + basketTypeToString(basketType)
                 + " with " + Utilities.payoffTypeToString(payoff) + " payoff:\n"
                 + "1st underlying value: " + s1 + "\n"
                 + "2nd underlying value: " + s2 + "\n"
                 + "              strike: " + payoff.strike() + "\n"
                 + "  1st dividend yield: " + q1 + "\n"
                 + "  2nd dividend yield: " + q2 + "\n"
                 + "      risk-free rate: " + r + "\n"
                 + "      reference date: " + today + "\n"
                 + "            maturity: " + exercise.lastDate() + "\n"
                 + "1st asset volatility: " + v1 + "\n"
                 + "2nd asset volatility: " + v2 + "\n"
                 + "         correlation: " + rho + "\n\n"
                 + "    expected   " + greekName + ": " + expected + "\n"
                 + "    calculated " + greekName + ": " + calculated + "\n"
                 + "    error:            " + error + "\n"
                 + "    tolerance:        " + tolerance);
 }