As the following graph shows Apple gross margins and its operating margins have both been on a consistent upward slope since early 2006.
The reason is that the company has moved to more mobile devices as a percent of products shipped. Whereas Macs have had decent margins by the standard of the PC industry, they are not as profitable on a unit basis as iPods, iPhones or iPads. As portable or mobile products grow rapidly, it would follow that margins would as well.
However, the growth is not monotonic. There are occasional dips in gross margins. The cause is the launch of new device versions. On the following graph I show the launch times for the iPhone versions and the company’s gross margin as well as my estimates for iPhone and other product line margins.