A Modern and Compact Way to Formulate Classical and Advanced Beam Theories