传统形式语言的语义建模方法在语义解释与规则描述等语义计算方面存在不足,应用范畴论方法的Monads对形式语言的语义计算进行了研究.基于Monads构造Kleisli范畴,在Kleisli范畴的形式化框架内建立语义计算模型,并对该模型进行了应用.与传统语义建模方法相比,所提语义计算模型具有普适性,其语义解释与规则描述的能力更强.%Traditional semantics modelling methods of formal languages have some drawbacks to interpret semantics and describe rule,and this paper explored semantics computation of formal languages by monads which is categorical method.It firstly constructed Kleisli category by monads,presented a semantics computational model in the formal framework of Kleisli category,and then applied it by example.Compared with traditional semantics modelling methods,the semantics computational model presented by this paper is universal and has more strong abilities of semantics interpreting and rule descripting.
展开▼