Unlike the Black-Scholes-Merton option model's call and put options, which are path-independent, a barrier option is path-dependent. A barrier option is similar in many ways to an ordinary option, except a trigger exists. An in option starts its life worthless unless the underlying stock reaches a predetermined knock-in barrier. On the contrary, an out barrier option starts its life active and turns useless when a knock-out barrier price is breached. In addition, if a barrier option expires inactive, it may be worthless, or there may be a cash rebate paid out as a fraction of the premium. The four types of barrier options are given as follows:
Up-and-out: In this barrier option, the price starts from below a barrier level. If it reaches the barrier, it is knocked out.
Down-and-out: In this barrier option, the price starts from above a barrier. If it reaches the barrier, it is knocked out.
Up-and-in: In this barrier option, the price starts down a barrier and has to...