Parallel Sugarscape: OpenMPによる「平行宇宙」版 Sugarscape
- エージェントは交配でなく自己複製で増える。
- 砂糖のレベルは整数ではなく実数。
- 特定のサイトへのエージェントの移動は、「早いもの順」ではなく、いったん希望者を集計してから乱数をふる。
- 「平行宇宙」(複数のSugarscape世界を同時実行)OpenMPで並列計算。
- Const.h の NUM_OF_PARALLEL_WORLD の値(この数字を使用する計算機のコア数に一致させるのが高速計算にはよい。)
- sキーで開始/停止
- 矢印キーで移動
- Shift+矢印キーで回転
- zキーで拡大。shift+z で縮小
//
// Parallel Sugarscape
//
// Reference : "Growing Artificial Societies: Social Science from
// the Bottom Up"
// by Joshua M. Epstein and Robert L. Axtell (1996)
//
//
// Difference from the original Sugarscape
// - The sugar level is saved in double, instead of integer.
// - Cloning, instead of crossbreeding.
// - Added "move request" function, for (future)
// parallel processing.
// - Added "parallel universe" function and its
// OpenMP parallel processing.
//
//
// Coded by Akira Kageyama (kage@cs.kobe-u.ac.jp)
// at Kobe Univ.
// on 2012.07.29
//
// 2013.08.01: A bug fixed by Y. Hashi (Agent.cpp)
//
- コンテンツ
- Agent.cpp
- Agent.h
- AgentSwarm.cpp
- AgentSwarm.h
- Consts.h
- Grid.cpp
- Grid.h
- Makefile
- Sugar.cpp
- Sugar.h
- TimeKeeper.cpp
- TimeKeeper.h
- main.cpp
- ファイル