0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Σ (シグマ)、和の記号

Last updated at Posted at 2020-08-31

Σ (シグマ)

和の記号と呼ばれ、総和(合計、Summation)を表す。
ギリシャ文字の「S」を指す。
繰り返し数値を足して、合計を求める時に使用する。

\sum_{k=i}^{n} a

1.「変数[$i$]」は「変数[$k$]」の初期値
2.「変数[$k$]」が「変数[$n$]」の値になるまで「数式[$a$]」の結果を繰り返し足す

\sum_{k=i}^{n} a=\sum_{k=0}^{99} f(k)=result
int n = 99;
int i = 0;
int result = 0;
for (int k = i; k <= n; k++){
    result += f(k);
}
return result;
\sum_{k=i}^{n} a=\sum_{k=1}^{100} 10=result
int n = 100;
int i = 1;
int result = 0;
for (int k = i; k <= n; k++){
    result += 10;
}
return result;
\sum_{k=3}^{15} (k^2+k)=\sum_{k=3}^{15}k^2 +\sum_{k=3}^{15}k
int n = 15;
int i = 3;
int result = 0;
for (int k = i; k <= n; k++){
    result += (k * k) + k;
}
return result;
int n = 15;
int i = 3;
int result[2] = { 0, 0 };
for (int k = i; k <= n; k++){
    result[0] += (k * k);
}
for (int k = i; k <= n; k++){
    result[1] += k;
}
return (result[0] + result[1]);
\sum_{k=0}^{99} 2k=2\sum_{k=0}^{99}k
int n = 99;
int i = 0;
int result = 0;
for (int k = i; k <= n; k++){
    result += 2 * k;
}
return result;
int n = 99;
int i = 0;
int result = 0;
for (int k = i; k <= n; k++){
    result += k;
}
return (2 * result);

・以下のサイトを参考にさせていただきました。
C# 統計・微分積分・線形代数への道 @0kuwa

0
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?