检索规则说明:AND代表“并且”;OR代表“或者”;NOT代表“不包含”;(注意必须大写,运算符两边需空一格)
检 索 范 例 :范例一: (K=图书馆学 OR K=情报学) AND A=范并思 范例二:J=计算机应用与软件 AND (U=C++ OR U=Basic) NOT M=Visual
机构地区:[1]华南理工大学计算机科学与工程学院,广州510640 [2]中山大学信息科学与技术学院,广州510275
出 处:《计算机科学》2011年第7期144-147,156,共5页Computer Science
基 金:2010年高校博士点科研基金-新教师类(20100172120043);华南理工大学中央高校基本科研业务费专项资金(2009ZM0158)资助
摘 要:函数式程序语言Haskell中的Monads理论在描述上下文依赖计算等方面存在一定的不足。作为Monads的范畴论对偶概念,Comonads理论可以有效地提高Haskell对上下文依赖计算的描述能力。首先给出Comonads的范畴论定义和性质,以及Comonads在Haskell的具体实现;接着探讨Comonads的CoKleisli三元组和CoKleisli范畴,通过实例说明如何将其应用于上下文依赖计算的描述和推理中;最后进一步研究Comonads与Monads之间的分配律,指出如何通过分配律将效果计算与上下文依赖计算有机地融合起来。Monad theory in functional programming language Haskell has some disadvantages in describing the context dependent computations.As the categorical dual notion of monads,comonad theory can effectively improve Haskell's description ability of context-dependent computations.Firstly,we gave the categorical definitions and properties of Comonads,as well as their implementations in Haskell.Secondly,we discussed the CoKleisli triple and CoKleisli category,and used some examples to demonstrate how to apply them into the descriptions and reasoning of context dependent computations.Finally,we also discussed the distributive laws between Comonads and Monads,and showed its uses in merging the effectful computations and context dependent computations.
关 键 词:Comonads 函数式程序语言 HASKELL 上下文依赖计算 范畴论
分 类 号:TP301.2[自动化与计算机技术—计算机系统结构]
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在载入数据...
正在链接到云南高校图书馆文献保障联盟下载...
云南高校图书馆联盟文献共享服务平台 版权所有©
您的IP:216.73.216.244