« Programmation objet et géométrie/Programmation avec DrGeoII » : différence entre les versions

s:=figure segment: 0@(-1) to: 4@(-1).
r:=figure pointOnCurve: s at: 0.8.
s:=figure segment: 0@0 to: 0@1.
u:=figure pointOnCurve: s at: 0.7.
u round small.
u color: Color blue.
1 to: 100 do: [:n|
u:=figure point: [:parents| |y t|
point: y[:=parents| first|y point y.t|
t y:=parents secondfirst point xy.
(n/5)@ t*y*(1-y)]:=parents second point x.
parents: (n/5)@t*y*(1-y)] {u.r}.
parents: {u round small.r}.
u color: Colorround bluesmall.
u color: Color blue].
</source>
 
Utilisateur anonyme