يوجد عندي خوارزميه وأريد تحويلها إلى برنامج بلغة الفيجوال سي أو بلغة الفيجوال بيسك6 أو لغة باسكال أو سي حيث أنني محتاج إليها بسرعة وهي كالتالي:
Type
Shape=(cardioid,threeleaf,spiral,fourlear,limacon) ;
Procedure drawshap (figure:shape;xc,yc,a,b:integer),
{a,b are used to computer}
var
thete,dtheta:real;
begin
theta:=;
dtheta=1/a;{الزيادة في الزاوية}
y [1]:=yc;
case figure of
cardioid : x[1]:= round (xc+a*2);
threeleaf:x[1]:=round(xc+a);
spiral:x[1]:=xc;
fourlead:x[1]:=round(xc+a);
limacon :x[1]:=round(xc+b+a);
end
while theat <6.28 do
begin
case figure of
cardioid :r:=a*(1+cos(theta));
threeleaf :r:=a*cos(3*theta);
spiral:r:=a*theta;
fourleaf:r:=a*cos(2*theta),
limacon :r:=b+a*cos(theta)
end
x[2]:=round(xc+r*cos(theta))
y[2]:=round(yc+r*sin(theta));
polyline(2,x,y);
x[1]:=x[2];
y[1]:=y[2];
theta:=theta+dtheta
end
end;
