回答編集履歴
1
Update
test
CHANGED
@@ -1,10 +1,11 @@
|
|
1
1
|
スクリプトの最後に以下を追加。
|
2
2
|
```python
|
3
3
|
steps = r1com_sol.shape[0]
|
4
|
-
artists = [
|
4
|
+
artists = [
|
5
|
+
[ax.scatter(*np.c_[r1com_sol[i], r2com_sol[i]],
|
6
|
+
color=["darkblue", "tab:red"], marker="o", s=30)]
|
5
|
-
for i in range(0, steps, 2)
|
7
|
+
for i in range(0, steps, 2)
|
6
|
-
artist = ax.scatter(*np.c_[r1com_sol[i], r2com_sol[i]], color=["darkblue", "tab:red"], marker="o", s=30)
|
7
|
-
|
8
|
+
]
|
8
9
|
anim = ArtistAnimation(fig, artists, interval=50)
|
9
10
|
```
|
10
11
|
![イメージ説明](https://ddjkaamml8q8x.cloudfront.net/questions/2022-07-24/1c66a8a8-04ef-405e-b08e-c6d07712a10b.gif)
|