Sunday, December 15, 2019

Parametric Drawing 2


PPRT2[n_,m_,col_,s_]:=Module[{a,b,c,u},
u=Pi/n; a=RandomInteger[{5,12}];

b=RandomInteger[{13,36}];c=2*RandomInteger[{3,6}];
PF1[i_,t_]:=Cos[u*t+2i*Pi/c]+Cos[a*u*t+2i*Pi/c]+Cos[b*u*t+2i*Pi/c];
PF2[i_,t_]:=Sin[u*t+2i*Pi/c]-Sin[a*u*t+2i*Pi/c]+Sin[b*u*t+2i*Pi/c];
Graphics[Table[{EdgeForm[ColorData[col][1-i/(2c)]],FaceForm[None],
Polygon[Table[{PF1[i,t], PF2[i,t]}, {t, 0,m*Pi,Pi/c}]]},{i,2c}],
Background->RGBColor["lightgrey"],

PlotLabel->{"a"->a,"b"->b,"c"->c},ImageSize->s]];
PPRT2[12,6,"DeepSeaColors",600]


No comments:

Post a Comment