loom
1import "diff/LorenzSystem.diff" type LorenzSystem;
2
3LorenzSystem LS = {
4sigma : 10.0,
5b : 8.0/3,
6R : 28.0,
7
8x : 10.0,
9y : 1.0,
10z : 1.0,
11};
12
13int XY_PANEL = 0;
14int XZ_PANEL = 1;
15
16string s1 = "Проекция x-y";
17string s2 = "Проекция x-z";
18
19chart.panel.init(XY_PANEL, "Аттрактор Лоренца: x, y");
20chart.panel.addSeries(XY_PANEL, s1, chart.Style.Line);
21chart.panel.init(XZ_PANEL, "Аттрактор Лоренца: x, z");
22chart.panel.addSeries(XZ_PANEL, s2, chart.Style.Line);
23
24void onShow()
25{
26chart.panel.addPoint(XY_PANEL, s1, LS.x, LS.y);
27chart.panel.addPoint(XZ_PANEL, s2, LS.x, LS.z);
28}
29
30scene.setIterationCallback(onShow, 1);
31scene.setT(0.0);
32scene.setTk(50.0);
33scene.setDt(0.01);
34
35scene.add(LS);
36
37scene.start();
38
39chart.panel.show(0);
40chart.panel.show(1);
41