#include #include #include #include #include "pssuby.h" //--------//--------//--------//--------//--------//--------//--------//-------- void main() { init(); viewport(0.2,0.2,0.8,0.8);xyworld(0.0,0.0,1.0,1.0); newpath();linety(2);plot(0.0,0.0,3);plot(0.0,1.0,2);plot(1.0,1.0,2);plot(1.0,0.0,2);closepath();stroke(); newpath();linety(2);rect(0.15,0.2,0.85,0.25);stroke(); newpath();linety(1); spline(0.2,0.25,0.4,0.23,0.6,0.23,0.8,0.25,-1); spline(0.2,0.25,0.4,0.23,0.6,0.23,0.8,0.25,0); spline(0.2,0.25,0.4,0.23,0.6,0.23,0.8,0.25,1);stroke(); newpath();linety(1); spline(0.2,0.2,0.4,0.18,0.6,0.18,0.8,0.2,-1); spline(0.2,0.2,0.4,0.18,0.6,0.18,0.8,0.2,0); spline(0.2,0.2,0.4,0.18,0.6,0.18,0.8,0.2,1);stroke(); newpath();plot(0.2,0.2,3);plot(0.2-0.05,0.2+0.01,2);plot(0.2-0.04,0.25+0.008,2);plot(0.2,0.25,2);stroke(); newpath();plot(0.8,0.2,3);plot(0.8+0.05,0.2+0.01,2);plot(0.8+0.04,0.25+0.008,2);plot(0.8,0.25,2);stroke(); newpath();plot(0.2,0.2,3);plot(0.22,0.15,2);plot(0.18,0.15,2);closepath();stroke(); newpath();plot(0.8,0.2,3);plot(0.82,0.15,2);plot(0.78,0.15,2);closepath();stroke(); newpath();arrowa(0.5,0.5,0.5,0.227,0.01);stroke(); text(0.49,0.52,"P"); newpath();text(0.2-0.01,0.25+0.01,"a1");stroke(); newpath();text(0.4-0.01,0.23+0.02,"a2");stroke(); newpath();text(0.6-0.01,0.23+0.02,"a3");stroke(); newpath();text(0.8-0.01,0.25+0.01,"a4");stroke(); newpath();text(0.2-0.01,0.2-0.1,"b1");stroke(); newpath();text(0.4-0.01,0.18-0.05,"b2");stroke(); newpath();text(0.6-0.01,0.18-0.05,"b3");stroke(); newpath();text(0.8-0.01,0.2-0.1,"b4");stroke(); setrgb(1.0,0.0,0.0); newpath();circ(0.2,0.25,0.005);stroke(); newpath();circ(0.4,0.23,0.005);stroke(); newpath();circ(0.6,0.23,0.005);stroke(); newpath();circ(0.8,0.25,0.005);stroke(); setrgb(0.0,0.0,1.0); newpath();circ(0.2,0.2,0.005);stroke(); newpath();circ(0.4,0.18,0.005);stroke(); newpath();circ(0.6,0.18,0.005);stroke(); newpath();circ(0.8,0.2,0.005);stroke(); fin(); }