Heres how I see the damage.
If you go 40/0/21 and use your 3 dots, then SB youll get 4-5 shadow bolts (Ill assume 4).
If you go 41/0/20 and use 4 dots, you get 3-4 (Ill assume 3) shadow bolts off before having to re apply.
Now you have a 16% chance of your SB hitting for 50% more. If we ignore ISB since it effects all shadow damage now then youre SB should be hitting for around 1600 for a normal hit, and 3200 for a crit.
Since you only have 16% crit, you can say that only 16% of that extra crit damage can be applied over each shadow bolt. So 16% of your extra 1600, then each bolt will be worth ~1860 on average
Youll be able to get 1 more SB cause youre not casting UA plus the extra damage from each from the higher crit. So overall youll do 1860+4*(1860-1600) = ~2625 more damage with Ruin.
With UA and its 120% coefficient, you will do 1050+900*1.2 = 2130 extra damage, plus the extra 16% of the 800 (1600/2) damage from a crit adds another 384 damage to that for a total of ~2514. So it looks like maybe ruin will do more damage but my calculations could be off (They probably are...) More chances for ISB and better trash damage might make that an even better choice.
Hmm, I gotta say when I started looking at the numbers I expected to see it the other way. Am I missing something here?