I just wonder whether it is needed to put hard data (like the exact formulas for the damage), e.g: [[example about distance calculation for skill rating]]

Most of such stuff I won't remember.

Remembering the exact formulas isn't entirely necessary, but I can remember the results of such formulas and keep them in mind during combat. Using your example and the explanation of stray chance with distance, we can figure this out:

Distance | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |

Skill Rating | +3 | +2 | +1 | -0 | -0 | -0 | -0 | -1 | -1 | -1 | -2 |

Stray Distance | +0 | +0 | +0 | +0 | +1 | +1 | +1 | +1 | +2 | +2 | +2 |

Using this information, we can conclude that the ideal shooting distance is 4 tiles away, although most cases will handle okay in the 4-7 tile range (since bullet stray only happens if if roll rating beats skill rating entirely). In short, you never want enemies getting too close: far distances are more reasonable than near ones, with the best accuracy occurring at a happy medium. This is very different from DoomRL, which is the very simple "closer is better" formula.

Now, I could have simply put the table down, and astute learners could come up with formulae that imitate the results. For the time being, however, I think it's good to see everything for what it is. There's plenty of time to parse it into more meaningful tidbits.

EDIT: table fixed, thanks skarczew