Formalisation of logic