Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Can anyone help me create this using python. Cellular Automata Coding help Create a folder on your computer where your files will be kept. To
Can anyone help me create this using python.
Cellular Automata
Coding help
Create a folder on your computer where your files will be kept. To keep your work organized, create a different folder for each lab, and for each programming assignment. A cellular automaton consists of an array of 1s and 0s, which is changed with each "generation". The new values form the next row of the automaton. At each entry, each value in the new row will depend on the three values above it: one directly above it, and the other two on either side. Here is an interesting rule (called "rule 110"): Let's try out this rule. Suppose the previous row was: 0 0 1 1 0 0 0 Then the next row would be: 0 0 1 0 0 1 0 Notice that we can't use the rule to compute the first and last values in the next row, because there aren't three values above it. We set the first and last values to 0. Write a program automaton.py which does the following: Asks the user for a initial row of values, entered as a string of 0s and 1s. For example, the user might type 0011000. Creates a list of ints, from the string the user entered. Runs 30 generations of the automaton, using rule 110, printing each generation as it is computed. Create a folder on your computer where your files will be kept. To keep your work organized, create a different folder for each lab, and for each programming assignment. A cellular automaton consists of an array of 1s and 0s, which is changed with each "generation". The new values form the next row of the automaton. At each entry, each value in the new row will depend on the three values above it: one directly above it, and the other two on either side. Here is an interesting rule (called "rule 110"): Let's try out this rule. Suppose the previous row was: 0 0 1 1 0 0 0 Then the next row would be: 0 0 1 0 0 1 0 Notice that we can't use the rule to compute the first and last values in the next row, because there aren't three values above it. We set the first and last values to 0. Write a program automaton.py which does the following: Asks the user for a initial row of values, entered as a string of 0s and 1s. For example, the user might type 0011000. Creates a list of ints, from the string the user entered. Runs 30 generations of the automaton, using rule 110, printing each generation as it is computedStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started