/ Published in: Python
                    
                                        
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
def logistic_map(x0, r, n):
if n == 0: return x0
xprev = logistic_map(x0, r, n - 1)
return r * xprev * (1 - xprev)
Comments
 Subscribe to comments
                    Subscribe to comments
                
                