次のような媒介変数表示される曲線をリサージュ曲線といいます。
\[ \begin{cases} x = \sin at \\ y = \sin bt \end{cases} \]
import java.awt.Graphics2D;
import myMath.MyCurve;
import myMath.Tpl20;
public class TestMyParameter071 extends Tpl20 {
public void draw2(Graphics2D g2) {
MyPara1 pf = new MyPara1();
draw(pf, 0, 2 * Math.PI);
}
class MyPara1 extends MyCurve {
double a = 1;
double b = 2;
public void p(double t) {
x = Math.sin(a * t);
y = Math.sin(b * t);
}
}
}
import java.awt.Graphics2D;
import myMath.MyCurve;
import myMath.Tpl20;
public class TestMyParameter072 extends Tpl20 {
public void draw2(Graphics2D g2) {
MyPara1 pf = new MyPara1();
draw(pf, 0, 2 * Math.PI);
}
class MyPara1 extends MyCurve {
double a = 2;
double b = 3;
public void p(double t) {
x = Math.sin(a * t);
y = Math.sin(b * t);
}
}
}
import java.awt.Graphics2D;
import myMath.MyCurve;
import myMath.Tpl20;
public class TestMyParameter073 extends Tpl20 {
public void draw2(Graphics2D g2) {
MyPara1 pf = new MyPara1();
draw(pf, 0, 2 * Math.PI);
}
class MyPara1 extends MyCurve {
double a = 4;
double b = 5;
public void p(double t) {
x = Math.sin(a * t);
y = Math.sin(b * t);
}
}
}