A theory of Lending Protocols in DeFi | Synapse