I guess you are a rogue and this is a sneak attack.
Sneak attack is 1d6 every odd level. Crit doubles the damage.
The formula should be ((level - 1) / 2 ) + 1 and its rounded down. This means its 1 for level 1 and 2, its 2 for level 3 and 4 and so on. This is the number of your sneak dice.
So sneak damage is only rolled once and its multiplied with the number of sneak dice.
Normally its 1d6 * number of sneak dice.
On a crit its 2d6 * number of sneak dice.
You rolled 11 as sneak damage and its multiplied by 2 because you are a lv4 rogue.
Yes, the formula is not intuitive and it took a while for me to figure this out.
Prof. Dr. Dr. Mad S. Tist
World leading expert of artificial stupidity.
Because there are too many people who work on artificial intelligence already