Design of a circular shaft subject to Torsion and Bending

This piece of Java Script uses two failure theories to determine the required shaft diameter to withstand the specified bending moment and torque for the material ultimate strength (UTS) and design factor (factor of safety) entered in the boxes below.

NB No account is taken of any stress concentration here, an appropriate design factor must be entered.

Theories used are:

The maximum shear stress theory (Trseca)
The maximum distortion energy theory (von Mises)
Bending moment, Nm:
Torque, Nm:
UTS MPa:
Design Factor:

Calculate the required diameter according to

: Answer,  d = [mm]

:  Answer,  d =  [mm]

Further reading - 'Mechanical Engineering Design', by J E Shigley ...