Skip to content

ddavidtran/Fishualization

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Fishualization - TNM085 Modelling and Simulation Course @ Linköping University

Introduction

Swarm behavior is a widely researched area but without many conclusive answers. Different kinds of swarms have different kinds of behaviors, and in this project the purpose is to simulate the schooling and shoaling patterns of fish using a Particle swarm optimization algorithm. Each individual fish has a set of rules which depends on its position relative to its neighbors and a universal target. To gain an insight into how the algorithm should be implemented, the first testing was done in MATLAB, which has extensive support for calculating and displaying large numbers of positions. The final program was written using C++ and OpenGL was used to generate the graphics.

How to run

MATLAB-version

  1. Download the MATLAB folder.
  2. Run FishSchool.m in MATLAB.

C++ version

Depends on:

  • OpenGL: Install OpenGL and build it with Cmake.
  1. Download the OpenGL folder.
  2. Compile the project. Make sure OpenGL is installed on your computer.
  3. If neccessary dependencies are installed, compile project and run main.cpp. Controls: Move the target with the mouse cursor. To move the target closer or further away in the scene use W and S on the keyboard.

Authors:

As part of the TNM085 Project course @ Linköping University.

Demo:

Fishualization

About

TNM085 Modelling and Simulation Course @ Linköping University

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •