diff --git a/scaddins/source/pricing/black_scholes.cxx b/scaddins/source/pricing/black_scholes.cxx index 98baa307c100..aa417f21af2d 100644 --- a/scaddins/source/pricing/black_scholes.cxx +++ b/scaddins/source/pricing/black_scholes.cxx @@ -559,6 +559,7 @@ static double barrier_term(double S, double vol, double rd, double rf, double c = 12.0*(rd-rf)/(vol*vol*vol*vol); // helper -db/dvol switch(greek) { case types::Value: + case types::Theta: val = vanilla_trunc(sc*S,vol,rd,rf,tau,K,B1,B2,pc,fd,greek) - pow(B/S,a)* vanilla_trunc(sc*B*B/S,vol,rd,rf,tau,K,B1,B2,pc,fd,greek); @@ -583,11 +584,6 @@ static double barrier_term(double S, double vol, double rd, double rf, vanilla_trunc(sc*B*B/S,vol,rd,rf,tau,K,B1,B2,pc,fd,types::Gamma) ); break; - case types::Theta: - val = vanilla_trunc(sc*S,vol,rd,rf,tau,K,B1,B2,pc,fd,greek) - - pow(B/S,a)* - vanilla_trunc(sc*B*B/S,vol,rd,rf,tau,K,B1,B2,pc,fd,greek); - break; case types::Vega: val = vanilla_trunc(sc*S,vol,rd,rf,tau,K,B1,B2,pc,fd,greek) - pow(B/S,a) * (