回答編集履歴
3
Update
test
CHANGED
@@ -62,7 +62,7 @@
|
|
62
62
|
|
63
63
|
|
64
64
|
|
65
|
-
以下の環境での実行時間は `N = 1e+7` で `0.66±0.2` 秒程度になりました(`timeit` モジュールを利用して計測)。
|
65
|
+
以下の環境での実行時間は `N = 1e+7` で `0.66±0.02` 秒程度になりました(`timeit` モジュールを利用して計測)。
|
66
66
|
|
67
67
|
```sh
|
68
68
|
|
2
Update
test
CHANGED
@@ -19,6 +19,8 @@
|
|
19
19
|
orbit = rg.uniform(*num_range, M)
|
20
20
|
|
21
21
|
|
22
|
+
|
23
|
+
orbit_org = orbit.copy()
|
22
24
|
|
23
25
|
orbit.sort()
|
24
26
|
|
1
Update
test
CHANGED
@@ -40,8 +40,6 @@
|
|
40
40
|
|
41
41
|
print(ratio)
|
42
42
|
|
43
|
-
|
44
|
-
|
45
43
|
#
|
46
44
|
|
47
45
|
[0.63314754 0.63316065 0.6325016 0.63304742 0.6318326 0.63409262
|
@@ -54,28 +52,42 @@
|
|
54
52
|
|
55
53
|
0.63252976 0.63157 0.63182343 0.63087606 0.63256839 0.6310312
|
56
54
|
|
57
|
-
|
55
|
+
:
|
58
56
|
|
59
|
-
0.63206805 0.63288187 0.63120482 0.63212706 0.63274749 0.63402672
|
60
|
-
|
61
|
-
0.63364018 0.63112059 0.63156005 0.63327901 0.63140728 0.63146173
|
62
|
-
|
63
|
-
0.6311587 0.63168948 0.63176906 0.63185224 0.63264017 0.63252129
|
64
|
-
|
65
|
-
0.63105783 0.63270842 0.63198682 0.63040526 0.63040611 0.63211661
|
66
|
-
|
67
|
-
0.63182223 0.63224523 0.6316447 0.63094144 0.6314832 0.63239629
|
68
|
-
|
69
|
-
0.63079837 0.6319649 0.63396299 0.63135619 0.631374 0.63106621
|
70
|
-
|
71
|
-
0.62994967 0.63206983 0.6333817 0.62947686 0.63216941 0.63327899
|
72
|
-
|
73
|
-
0.63219069 0.63352638 0.63068507 0.63261416 0.63156 0.6311749
|
74
|
-
|
75
|
-
0.63159209 0.62994582 0.63210173 0.63382665 0.63166554 0.63240191
|
76
|
-
|
77
|
-
0.63148091 0.6299639 0.63219558 0.6326104 0.63466182 0.63252711
|
78
|
-
|
79
|
-
|
57
|
+
:
|
80
58
|
|
81
59
|
```
|
60
|
+
|
61
|
+
|
62
|
+
|
63
|
+
以下の環境での実行時間は `N = 1e+7` で `0.66±0.2` 秒程度になりました(`timeit` モジュールを利用して計測)。
|
64
|
+
|
65
|
+
```sh
|
66
|
+
|
67
|
+
$ lscpu | grep -E '^(Architecture|Model name)'
|
68
|
+
|
69
|
+
Architecture: x86_64
|
70
|
+
|
71
|
+
Model name: Intel(R) Core(TM) i5-8500T CPU @ 2.10GHz
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
$ lsb_release -ir
|
76
|
+
|
77
|
+
Distributor ID: Ubuntu
|
78
|
+
|
79
|
+
Release: 21.04
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
$ python3 --version
|
84
|
+
|
85
|
+
Python 3.9.5
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
$ python3 -c 'import numpy;print(numpy.__version__)'
|
90
|
+
|
91
|
+
1.21.4
|
92
|
+
|
93
|
+
```
|