2020/03/02

リサジュー曲線の書き方(2)

 前回の続きです。下記式で c を変化させるとどんな図形になるか実行してみます。

{x(t)=cos(at)y(t)=cos(bt+c) (0t<2π)

  cx に対する y の位相を意味します。


書き方


 R言語での書き方は以下の通りです。

1
2
3
4
5
6
7
8
9
10
11
12
t=seq(0, 2*pi, length=300)
svg("phase.svg", width=5, height=12)
par(mfcol=c(4,2))
plot(sin(t), sin(t),        type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=0°")
plot(sin(t), sin(t+pi/4),   type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=45°")
plot(sin(t), sin(t+2*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=90°")
plot(sin(t), sin(t+3*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=135°")
plot(sin(t), sin(t+4*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=180°")
plot(sin(t), sin(t+5*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=225°")
plot(sin(t), sin(t+6*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=270°")
plot(sin(t), sin(t+7*pi/4), type="l", asp=1, col=2, lwd=2, main="a:b=1:1, c=315°")
dev.off()

 実行結果を以下に示します。

0 件のコメント:

コメントを投稿

マンデルブロ集合の彩色方法(5)

06.knit 1 発散判定式を変更する mandelbrot() 内の発散判定式 |zn|>2 を変更する...