Skip to content

Improve documents #185

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

Merged
merged 3 commits into from
Apr 19, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion document_en/fenwicktree.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Fenwick Tree

Given an array of length $N$, it processes the following queries in $O(\log N)$ time.
Given an array of length $n$, it processes the following queries in $O(\log n)$ time.

- Updating an element
- Calculating the sum of the elements of an interval
Expand Down
2 changes: 1 addition & 1 deletion document_en/mincostflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ Let $g$ be a function such that $g(x)$ is the cost of the minimum cost $s-t$ flo
It returns $g$ as the list of the changepoints, that satisfies the followings.

- The first element of the list is $(0, 0)$.
- Both of `.first` and `.second` are strictly increasing.
- `.first` is strictly increasing and `.second` is non-decreasing.
- No three changepoints are on the same line.
- (1) The last element of the list is $(x, g(x))$, where $x$ is the maximum amount of the $s-t$ flow.
- (2) The last element of the list is $(y, g(y))$, where $y = \min(x, \mathrm{flow\\_limit})$.
Expand Down
2 changes: 1 addition & 1 deletion document_en/segtree.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ It is the data structure for [monoids](https://en.wikipedia.org/wiki/Monoid) $(S
- associativity: $(a \cdot b) \cdot c$ = $a \cdot (b \cdot c)$ for all $a, b, c \in S$
- existence of the identity element: $a \cdot e$ = $e \cdot a$ = $a$ for all $a \in S$

Given an array $S$ of length $N$, it processes the following queries in $O(\log N)$ time (see [Appendix](./appendix.html) for further details).
Given an array $S$ of length $n$, it processes the following queries in $O(\log n)$ time (see [Appendix](./appendix.html) for further details).

- Updating an element
- Calculating the product of the elements of an interval
Expand Down
4 changes: 2 additions & 2 deletions document_ja/fenwicktree.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# Fenwick Tree

長さ $N$ の配列に対し、
長さ $n$ の配列に対し、

- 要素の $1$ 点変更
- 区間の要素の総和

を $O(\log N)$ で求めることが出来るデータ構造です。
を $O(\log n)$ で求めることが出来るデータ構造です。

## コンストラクタ

Expand Down
2 changes: 1 addition & 1 deletion document_ja/mincostflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ vector<pair<Cap, Cost>> graph.slope(int s, int t, Cap flow_limit);
返り値に流量とコストの関係の折れ線が入る。全ての $x$ について、流量 $x$ の時の最小コストを $g(x)$ とすると、$(x, g(x))$ は返り値を折れ線として見たものに含まれる。

- 返り値の最初の要素は $(0, 0)$
- 返り値の`.first`、`.second`は共に狭義単調増加
- 返り値の`.first` は狭義単調増加、`.second`は広義単調増加
- 3点が同一線上にあることはない
- (1) 返り値の最後の要素は最大流量 $x$ として $(x, g(x))$
- (2) 返り値の最後の要素は $y = \min(x, \mathrm{flow\\_limit})$ として $(y, g(y))$
Expand Down
4 changes: 2 additions & 2 deletions document_ja/segtree.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@

を満たす代数構造に対し使用できるデータ構造です。

長さ $N$ の $S$ の配列に対し、
長さ $n$ の $S$ の配列に対し、

- 要素の $1$ 点変更
- 区間の要素の総積の取得

を $O(\log N)$ で行うことが出来ます。詳細な要件は [Appendix](./appendix.html) を参照してください。
を $O(\log n)$ で行うことが出来ます。詳細な要件は [Appendix](./appendix.html) を参照してください。

また、このライブラリはオラクルとして`op, e`の2種類を使用しますが、これらが定数時間で動くものと仮定したときの計算量を記述します。オラクル内部の計算量が $O(f(n))$ である場合はすべての計算量が $O(f(n))$ 倍となります。

Expand Down
Loading