ramified theory of types