JStarx
未讀,2012年1月28日 下午2:42:172012/1/28登入以回覆作者
登入以轉寄訊息
你的權限不足,無法在這個群組刪除訊息
登入以檢舉訊息
該群組的電子郵件地址為匿名,或你需要檢視成員電子郵件地址的權限才能查看原始貼文
收件者:sage-support
Consider the following:
sage: Q = DiGraph({1: {2:'a'}, 2: {1: 'b', 3: 'c'}, 3: {2: 'd'}})
sage: Q.all_simple_paths([1], [2])
[[1, 2], [1, 2, 3, 2]]
sage: Q.all_simple_paths([2], [1])
[[2, 1]]
First, the documentation to all_simple_paths says that a simple path
is one in which no vertex appears twice *except possibly the starting
and ending one*. This is not what I understand to be a simple path,
why the exception for the starting and ending vertex?
Second, if there indeed should be such an exception, why isn't [2, 3,
2, 1] a simple path? It appears that sage is only letting the end
vertex repeat.
-Jim Stark