## Pages

### Cloud Call

Last week, Mathematica 10 was released. The two major new features (at least from my point of view) are the Wolfram Programming Cloud and Finite Elements. Luckily, when there are new gadgets around to play with, the blog provides a perfect excuse  :)

To be able to toy around with both new features, I set out to solve a simple PDE (the Black-Scholes equation, of course), and deploy the whole calculation as small web application in the Wolfram Cloud.

Part I of this endeavour proved to be extremely simple: It's really just a matter of writing down the differential equation, the boundary and initial conditions and calling NDSolveValue with that (see screenshot)

The above example shows the value of a European Call as a function of time to maturity (tau=0...20) and price of the underlying (0..10). The strike of the call was K=5.0 in this example, the risk-free rate r=0.02 and the volatility was time dependent, with a value of 0.2 for tau=10, and a value of 0.8 for times tau > 10.

Part II proved to be a bit trickier: The FEM solution calculated on the cloud server is often different from the solution delivered by my local Mathematica 10. For constant volatility, my local Mathematica always obtains a solution that is indistinguishable from the analytic solution, while the results obtained in the cloud often (but not always) differ. Well, I guess that's why it is called a "beta"

Anyway - if you want to try the cloud solution, the link is here.

(in the form, "strike" is the strike of the option, vola1, tjump and vola2 are the constant volatility for times smaller or greater than tjump, rate is the risk-free rate and maxtime the maximum time to maturity to calculate)