Microsoft Small Basic

Program Listing: DCJ438
'Program 06 (logist.bas)
' Author Wojciech Szczepankiewicz
' Silesian University of Technology, Gliwice, Poland
' Attractors, bifurcations and chaos in logistic function
GraphicsWindow.BackgroundColor = "White"
For c = 0.9 To 4 Step .01
x = .2
min = 60 'the number of abandoned iterations
For i = 1 To 500
x = c * x * (1 - x) 'logistic equation
If i > min Then
GraphicsWindow.SetPixel(c * 100, 400 - x * 300, "Red")
EndIf
EndFor
EndFor
GraphicsWindow.DrawText(10, 420, "End of calculation")