I spent the last 30 minutes coming up with a mathematical formula to answer this question.

This formula only works for composers born from 1750 to 1833. This is just a general formula and does not work in all cases. For example Beethoven Hammerklavier sonata is much more difficult than this formula implies.
The total difficulty score of the composer’s work(s) in question is 1000 times the product of A, B, C, and D defined as follows:
A = 1 – (1850 – composer year of birth)/130 (example for Beethoven 1 – (1850-1770)/130 = . 0.384615385
B = How difficult is the composers music in general to play relative to his contemporaries. 1.0 means he is the most difficult composer relative to his contemporaries.
C = How difficult is the composition(s) in question relative to the composer’s most difficult work. 1.0 means the composition in question is the most difficult work of the composer.
D = How long does it take to play the composition(s) (time in hours).
Note, for values B and C, I assign the values of .95 and .9 respectively for each of the 3 composers (this is just my wild guess).
For the 4 Mozart sonatas in question (1.2 hours of music):
A = 0.276923077, B =.95, C = 0.90, D = 1.2
Total difficulty score equals 1000xAxBxCxD = 284
For the 3 Beethoven sonatas in question (1.1 hours of music):
A=0.384615385, B = 0.95, C = 0.90, D = 1.1
Total difficulty score equals 1000xAxBxCxD = 362
For the 4 Chopin Ballades in question (0.53 hours of music):
A = 0.692307692, B = 0.95, C=0.90, D=0.53
Total difficulty score equals 1000xAxBxCxD = 314
So Beethoven wins with 362 difficulty points, Chopin is second with 314 difficulty point and Mozart is easiest with 284 difficulty points.
EDIT: This formula is intended to be silly and I was hoping this was obvious. For example, if formula is used, note that parameter C of the pieces being compared need to be all fairly close to each (within .5 of each other). Otherwise you end up with extremely silly results such as playing 10 minutes of very easy Beethoven is as hard as playing 1 minute of very hard Beethoven.