Bugs item #2637105, was opened at 2009-02-25 15:16
Message generated for change (Settings changed) made by lballabio
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112740&aid=2637105&group_id=12740Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
>Resolution: Accepted
Priority: 5
Private: No
Submitted By: Michael Heckl (heckl)
>Assigned to: Luigi Ballabio (lballabio)
Summary: error in method expectation of BlackScholesMerton process
Initial Comment:
The method "expectation(Time t0, Real x0, Time dt)" does wrong calculations. I tried it for a BlackScholesMerton Process and the result is wrong. After following up the code i found out that the method calculates:
return x0 * std::exp(dx);
where dx comes from
Real EulerDiscretization::drift(const StochasticProcess1D& process,
Time t0, Real x0, Time dt) const {
return process.drift(t0, x0)*dt;
}
And the process drift from
Real GeneralizedBlackScholesProcess::drift(Time t, Real x) const {
Real sigma = diffusion(t,x);
// we could be more anticipatory if we know the right dt
// for which the drift will be used
Time t1 = t + 0.0001;
return riskFreeRate_->forwardRate(t,t1,Continuous,NoFrequency,true)
- dividendYield_->forwardRate(t,t1,Continuous,NoFrequency,true)
- 0.5 * sigma * sigma;
}
This is simply wrong. What is wrong is that you didnt consider the Jenson inequality. Since exp is a strictly convex function we have:
let X_t be the BlackScholes Merton Process and S_t be ln(X_t) the related log-process, then
exp{E[S_t]}=exp{E[ln(X_t)]}<E[exp{ln(X_t)}]=E[X_t]
But the method expectation calculates the left side which is always to small. You can easily illustrate it if you choose the BlackScholesMerton Process in a way that the drift is 0. Check out the attached code for clarification.
Greetings
Michael
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112740&aid=2637105&group_id=12740------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev