Chapter 0: What is Cyclone ?

Introduction - A Classic Graph Problem

What is Cyclone? What can it do? Before revealing all features about Cyclone, let's begin with a classic and commonly known problem in graph theory.

In graph theory, a Hamiltonian path problem is about deciding/finding whether a (directed/undirected) graph contains a Hamiltonian path.

So what is a Hamiltonian path?

Here is an informal explanation, a Hamiltonian path is a path that covers all the vertices of a graph exactly once.

Finding a Hamiltonian path in a graph is challenging. In fact, it is NP-complete and this means we can verify the correctness of a solution quickly but takes much more time (than verifying a solution) to find a solution.

For example, does the following graph have a Hamiltonian path? If it has, how many does it have ?

Well, you could write a brute-force search algorithm to find all solutions to the condition: covers all the vertices of a graph exactly once. However, what happens if we have another graph with different conditions to be met such as a path must include multiple cycles or even for some nodes or edges (not) to be appeared a number of time. You certainly don't want to write a new algorithm every time when a condition is added, changed or removed. More importantly, how can you ensure the correctness of your algorithms.

In our daily life, many problems can be represented as a graph such as a puzzle, a computer program or a free-falling ball.

Cyclone is designed to provide a general solution to problems that can be described as a graph. Cyclone provides a specification language that allows users to describe a graphical structure along with conditions to be met and automatically solves them for you. More importantly, as long as conditions are correctly specified the correctness of returned solutions are ensured. Problems like finding Hamiltonian path in the graph above can be easily turned into a Cyclone specification and solved by Cyclone's powerful algorithms. We will come back to this problem in a later Section.

Want to try Cyclone? just click Here >

Wanna learn Cyclone? just click Start >

For quick reference of Cyclone specification language, click Here >

 

 

Watch out, Cyclone is on its way...


中文版:Cyclone(飓风) - 教程-启蒙篇:零

Cyclone(飓风)到底是什么东西? 它可以干嘛? 在揭开Cyclone所有的功能之前,让我们先来看一道图论中的经典问题。

一个经典的图论问题

哈密顿路径问题: 确定在一个给定的图上是否存在哈密顿路径

那么到底什么是哈密顿路径呢? 非正式的来说就是:我们在图中需要寻找一条路径能遍历图中每个节点且每个节点只能遍历一次。

在给定一个图中寻找这么一条路径并不是一件容易的事情。特别是当图的规模变的很大时。比如:你能否确定下图中是否存在哈密顿路径?如果有,有多少个?

事实上搜索一个图是否包含哈密顿路径这个问题为NP完备。这就意味着假设我们已经知道一个解,我们可以在很短的时间内验证它的正确性。 但是要找到这么一个解却需要花费比验证所花费大的多的时间。

当然你可以很容易的给出一个暴力搜索算法来解决哈密顿路径问题。但是,如果我们换了一个图和条件。比如:寻找一个路径包含一个特定的环并且一些节点和边或者遍历一些节点2次而另一些3次呢? 你当然不想每一次都重新写一个算法来针对新的,改动或者被移除的条件。这样繁琐又耗时,即使写出来也不能保证算法的正确性。

现实生活中的许多问题其实都可以用图的形式来表示。比如:一个有意思的猜谜游戏,一段代码或者一个正在自由落体的物体。

Cyclone(飓风)致力于为那些可用图来描述的问题提供一个通用的解决方案。Cyclone(飓风)提供了一种全新的规范语言,用户可以使用图来描述所要解决的问题, Cyclone(飓风)会自动根据问题的描述给出答案。Cyclone (飓风) 提供一种强大的归约机制能有效的解决基于图形结构的约束条件。比如:寻找上图中的哈密顿路径问题或者验证一段代码的正确性 都可以非常容易用Cyclone(飓风)的语言来描述并解决。 我们会在稍后的章节中给出如何用Cyclone(飓风)来解决这个问题。

是不是很有意思? 想下载Cyclone请点击 这里 >

想学习如何使用Cyclone(飓风)吗?请点击 开始 >

想要快速了解Cyclone(飓风)的语言特性点击 这里 >

 

 

敬请期待强大的Cyclone (飓风)的到来...


@2020-2022 Hao Wu. All rights reserved. Last update: January 29, 2022