-
Notifications
You must be signed in to change notification settings - Fork 12
最大流問題や最小カット問題などについて記事を足す #140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
kmyk
wants to merge
17
commits into
gh-pages
Choose a base branch
from
max-flows
base: gh-pages
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
830c6ed
画像ファイルについて準備しておく
kmyk 8e7647e
最大流問題の記事の下書きを追加する
kmyk 939b6c8
「燃やす埋める問題」「project selection problem」を独立したページにする
kmyk 72a04da
劣モジュラ関数まわりの記事の内容を確認した
kmyk a7b0dfa
カットの定義に 2 種類ある話のまわりを更新する
kmyk e238ccd
lint が落ちたので修正する
kmyk 0bebc77
project selection problem の出典についての TODO を削除する
kmyk 0cf9a30
カットの定義に 3 種類あることをきちんと説明する
kmyk 7864a12
カットを頂点集合で定義するときの記号を A ⊆ V でなく S ⊆ V にする
kmyk 04a9665
リンクが壊れていたので修正する
kmyk 7b593e3
最小カット問題関連の記事の細部を調整する
kmyk f84a44b
「最大流」でなく「最大フロー」で統一する
kmyk a8a1488
"s-t disconnecting" ではなく "s-t disconnecting edge set"
kmyk ec17ece
project selection problem のネットワークの図を修正する
kmyk 0f45a6e
typo: "problem selection problem" ではない
kmyk f391590
「という別の」という句は不自然なので削除
kmyk d6e4a1d
s/みっつ/3 種類/
kmyk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
--- | ||
layout: entry | ||
changelog: | ||
- summary: 記事作成 | ||
authors: kimiyuki | ||
reviewers: | ||
date: 2021-04-01T00:00:00+09:00 | ||
algorithm: | ||
input: | ||
output: | ||
time_complexity: | ||
space_complexity: | ||
aliases: ["最大流問題", "maximum flow problem"] | ||
level: blue | ||
description: > | ||
最大フロー問題とは、与えられたネットワークのフローであって流量が最大のものを求めるという問題。 | ||
最大フロー最小カット定理によって最大フロー問題の解の流量は最小カット問題の解の容量に等しい。 | ||
--- | ||
|
||
# 最大フロー問題 | ||
|
||
## 概要 | ||
|
||
最大フロー問題とは、与えられたネットワークのフローであって流量が最大のものを求めるという問題である。 | ||
最大フロー最小カット定理によって最大フロー問題の解の流量は[最小カット問題](/minimum-cut-problem)の解の容量に等しい。 | ||
|
||
|
||
## 詳細 | ||
|
||
(省略) | ||
|
||
|
||
## その他 | ||
|
||
- フローの定義では「始点から終点へと向かうフローと無関係な位置に閉路状のフローがないこと」は要求されていない。最大フローを求めるアルゴリズムはこのような閉路状のフローを含む出力をすることがあるので、出力されたフローの構成を利用する際には注意が必要である。なお、最大フロー問題の解から流量を変えずにこのような閉路状のフローを取り除くことは常に可能である。 | ||
|
||
|
||
## 関連項目 | ||
|
||
- [最小カット問題](/minimum-cut-problem) | ||
- 最大フロー最小カット定理によって最大フロー問題の解の流量は最小カット問題の解の容量に等しい。 | ||
- [Dinic 法](/dinic) | ||
- Dinic 法は最大フロー問題を解くアルゴリズムである。最悪計算量は $O(\lvert V \rvert^2 \cdot \lvert E \rvert)$ だが実用的にはかなり速い。 | ||
- [Ford-Fulkerson 法](/ford-fulkerson) | ||
- Ford-Fulkerson 法は最大フロー問題を $O(F \cdot \lvert E \rvert)$ で解く代表的なアルゴリズムである。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
--- | ||
layout: entry | ||
changelog: | ||
- summary: 記事作成 | ||
authors: kimiyuki | ||
reviewers: | ||
date: 2021-04-01T00:00:00+09:00 | ||
algorithm: | ||
input: | ||
output: | ||
time_complexity: | ||
space_complexity: | ||
aliases: ["minimum cut problem"] | ||
level: blue | ||
description: > | ||
最小カット問題とは、与えられたネットワークのカットであって容量が最小のものを求めるという問題。 | ||
最大フロー最小カット定理によって最小カット問題の解の容量は最大フロー問題の解の流量に等しい。 | ||
--- | ||
|
||
# 最小カット問題 | ||
|
||
## 概要 | ||
|
||
最小カット問題とは、与えられたネットワークのカットであって容量が最小のものを求めるという問題である。 | ||
最大フロー最小カット定理によって最小カット問題の解の容量は[最大フロー問題](/maximum-flow-problem)の解の流量に等しい。 | ||
|
||
|
||
## カットの定義 | ||
|
||
与えられたネットワークの $s$-$t$ カットの定義としては、大きく分けて以下の 3 種類がある。 | ||
|
||
1. 有向辺の部分集合 $C \subseteq E$ であってどの $s$-$t$ パスも $C$ に含まれるような有向辺を含むもの[^cut-set-of-edges] | ||
2. 頂点の部分集合 $S \subseteq V$ であって $s \in S$ かつ $t \in V \setminus S$ なもの[^cut-set-of-vertices] | ||
3. 有向辺の部分集合 $C \subseteq E$ であって、次を満たすもの: ある頂点の部分集合 $S \subseteq V$ であって $s \in S$ かつ $t \in V \setminus S$ なものが存在し、$S$ に含まれる頂点から $V \setminus S$ に含まれる頂点への有向辺の全体が $C$ に等しい[^cut-set-of-vertices-as-edges] | ||
|
||
カットの容量は、(1.) と (3.) の定義の場合は $C$ に含まれる有向辺の重みの総和として定義される。 | ||
(2.) の定義の場合は始点が $S$ に含まれかつ終点が $V \setminus S$ に含まれるような有向辺の重みの総和として定義される。 | ||
|
||
最小カット問題を考える際にはどの定義を用いても解の容量は同じであるが、カットの定義としてはすべて異なるものである。 | ||
(1.) の定義と (2.) の定義との違いはカットの容量の最大値について考えれば明らかである。 | ||
(2.) の定義と (3.) の定義とはほとんど同じものであるが、ネットワークが非連結な場合に異なってくる。 | ||
(1.) で定義されるものを (2.) や (3.) で定義されるものから区別したいときには、(1.) で定義されるものを $s$-$t$ 非連結化集合 ($s$-$t$ disconnecting edge set) と呼ぶことがある[^s-t-disconnecting-edge-set]。 | ||
|
||
|
||
## 関連項目 | ||
|
||
- [最大フロー問題](/maximum-flow-problem) | ||
- 最大フロー最小カット定理によって最小カット問題の解の容量は最大フロー問題の解の流量に等しい。 | ||
- [燃やす埋める問題](/moyasu-umeru-mondai) | ||
- 燃やす埋める問題は最小カット問題へと帰着できる。 | ||
- [project selection problem](/project-selection-problem) | ||
- project selection problem は最小カット問題へと帰着できる。 | ||
|
||
|
||
## 外部リンク | ||
|
||
- [最小カットについて - よすぽの日記](https://yosupo.hatenablog.com/entry/2015/03/31/134336)<sup>[archive.org](https://web.archive.org/web/20210401023012/https://yosupo.hatenablog.com/entry/2015/03/31/134336)</sup> | ||
- <a class="handle">yosupo</a> によるブログ記事。最小カット問題はグラフの $2$ 彩色だと思うとよいことが説明されている。 | ||
- [最小カット問題と充足最大化問題 - うさぎ小屋](https://kimiyuki.net/blog/2020/03/07/minimum-cut-and-maximum-satisfiability/)<sup>[archive.org](https://web.archive.org/web/20210401023109/https://kimiyuki.net/blog/2020/03/07/minimum-cut-and-maximum-satisfiability/)</sup> | ||
- <a class="handle">kimiyuki</a> によるブログ記事。最小カット問題は $\bigvee\mkern-12.5mu\bigvee _ i p_i \to \bigwedge\mkern-12.5mu\bigwedge _ j q_j$ の形の論理式たちの充足最大化問題と見ることができると主張している。 | ||
- [燃やす埋める問題と劣モジュラ関数のグラフ表現可能性 その① - 私と理論](https://theory-and-me.hatenablog.com/entry/2020/03/13/180935)<sup>[archive.org](https://web.archive.org/web/20210401023205/https://theory-and-me.hatenablog.com/entry/2020/03/13/180935)</sup>, [燃やす埋める問題と劣モジュラ関数のグラフ表現可能性 その② グラフ構築編 - 私と理論](https://theory-and-me.hatenablog.com/entry/2020/03/17/180157)<sup>[archive.org](https://web.archive.org/web/20210401023147/https://theory-and-me.hatenablog.com/entry/2020/03/17/180157)</sup> | ||
- <a class="handle">theory_and_me</a> によるブログ記事。$3$ 変数までの劣モジュラ関数の和 $\sum_i \theta_i(x_i) + \sum _ {i \lt j} \phi _ {i, j} (x_i, x_j) + \sum _ {i \lt j \lt k} \psi _ {i, j, k} (x_i, x_j, x_k)$ で表される関数の最小化問題は最小カット問題に帰着できることを説明している。 | ||
- [燃やす埋める問題を完全に理解した話 - koyumeishiのブログ](https://koyumeishi.hatenablog.com/entry/2021/01/14/052223)<sup>[archive.org](https://web.archive.org/web/20210401023419/https://koyumeishi.hatenablog.com/entry/2021/01/14/052223)</sup> | ||
- <a class="handle">koyumeishi</a> によるブログ記事。$2$ 変数間の制約からグラフ表現可能な劣モジュラ関数を自動導出するライブラリを提案している。 | ||
|
||
|
||
## 注釈 | ||
|
||
[^moyasu-umeru-local-name]: 競技プログラミングのコミュニティ外では通用しない名前であることに注意したい。 | ||
[^cut-set-of-edges]: たとえば R. J. ウィルソン. グラフ理論入門. 近代科学社, 2001, [ISBN978-4-76-490296-1](https://iss.ndl.go.jp/api/openurl?isbn=9784764902961). | ||
[^cut-set-of-vertices]: たとえば R. Diestel, [Graph Theory](https://www.springer.com/jp/book/9783662536216), 5th ed. Berlin Heidelberg: Springer-Verlag, 2017. | ||
[^cut-set-of-vertices-as-edges]: たとえば Schrijver, A. [Combinatorial Optimization: Polyhedra and Efficiency](https://www.springer.com/jp/book/9783540443896), Springer Science & Business Media, 2003. | ||
[^s-t-disconnecting-edge-set]: たとえば Schrijver, A. [Combinatorial Optimization: Polyhedra and Efficiency](https://www.springer.com/jp/book/9783540443896), Springer Science & Business Media, 2003. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
「異なる」が曖昧な気がしていて、もうちょっと具体的に「一般には多対一対応になる」みたいな書き方のほうがよい気がします。あと、有向なので、非連結でなくても多対一になる場合がって、例えば u は接続する辺が (u, s) のみのとき、2. では区別出来る「u が s 側に属するか否か」が 3. では区別できません。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
これも自分のミスです、申し訳ない...