Math, Where are the static types?
While most new (and old) programming languages are typed, Traditional math does not have types.
Optimization - Different Objective
Math notation has no runtime, optimization does not come in the form of performance, but as formula simplification,
In a computer setting, the second formula is much faster than the first formula,
Formula 1 has a time complexity of O(n),
Formula 2 has a time complexity of O(1).
In Pure Math, Above formulas do not “Run”, and so its a matter of simplification, not optimization.
In addition, numbers have no “size”, while the default integer size in programs is 64 bits (base 2),
the integer size in math is virtually infinite (base 10).
A Math Statement Is Mostly Immutable
Programs have bugs and users,
Bugs need to be fixed,
And user-requested features may be implemented.
Programs are meant to be mutable for life, while math statements, are mutable until proven true.
on average, a traditional program is a lot longer than a math paper.
Python - A Case Study
Most research and prototyping is done in Python,
Dynamic typing has been a primary factor for Python’s success, It allowed effortless prototyping with the expense of long term technical debt.
by default, Python has no types, but in recent years, as python is used more-and-more in production, typed Python, or mypy, has gained significant traction.
As of today, most Python libraries are typed, and large programs are also.