You may input an image or use random initialized values and see the results.
You can change the rules with new rules.
You can control the time.
Do you ave any related question, any suggestions to speed up the code, you are more than welcome. ^_^
Nice and simple code! Helps me to learn CLA.
Thank You :)
thanks ,I am learning the CA
Thanks for your comments.
I have updated the zip file to contain the image example.
You can do the following:
1. put any binary image in the same folder.
2. put the image file name in the line :
A=imread('Your_ image_ file_ name.image type');
You should notice that the image is an example, you may put your own initial values matrix which is suiatble for your problem or you may start with a random matrix.
When i try running your program it comes up with the following error message:
??? Error using ==> imread at 361
File "CA02.JPG" does not exist.
Error in ==> gameoflifedownloaded at 29
What do I have to change in the program to get it to work?
I have added a sample image, but you may change it with your initial states suitable for your problem.
Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.