The damage a unit does is equal to the sum of the chance of not scoring a critical hit times the unit's direct damage and the chance of a critical hit times critical hit damage (note that Direct Damage represents the Damage number that shows up on a unit's stats in the Armory):
D = Damage, DD = Direct Damage CD = Critical Hit Damage CC = Critical Chance
 Damage = (1-CC)* + CC*CD
Damage per second is a more useful statistic because it incorporates rate of fire. For a simpler calculation, we will use a shots per second variable, F.
DPS = Damage per second F = 1 / Rate of Fire
 DPS = * D
Substituting to  into  gives:
 DPS = * [ (1-)* + * ]
When analyzing the effects of mods, formula  may need to be broken down further. The following mods types are accounted for: ammo (flat damage bonus), armament (percentage damage bonus), impact (critical hit damage bonus), and precision (critical hit chance bonus).
Direct damage is affected by the unit's base damage and any percentage damage increase or flat damage bonuses.
BD = Base Damage (the unit's direct damage with no mods) BDm = Base Damage modifier (from armament mods) BDf = Base Damage flat increase (from ammo mods)
Critical Hit Damage is based on a unit's Direct Damage and is further Critical Hit Damage Bonus modifiers.
CDm = Critical Hit Damage modifier (impact mods)
 = *
Critical Hit Chance is affected by a unit's base critical hit chance and it's critical hit chance modifier
CCb = Base critical hit chance (unit's critical hit chance with no mods equipped) CCm = Critical Hit Chance modifier (precision mods)
Substituting  into the original DPS formula  yields:
 DPS = * [ (1-)* + * * ]
This can be simplified with the following steps:
 DPS = * * [ (1-) + * ]
 DPS = * * [ 1 - + 1.5 + * CDm ]
 DPS = * * [ 1 + 0.5 + * CDm ]
 DPS = * * [ 1 + * ( 0.5 + CDm ) ]
Substituting in  and  into  gives:
 DPS = * * [ 1 + * ( 0.5 + CDm ) ]
For units that have area of effect damage and can hit multiple units at once, you will need to factor in on average how many units it will hit.
AH = Average number of units hit per shot
 DPS = * * [ 1 + * ( 0.5 + CDm ) ] * AH
An easy shortcut to figuring out a unit's damage is to actually look at the unit in game in the armory and add in the mods you want to test out. This way, you will not need to worry about the specific variables BDm, BDf, CCb, CCm, or CDm in  above. Take the Damage, Critical Hit Chance, and Critical Hit Damage numbers from a unit's armory stats and plug them into this formula:
 DPS = * [ (1-)* + * ] * AH
A simple example of the damage calculation can be done using a Base Damage (BD) of 100 and Critical hit Chance base (CCb) of .1 (10%). For the sake of simplicity (and if comparing two identincal units) the Fire rate and Average number of units hit per shot are removed from the formulas.
Base Damage (BDm/ BDf) increase of 10%; DPS = 115.5
Critical hit Chance (CCm) increase of 21% (base of 10%); DPS = 115.5
Critical Damage Bonus (CDm) of 105% (base of 150%); DPS =115.5
Base Damage modifier calculations
For the sake of a simple calculation assume the Direct Damage (DD) after mods will be 110, which means there is a Base Damage mod (BDm) of .1 (10%) or a Base Damage flat increase of 10 or some combination of the two. As such, the initial calculation formulas looks like:
DD= 100 + 100 *.1 = 110
CD=DD* 1.5 = 110 *1.5 = 165
DPS = (1-CC) *DD+CC*CD= (1-.1) * 110 + .1 * 165 = 99 + 16.5 = 115.5
So with a Base Damage (BD) increase of 10%, the final DPS is 115.5, not to shabby.
Comparing Critical Hit Chance and Critical Damage Bonus modifiers
Increasing the base damage by 10% gave us a DPS increase of 15.5%, but increasing the base damage is not our only option. Calculations for an equivalent Critical Hit Chance modifier and Critical hit Damage modifier with a Critical hit Chance base (CCb) of .1 (10%) are as follow:
Equivalent Critical Hit Chance modifier (CCm) for 10% Base damage increase (DPS = 115.5,DD= 100,CD= 150):
115.5 = [(1-CC) * 100] + [CC* 150] = 100 - 100 *CC+ 150 *CC= 100 + 50 *CC
15.5 = 50 *CC
.31 =CC= .1 +CCm
Thus a 21% Critical hit Chance mod (CCm) is equal to a 10% Base Damage modificiation for final DPS.
Equivalent Critical hit Damage modifier (CDm) for 10% Base damage increase (DPS = 115.5,DD= 100,CC= .1):
115.5 = (.9 * 100) + (.1 *CD) = 90 + .1 *CD= 90 + .1 * [100 * (1.5 +CDm)] = 90 + 15 +10*CDm= 105 + 10*CDm
10.5 = 10 *CDm
As calculated, a Critical hit Damage modifier of (CDm) 105% is equal to a 10% Base Damage modification for final DPS.
Results (minus the math) if the the base Critical Hit Chance was .01 (1%):
Base Damage (BDm/ BDf) increase of 10%; DPS = 110.55
Critical hit Chance (CCm) increase of 20.1% (base of 1% Crit hit chance); DPS =110.55
Critical Damage Bonus (CDm) of 1005% (base of 150% normal damage); DPS =110.55