Γ = δΔ/δS = δ^{2}V/δS^{2}
Δ  option delta
V  option price
S  price of the underlying asset
Mathematically, delta is the 1st derivative of the option price relative to the underlying asset price. Gamma is the 2nd derivative with respect to asset price.
Gamma indicates the change in delta when the price of the underlying asset moves, i.e. mathematically, gamma represents the derivative of the option delta relative to the underlying asset price. Figure 1 shows that delta (the slope of the tangent to the option price graph) is not constant, but depends on the asset price.
Chart 1. Delta of long call
Chart 2. Gamma of long call
Chart 3. Delta of long put
Chart 4. Gamma of long put
Delta is used as an indicator of the change in the option price only for small changes in the asset price and assumes a linear relationship between the price of the underlying asset and the option price. However, if the price of the asset rises or falls very significantly, then the actual change in the option price will be very different from what was indicated by delta. More details about delta can be read in Option delta as hedge ratio.
Option traders compare delta to duration when looking at the relationship between bond price and interest rates, and gamma to convexity.
Gamma Gamma (or convexity, to use bond terminology) measures the rate of change in option's delta. Gamma indicates the degree of convexity of the option price graph relative to the underlying asset at a certain point. The higher the convexity, the faster the delta changes. Buying call and put options results in a long (or positive) gamma, and selling options results in a negative gamma position. 
Gamma risk
Since professional option market participants use the delta to control the risk of their portfolio, they are subject to the risk of changes in delta position. For example, a trader sells 1,000 call options of Google with a delta of 0.50 each. Thus, the delta is minus 500 shares. In other words, with small movements in the share price, the profit (loss) from a short option position will be similar to the profit (loss) from a short position of 500 shares  not 1,000, since the change in the call option price will be half of the change in the share price.
To hedge the delta , i.e. reduce the delta to zero, trader buys 500 shares. Such a hedge will only be effective if the stock price fluctuates slightly. The problem arises if the share price rises quickly and very high, as the short option position will suffer losses significantly faster than the delta indicates. This behavior is due to gamma or convexity. The profit from the acquired 500 shares will not be enough to cover the losses from the option position, since the share price moves linearly, and the delta value changes nonlinearly.
Example. Trader sold call options for 1,000 shares with a delta of 0.50 each, which is equivalent to a short position of 500 shares. The trader then hedges the delta by buying 500 shares. The gamma of options sold is 0.01 or 1%. This means that if the price of Google rises (falls) by 1%, the delta of call option will increase by 0.01. Delta _{0} = Delta Options + Delta Stocks (Gamma is negative because the options were sold.) Step 1. Suppose that once the trader has sold the options and bought 500 shares, the share price rises by 10% and the call delta is now 0.60. In this case, the delta of a short option position will be equivalent to a short position in 600 shares, not 500. Now the delta of the entire portfolio is not zero, as it was before the price increase, but minus 100 shares. Delta _{1} = Delta _{0} + Gamma _{0} x 10% This suggests that the trader lost more from the option position than he earned from 500 shares.
Step 2. Next, trader faces a choice. First, the trader can leave everything as it is, i.e. keep holding 500 shares and hope that the share price will fall back and the entire portfolio will compensate for the losses, since the delta of the portfolio is equal to minus 100 shares. Note that if the stock price continues to rise, the trader's losses will increase, since the position is not hedged. Secondly, the trader can buy additional 100 shares in order to completely reduce the delta to zero. But if the share price falls back, the delta of the option position will again be minus 500 shares with a long position of 600 shares. Consequently, the delta of the entire portfolio will have a positive value, and the trader will again incur losses, since if the price of Google falls, the delta of the total position will increase due to the negative gamma. 
The example clearly shows that a short option position leads to losses when the price of the underlying asset fluctuates significantly. Therefore, the long option position should be profitable on significant movements in the underlying asset, provided that traded constantly rehedges delta.
Option gamma and option moneyness
The graph 1 (above) shows the relationship between the delta of a $50 call option and the price of the underlying asset. The option expiration date will be in 1 month. Note that delta is subject to higher variations when the option is atthemoney, i.e. when the delta is 0.50 or the underlying asset price is $ 50. In other words, delta is more sensitive to changes in the asset price when its value is 0.50. It follows that gamma has the greatest value when the option is atthemoney, as can be seen from Fig. 2.
In comparison, delta change is minimal when calls and puts are deep inthemoney or out of the money . The deep outofthemoney delta of a call or put option is practically zero, i.e. the probability of the option being exercised is very low. Thus, the sensitivity to asset price fluctuations will also be low. Therefore, the gamma of deep outofthemoney options is almost zero. A significant rise in the delta of a deep outofthemoney call option will require a strong rise in the price of the underlying asset, for a put option – a strong fall.
Deep inthemoney, a call option has a delta of 1, which indicates a high probability of exercise. The price of such option moves almost one to one with the price of the underlying asset. A significant change in the delta of a deepinthemoney call option would require a significant drop in the price of the underlying asset.
Gamma and date of execution
Fig. 5 depicts the relationship between the price of the underlying asset and the gamma of $50 strike options with different expiration dates. In Fig. 6, you can see that the gamma of the atthemoney call option increases as expiration approaches, while the gamma of the inthemoney and outofthemoney call options falls. Due to the small amount of time before expiration, the likelihood of nonexercise of outofthemoney and inthemoney options increases, the deltas approach zero and one (or minus 1 for a put option), respectively. To radically change the situation, a significant movement in the price of the underlying asset is required. On the other hand, the ATM option is characterized by greater uncertainty when it expires after three days, since a small fluctuation in the price of the underlying asset can strongly change the option delta, either towards zero or one (or minus 1).
Chart 5. Gamma and spot price
Chart 6. Gamma and expiration
This phenomenon of increasing gamma for atthemoney options, both calls and puts, is critical for a trader who has a short option position. The higher the gamma, the more unstable the delta. This results in more frequent delta hedging, and hence higher losses from portfolio rebalancing.
A short option position forces the trader to hedge the delta at a loss by buying and selling the underlying asset. As the share price rises, the seller of the call options must buy more and more shares in order to reduce the delta to zero. Then, if the share price falls, the trader needs to sell the purchased shares at lower prices so that the delta is zero again. On the other hand, the holder of the option (call or put) will always hedge the delta with a profit due to the positive gamma. This means that the portfolio delta will increase when the asset price rises and decrease when the asset price falls.
Then the question arises, what does the option buyer give in exchange for a positive gamma (i.e. in exchange for the right to hedge the delta with a profit)? Answer: theta. The option loses its time value as time passes (all other things being equal). Every day, the value of the option will fall (other things being equal) by the amount of theta. And if the profit from hedging the delta for that day turns out to be lower than the theta value, then the trader will eventually suffer losses. (Read also about Options Portfolio Delta and Gamma Hedging).

Delta 
Gamma 
Long call option 
+ 
+ 
Short call option 
– 
– 
Long put option 
– 
+ 
Short put option 
+ 
– 