---
# System prepended metadata

title: 2023-05-15 Meeting minutes
tags: [Meeting]

---

# 2023-05-15 Meeting minutes
###### tags: `Meeting`
**08:00 | Zoom**

Present: Martin, Mathias, Jacob, Christoffer, Linn, Edvin

## Before the meeting
* Don't worry be happy

## Agenda
* Around the table
* Go through the report one last time
* Turn the report in??!! 🥳🥳🥳
* Last parts :man-with-bunny-ears-partying: 
  * Movie, Opposition and Presentation


## Decisions
* Film
  * Should be short, really just an overview of our engine
  * Audience: Basic understanding of programming, 
  * Structure:
    * (30s) Introduce simulations and game engines
      * Computer simulations are widely used in the industry today. The speed of which is highly sought after, allowing for fast generation of results and for a wide variety of real-time applications, such as videogames, to be implemented. Simulation- and game-engines have for a long time used an object-oriented approach, but due to its poor performance and difficulty to work with, alternative designs are becoming more common. ECS is one of these and stands for Entity Component System. 
    * (2 min) Explain ECS
        * The ECS architecture splits the engine into three parts: Entities, Components and Systems. Entities represent different objects in the simulated world, and components are the different attributes of each entity, such as position, velocity and mass. The developer can create their own unique components based on their needs. Systems operate on entities and their components and give them behaviors and effects. A system only operates on entities with a specific set of components, such as a gravity system, only operating on entities with a position, velocity and mass. This gives ECS a high degree of flexibility as it allows behaviors to be modified by simply adding or removing components from entities, which can be used d to change what happens in the simulation. 
        * A key difference between ECS and object-orientation, is that ECS separates data from logic into component and systems, while objects encapsulate these two. This separation gives ECS higher composability and a more efficient way of storing and accessing data. Components can be packed cloesly in memory, and processed quickly using the same function multiple times. In contrast it is difficult to do this with objects and thus fewer can be processed in the same amount of time.
        * Working with large projects is also improved in ECS, thanks to its use of composition of components, which decreases coupling of code making modifications to the simulation less difficult.
    * (30 s) Explain what features RECS have
        * During the thesis, a simulation engine called RECS was implemented using the ECS architecture. The purpose was to produce an engine that could help developer build high performing simulations by providing a flexible developer API, automated parallelism and an efficient component storage, while hiding this complexity from the developer. 
    * (30 s) Show the N-Body simulation
        * To showcase and compare the performance difference between RECS, the object-oriented game-engine Unity GameObjects and other ECS engines, a simple gravity simulations was created. Each entity or body within the simulations is a sphere which is affected by the gravity of all other objects. This is a computationally-heavy simulations since it requires each body to be altered by every other body in the scene leading to the fact that the number of computations increases quadratically according to the amount of bodies.
    * (1 min) Present performance results
      * To evalute the performance between RECS and other engines and frameworks, the N-body simulation was benchmark for different number of bodies. 
      * This is the realtime execution of the simulation using the Unity GameObjects engine. We can see that the FPS is quite slow at 0.3 frames per second with around 4000 bodies. 
      * We now switch over to the simulation being executed by RECS. We can now see that the same amount of bodies is being updated at a significantly faster rate, at 87 frames per second.
      * With the amount of bodies set to around 16000 bodies being executed on the two engines it was observed that RECS was almost 700 times faster than Unity GameObjects. 
      * RECS has a similar performance to other ECS-engines for large numbers of bodies.

    * (30 s) Thesis Conclusion
      * In conclusion, RECS performs quite well on computationally-heavy tasks. Compared to Unity Gameobjects an almost 700 times speedup was observed and against other ECS engines, only one was more efficient at scale. RECS is quite slow at other tasks, however, like dynamically creating and removing entire entities during runtime. During the benchmarking of this functionality it was seen that RECS performed up to 20 times slower than an other ECS engine. As a whole the project was a success and the benefits of ECS compared to OOP have been showcased.
  * The Three Questions:
    * What is the main difference between ECS and OOP?
      * (correct) Separation of data and logic
      * (incorrect) There is no difference
      * (incorrect) OOP is faster
      * (incorrect) ECS is used in games but OOP is not
    * Approximately, how much faster is RECS than Unity GameObjects in the largest measured n-body simulation?
      * (correct)   700
      * (incorrect) 70
      * (incorrect) 7000
      * (incorrect) 70000
    * What area does RECS excel in? 
      * (correct) Computationally heavy simulations 
      * (incorrect) Lightweight system iteration
      * (incorrect) Dynamic removal and addition of entities and components
      * (incorrect) High-fidelity graphics rendering
* Christoffer, Edvin and Jacob will create the film.
* The [Final presentation](/ddTZdn6dTK--v6TdjqMAxg) document
  * Martin, Mathias and Linn

## Next meeting

**2023-05-16 | 10:00 | Zoom**



