Skip to content

Commit c2ffd4e

Browse files
author
Bouwmeester, Kevin
committed
Forgot to add remainder source
1 parent 004004b commit c2ffd4e

26 files changed

+3810
-1
lines changed
53.5 KB
Loading
49.8 KB
Loading
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
% The abstract should briefly summarize the contents of the paper in 150--250 words.
2+
% \begin{abstract}
3+
% asdasd
4+
5+
% \keywords{Digital Twins \and Design Patterns.}
6+
% \end{abstract}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
\begin{credits}
2+
\subsubsection{\ackname} A bold run-in heading in small font size at the end of the paper is
3+
used for general acknowledgments, for example: This study was funded
4+
by X (grant number Y).
5+
6+
\subsubsection{\discintname}
7+
It is now necessary to declare any competing interests or to specifically
8+
state that the authors have no competing interests. Please place the
9+
statement with a bold run-in heading in small font size beneath the
10+
(optional) acknowledgments\footnote{If EquinOCS, our proceedings submission
11+
system, is used, then the disclaimer can be provided directly in the system.},
12+
for example: The authors have no competing interests to declare that are
13+
relevant to the content of this article. Or: Author A has received research
14+
grants from Company W. Author B has received a speaker honorarium from
15+
Company X and owns stock in Company Y. Author C is a member of committee Z.
16+
\end{credits}
Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
\section{First Section}
2+
\subsection{A Subsection Sample}
3+
Please note that the first paragraph of a section or subsection is
4+
not indented. The first paragraph that follows a table, figure,
5+
equation etc. does not need an indent, either.
6+
7+
Subsequent paragraphs, however, are indented.
8+
9+
\subsubsection{Sample Heading (Third Level)} Only two levels of
10+
headings should be numbered. Lower level headings remain unnumbered;
11+
they are formatted as run-in headings.
12+
13+
\paragraph{Sample Heading (Fourth Level)}
14+
The contribution should contain no more than four levels of
15+
headings. Table~\ref{tab1} gives a summary of all heading levels.
16+
17+
\begin{table}
18+
\caption{Table captions should be placed above the
19+
tables.}\label{tab1}
20+
\begin{tabular}{|l|l|l|}
21+
\hline
22+
Heading level & Example & Font size and style\\
23+
\hline
24+
Title (centered) & {\Large\bfseries Lecture Notes} & 14 point, bold\\
25+
1st-level heading & {\large\bfseries 1 Introduction} & 12 point, bold\\
26+
2nd-level heading & {\bfseries 2.1 Printing Area} & 10 point, bold\\
27+
3rd-level heading & {\bfseries Run-in Heading in Bold.} Text follows & 10 point, bold\\
28+
4th-level heading & {\itshape Lowest Level Heading.} Text follows & 10 point, italic\\
29+
\hline
30+
\end{tabular}
31+
\end{table}
32+
33+
34+
\noindent Displayed equations are centered and set on a separate
35+
line.
36+
\begin{equation}
37+
x + y = z
38+
\end{equation}
39+
Please try to avoid rasterized images for line-art diagrams and
40+
schemas. Whenever possible, use vector graphics instead (see
41+
Fig.~\ref{fig1}).
42+
43+
\begin{figure}
44+
\includegraphics[width=\textwidth]{fig1.eps}
45+
\caption{A figure caption is always placed below the illustration.
46+
Please note that short captions are centered, while long ones are
47+
justified by the macro package automatically.} \label{fig1}
48+
\end{figure}
49+
50+
\begin{theorem}
51+
This is a sample theorem. The run-in heading is set in bold, while
52+
the following text appears in italics. Definitions, lemmas,
53+
propositions, and corollaries are styled the same way.
54+
\end{theorem}
55+
%
56+
% the environments 'definition', 'lemma', 'proposition', 'corollary',
57+
% 'remark', and 'example' are defined in the LLNCS documentclass as well.
58+
%
59+
\begin{proof}
60+
Proofs, examples, and remarks have the initial word in italics,
61+
while the following text appears in normal font.
62+
\end{proof}
63+
For citations of references, we prefer the use of square brackets
64+
and consecutive numbers. Citations using labels or the author/year
65+
convention are also acceptable. The following bibliography provides
66+
a sample reference list with entries for journal
67+
articles~\cite{citation-key}, an LNCS chapter~\cite{Nobody08}, a
68+
book~\cite{1patashnik}, proceedings without editors~\cite{1patashnik},
69+
and a homepage~\cite{1patashnik}. Multiple citations are grouped
70+
\cite{1patashnik,Nobody06,Nobody07},
71+
\cite{1patashnik,Nobody06,Nobody07,Nobody08}.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
% \section{Introduction}
2+
% Basic intro in DT engineering practises (cause for this research)
3+
4+
% Basic intro into pattern use. Introduce ECS with the indication of being well-used in Game Development, but under-represented in research (i.e. outside of game development). Mainly indicate how ECS would fit well, as video games are often also quite complex software systems.
5+
6+
% Intro on what the paper presents, mainly scoping it. Introduce the (research) questions. NOTE: Not certain if truly research questions, since the goal is mainly to explore the pattern, and place it in our existing knowledge.
7+
8+
% Introduce structure of article.

app/knowledge-hub/ECS/latex/Sections/Section_10.tex

Whitespace-only changes.
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
2+
\section{The Entity-Component System Pattern}
3+
The main purpose of this section is to introduce the ECS pattern and to elaborate on the principles that support it. We will do this through comparing the ECS pattern with other, more well-known patterns commonly found in the field of Digital Twin Engineering. Furthermore, the section will list some terminology and illustrations on the pattern that support later sections.
4+
5+
\subsection{Structure}
6+
To explain what the ECS pattern is, it is useful to compare it with the OOP paradigm. OOP provides practical aspects such as encapsulation and inheritance. Encapsulation provides the benefit of keeping related code, both variables and methods, together. This approach is also used by the Entity-Component architecture, which should not be confused with the Entity-Component-System Architectural pattern. Inheritance provides benefits for which code reusability is the primary one. However, in some applications, the hierarchical structure could become problematic if the structure does not account for a certain new type of entity.
7+
8+
As mentioned, the ECS pattern has its roots in game development, where iterative development is common. The ECS pattern has the benefit of providing a high separation of concerns, which allows separate development teams to concurrently develop elements for their system, as well as to support more iterative development \cite{wiebuschDecouplingEntitycomponentsystemPattern2015, muratetAccessibilitySeriousGames2020}. The pattern achieves this by defining \textit{entities} as compositions of \textbf{components} instead of having \textit{entities} inherit properties from \textit{components}. In short, the ECS system pattern is defined through three major elements: \textit{Entities}, \textit{Components} and \textit{Systems}.
9+
10+
\subsection{Entities}
11+
Entities are nothing more than a container with a unique identifier that is composed of components. Although this often implies that an entity can be represented by a simple integer, this is often extended with more descriptive information to clarify the desired purpose of the entity, as well as a name \cite{hatledalVicoEntitycomponentsystemBased2021}. To be usable, it is important that the entities can be easily managed. Sometimes, depending on the components of which the entity is composed, a \textit{family} label is assigned to the entities. Such a label could be used to quickly discover entities that are composed of similar components.
12+
13+
\subsection{Components}
14+
Components represent data. If well-designed, they are generic, small, and reusable. A component, to some extent, could be considered as a collection of properties. \textit{Geometry} is a proper example, as this can be defined in different ways using different properties (e.g. length, width). Components could also be slightly more abstract, where a component itself serves as an identifying label to the entity that is composed from it (an example from game-design could be the differentiation between ally or foe).
15+
16+
In the ECS pattern, the components are different from other entity-component designs, as they do not describe behavior. In classical OOP and Object-oriented composition, components include behavioral functionality, which is part of the encapsulation principle. The ECS completely decouples this, as behavior is determined based on the composition of Components, where \textit{Systems} calculate state-changes to entity-component data.
17+
18+
\subsection{Systems}
19+
Systems act on entities, computing mutations to relevant components. Systems act only upon certain entities, which depend on the components it has. As a very basic example, if gravity exists within the simulated world, a \textit{Gravity System} could be responsible for calculating vectors based on the mass of entities. This system could act upon entities that are composed of a \textit{mass} component. In this way, the behavior of an entity is determined by the systems that act on the entity.
20+
21+
In naive implementations, Systems have to iterate over all entities to determine which should be processed. This can be expansive, especially in software systems where timing is important. The concept of entity families mitigates this, providing dynamic grouping of entities based on their component composition \cite{hatledalVicoEntitycomponentsystemBased2021,LibgdxAshley2025}.
22+
23+
\subsection{An example}
24+
To clarify the differences between classical OOP and use of the ECS pattern, we provide a small example. Figure \ref{fig:OOPVehicles} shows a simple class diagram that could be used to define different vehicles. The specialized classes \textit{LandVehicle} and \textit{SkyVehicle} inherit properties and methods from the \textit{Vehicle} class. Each specialization might provide different implementations for the indicated methods as the way in which this is performed might differ. Further specialized classes could differentiate helicopters from airplanes and cars from bicycles. Similarly to actuation in a Digital Twin system, assume that an external actor controls the vehicles velocity. The public methods represent user controlled actions, while the \textit{updatePosition()} method represents some logic that continuously updates the position of the vehicle based on its velocity and current position.
25+
26+
When using the given classes, it becomes difficult to model a bicycle with flight capabilities. Multiple-inheritance could be used, but given the possibly different implementations of the shared methods, its behavior would likely have to be manually defined.
27+
28+
Object-Oriented composition could be utilized, resulting in an Entity-Component implementation where entities are composed of the components which include behavioral components. However, this approach does not separate behavior from data. This approach could introduce additional overhead \cite{romeoAnalysisEntityEncoding2016}. Furthermore, to optimize this, software developers would have to optimize each individual method. This is more difficult to maintain and evolve.
29+
30+
31+
\begin{figure}
32+
\centering
33+
\includegraphics[width=0.85\linewidth]{Figures/OOP Vehicles.png}
34+
\caption{A simple UML class diagram that models vehicles}
35+
\label{fig:OOPVehicles}
36+
\end{figure}
37+
38+
Using the ECS pattern, a vehicle entity could be modeled by composing it with desired components. Figure \ref{fig:ECSVehicles} shows how this can be done. An \textit{Input System} would process entities with the \textit{user-controlled} and \textit{linear velocity} components. A different system could be defined that acts on entities also composed of the \textit{angular velocity} component, but the \textit{input system} could also provide additional logic when this component is present. Finally, the \textit{Position System} would act upon every entity with a velocity and position component, and calculate the new positions.
39+
40+
Instead of requiring each entity to be scheduled for processing, only the \textit{Systems} would require this when using the ECS pattern. In the given example, there would likely need to be some orchestration defining the order in which the systems are executed, as otherwise race conditions could occur. As such, the ECS pattern is not a panacea. It has uses in certain applications, specifically those in which many entities exhibit equal or similar behavior, as it reduces the overhead required. Furthermore, this approach allows entities to be adjusted at run-time, or even new systems to be introduced \cite{wiebuschDecouplingEntitycomponentsystemPattern2015}.
41+
42+
\begin{figure}
43+
\centering
44+
\includegraphics[width=0.85\linewidth]{Figures/ECS Vehicle.png}
45+
\caption{A UML diagram representing how vehicles could be modeled using ECS}
46+
\label{fig:ECSVehicles}
47+
\end{figure}

app/knowledge-hub/ECS/latex/Sections/Section_3.tex

Whitespace-only changes.

app/knowledge-hub/ECS/latex/Sections/Section_4.tex

Whitespace-only changes.

0 commit comments

Comments
 (0)