| Inputs: , , inter-state weights, gains for each state |
| Outputs: |
| state = excite |
| while (oscillating) { |
| if (state is excite) { |
| = Calculate new value of system |
| if (Based on it is time to move to Inhibit state) { |
| modify based on Excite to Inhibit weights |
| set state to Inhibit |
| } |
|
* End excite. * |
| if (state is inhibit) { |
| = Calculate new value of system |
| if (Based on it is time to move to Excite state) { |
| modify based on Inhibit to Excite weights |
| set state to Excite |
| } |
|
* End inhibit * |
| determine if it is time to stop oscillating based on: |
| number of iterations |
| closeness of and to ( + )/2 |
| Set oscillating variable appropriately. |
|
* End while * |