This week, Eli Lilly's (LLY -1.87%) leading antidepressant drug Cymbalta will lose its U.S. patent exclusivity, opening the floodgates to generic competition.

During the first nine months of the year, Cymbalta generated more than $4.2 billion for Lilly, accounting for 24% of the company's revenue. 

Cymbalta's U.S. patent expiry, which is due on Wednesday, could not have come at a worse time. Last week, Lilly ditched its depression drug candidate edivoxetine when it failed to beat a placebo in phase 3 clinicals.

Edivoxetine was not seen as a potential blockbuster, but if it had been approved it might have helped plug part of the gap that Cymbalta's loss of exclusivity will leave in Lilly's CNS portfolio. 

Edivoxetine's phase 3 failure is the latest in a string of flops that have plagued the company's R&D efforts in the past two years -- solanezumab's disappointing results in Alzheimer's disease, ramucirumab's below-par results in breast cancer, and pomaglumetad methionil's failure in schizophrenia are examples. 

Will history repeat itself?
When Lilly's Prozac lost U.S. patent exclusivity in August 2001, it was also the leading antidepressant medication and accounted for the same 24% of Lilly's revenue, which was $10.8 billion at the time.

Immediately following Prozac's loss of patent exclusivity, generic competition entered the market in force, and the drug's quarterly sales dropped 66% from their previous year's level. Lilly's profits fell 7%, and it had to eliminate cash and equity bonuses for two years.

In 2002, the company lost substantial amount of revenue, saw virtually no income growth, and had to make extensive cost cuts. Lilly's market value lost more than $30 billion from its 2001 peak as a result of the ordeal. 

U.S. market for antidepressants
The U.S. antidepressants market, which currently stands at more than $9 billion, is in decline due to fierce competition from generics -- which currently control more than 40% of the market in terms of revenue and over 85% in terms of prescriptions.

Forest Laboratories' (NYSE: FRX) Lexapro, which used to be the second leading brand in the market, lost U.S. patent exclusivity in March 2012 and went into decline. The brand lost more than 90% of its $2.3 billion peak sales.

Valuation

Lilly, which has gained a meager 2.7% since the beginning of the year, has underperformed the market and is currently trading down 14% from its peak for the year. However, at a current P/E ratio of 11.6 the company does not look expensive.

In October this year, Lilly unveiled a fresh $5 billion share repurchase program as its executives outlined their future vision for the company and how they are planning to deal with Cymbalta's patent expiry. Despite the announcement, Lilly still ranked as the 197th most shorted stock on the NASDAQ.

Foolish takeaway
The imminent expiration of Cymbalta's patent, with its major contribution to Lilly's revenue mix, does create an immediate challenge that will be hard for the company to overcome. However, the fact that Lilly is planning to fork out $5 billion in hard won cash to buy back its own shares makes the stock rather attractive at its current P/E level. The two opposing trends are bound to cause cognitive dissonance in investors minds, which might create a sea of volatility that can spell asymmetric gains for the shrewd speculator. However, looking at this stock as a long-term investor, this patent expiration will be a blow to Lilly's revenue and earnings, and I'll be focusing on its pipeline in upcoming quarters.