Go by UV index.
UV index weights the total emmision from 280nm - 319nm at 99% weight and the rest (320nm-400nm) at less than 1%. So UVI is most influenced by UVB.
A UVI of 10.0 means there is 250mW/m2 of erythemally weighted emissions. 250mW is the figure they got when they added up all the emissions from 280nm-319nm and weighted each individual WV at 1-99% with 280nm being 100% and 319nm being 1%, and then added up all the 320nm-400nm emissions and weighted each individual WV with a max weighting of less than 1%, equating 320nm to the highest weighted nm in that range (320-400) but at less than 1%, and then equating 400nm to the lowest weight% at 0%. The total between all the weighted sums is 250mW erythemal or a 10.0 UVI day. They use an arbitrary 25mW/m2 to divide the total erythemally weighted emissions by, to give a nice easy fugue to use. So 250mW/m2 ÷ 25mW/m2 is 10, or a UVI of 10.0.
EDIT:
2 hrs under a 10.0 UVI equals...
1mW = 0.001W
1mJ = 0.001J
W = J/s
mW = mJ/s
hr = 3600s
10.0 UVI × 25mW/m2
=
250mW/m2 erythemally weighted emissions
Then..
[(250mW)·(2hrs)] × {[(mJ/s)·(1/mW)] × (0.001J/1mJ) × (3,600sec/1hr)}
=
(250)·(2)·(0.001)·(3,600)·mW·hr·mJ·sec·J
________________________________________
(1)·mW·hr·mJ·sec
=
1,800J
{...} conversion factor for future calcs...
(3,600)·(0.001)·mJ·sec·J
________________________
(1)·mJ·sec·mW·hr
=
3.6J/(mW·hr)
In a nutshell...
Multiply any UVI by 25mW/m2, then by the duration of hrs exposed, and then finally by a conversion factor of 3.6 to calculate total erythemal doseage in J per m2, or use a conversion factor of 0.0036 to calculate total erythemal doseage in kJ per m2.
(10.0)UVI × (25)mW/m2 × (2)hrs × (3.6)
=
1,800J/m2
Or...
(10.0)UVI × (25)mW/m2 × (2)hrs × (0.0036)
=
1.8kJ/m2 total dose