Similar to lumberjacking, mining has its own skill bar with its own formula. With mining you are able to obtain different types of minerals the higher your skill is, and each rock provides different experience. With a higher skill in this category you will break picks less often and will be able to obtain all the gold.
Mining System

The amount of ores is also relevant in your skill level. No one wants to get half an ore per rock, but everyone wants a stack of five. How this works is as follows:

You are able to obtain one more stack for every time your current skill level reaches a multiplier for that rock. Such as a rock having 20 skill to mine, once you reach 40 skill you will have a higher chance. Similarly to a rock having 15 skill to mine, you able to obtain more if you reach 30 skill, 45, and so forth.

Once that has been determined you will always receive one ore and a chance of 50/n where n=the stacks you are bound to get.

100% for single stack
50% for a second stack
25% for a second stack
12.5% for a fourth stack
6.25% for a fifth stack