This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Random Boolean Networks */ | |
#include <stdio.h> | |
/* This is a two-dimensional Boolean Network based on an X-Y system. | |
If the field were put geometrically it would be a toroid. */ | |
#define MaxX 16 | |
#define MaxY 10 | |
/* K is the number of inputs a node has. I will use 2 for now. */ | |
#define K 2 | |
/* TRUE and FALSE are states, Boolean States. There are two of them. */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- | |
# # | |
## ## # # # # # # #### | |
# # # # # # # # ## # # # | |
# # # # ## # # # # # | |
# # # ## # # # # # ### | |
# # # # # # # ## # # | |
# # # # # # # # #### |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Triangle Input | |
*/ | |
#include <graphics.h> | |
#include <math.h> | |
#include <string.h> | |
#include "mouse.h" | |
struct point { | |
long int x,y; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*------------------------------------------------------------------------*\ | |
| C O R E W A R . H | | |
\*------------------------------------------------------------------------*/ | |
/* defines used for controlling size of the Core */ | |
#define MaxCoreSize 10 | |
#define MaxInstruction 9 | |
/* the modes of addressing in respect to the arguments' values */ | |
#define Immediate 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Run Length Decoding | |
An example program that decompresses the data stored in | |
a disk file to video memory */ | |
#include <stdio.h> | |
/* the screen's beginning memory address B800:0000 */ | |
#define ScrnMem 0xb8000000 | |
/* with CGAs the screen takes up 4000 bytes. */ | |
#define ScrnSize 4000 | |
/* the escape code is the symbol which we won't see in the data we are |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <math.h> | |
#include <graphics.h> | |
#include <conio.h> | |
#include <mouse.h> | |
#define double long double | |
#define MaxRI (double)6.0 | |
#define MaxIter 32 | |
#define ScrX 40 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Maximizing Flow in a Network */ | |
#include <stdio.h> | |
#include <ctype.h> | |
#include <conio.h> | |
#include <stdlib.h> | |
/* These are small for no real reason. */ | |
#define MAXVERTEXCNT 6 | |
#define MAXFLOW 15 | |
#define BIGMAXFLOW (MAXFLOW*MAXFLOW) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Meander | |
*/ | |
#include <stdio.h> | |
/* For IBMs only. */ | |
#include "stdlib.h" | |
#include "graphics.h" | |
/* Miscellaneous defines. */ | |
#define BOARDX 8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Random Walks | |
*/ | |
#include "stdio.h" | |
#include "stdlib.h" | |
#include "time.h" | |
#include "conio.h" | |
#include "graphics.h" | |
#define MAXX 40 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
"Life" | |
John Horton Conway's Cellular Automaton | |
Using meta-blocks | |
*/ | |
#include <stdio.h> | |
/* For IBMs only. */ | |
#include "conio.h" |