用 F# 编写的有限自动机库

发布于 2024-09-15 00:38:11 字数 1536 浏览 3 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

打小就很酷 2024-09-22 00:38:11

我的第一个想法是使用状态机 monad,它已被博客/编写/讨论/生成多次,下面是一些参考文献。

http://fsharpcode。 blogspot.com/2008/12/f-state-monad-type-state-state-state-of.html
http: //codebetter.com/blogs/matthew.podwysocki/archive/2009/12/30/much-ado-about-monads-state-edition.aspx

虽然这不会给你你想要的翻译.. 。
可能是一个起点。

My first thought would be to use the state machine monad, which has be blogged/written/discussed/produced several times, a couple of references are below.

http://fsharpcode.blogspot.com/2008/12/f-state-monad-type-state-state-state-of.html
http://codebetter.com/blogs/matthew.podwysocki/archive/2009/12/30/much-ado-about-monads-state-edition.aspx

although this doesn't give you the translations you want...
Might be a place to start.

友谊不毕业 2024-09-22 00:38:11

可能不是您正在寻找的东西,但让 FA 工作的一种快速而肮脏的方法是为您的 FA 编写等效的上下文无关语法,然后使用 fsyacc

Probably not what you are looking for but a quick and dirty way to get some FA things working would be to write an equivalent context free grammar for your FA then using fsyacc?

给不了的爱 2024-09-22 00:38:11

Jolt.NET

它不能满足您的所有要求:它是用C#编写的,并且似乎不支持转换为DFA或最小化。至少它可以在 F# 中使用并且可以用作起点。我自己从未使用过它,所以我不能保证它的适用性或质量。

另请参阅C# 中的 NFA/DFA 实现

Jolt.NET

It does not fulfil all your requirements: It's in C#, and it does not seem to support translation to DFA or minimization. At least it's usable from F# and could be used as a starting point. I've never used it myself, so I can't vouch for its suitability or quality.

See also NFA/DFA implementation in C#

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文