ArticleslgStudy

computer science

Simulation (computer science)

Simulation (computer science) is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Simulation (computer science) rather than just read about it. In short: In theoretical computer science, a simulation is a relation between state transition systems associating systems that behave in the same way in the sense that one system simulates the other. Intuitively, a system simulates another system if it can match all of its moves.

Key takeaways

  • Simulation (computer science) belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Simulation (computer science) to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Simulation (computer science) from memory before moving on to harder problems.

Reference excerpt

In theoretical computer science, a simulation is a relation between state transition systems associating systems that behave in the same way in the sense that one system simulates the other. Intuitively, a system simulates another system if it can match all of its moves. The basic definition relates states within one transition system, but this is easily adapted to relate two separate transition systems by building a system consisting of the disjoint union of the corresponding components.

Formal definition Given a labelled state transition system ( S {\displaystyle S} , Λ {\displaystyle \Lambda } , →), where S {\displaystyle S} is a set of states, Λ {\displaystyle \Lambda } is a set of labels and → is a set of labelled transitions (i.e., a subset of S × Λ × S {\displaystyle S\times \Lambda \times S} ), a relation R ⊆ S × S {\displaystyle R\subseteq S\times S} is a simulation if and only if for every pair of states ( p , q ) {\displaystyle (p,q)} in R {\displaystyle R} and all labels λ in Λ {\displaystyle \Lambda } :

if p → λ p ′ {\displaystyle p{\overset {\lambda }{\rightarrow }}p'} , then there is q → λ q ′ {\displaystyle q{\overset {\lambda }{\rightarrow }}q'} such that ( p ′ , q ′ ) ∈ R {\displaystyle (p',q')\in R}

Equivalently, in terms of relational composition:

R − 1 ; → λ ⊆ → λ ; R − 1 {\displaystyle R^{-1}\,;\,{\overset {\lambda }{\rightarrow }}\quad {\subseteq }\quad {\overset {\lambda }{\rightarrow }}\,;\,R^{-1}}

Given two states p {\displaystyle p} and q {\displaystyle q} in S {\displaystyle S} , p {\displaystyle p} can be simulated by q {\displaystyle q} , written p ≤ q {\displaystyle p\,\leq \,q} , if and only if there is a simulation R {\displaystyle R} such that ( p , q ) ∈ R {\displaystyle (p,q)\in R} . The relation ≤ {\displaystyle \leq } is called the simulation preorder, and it is the union of all simulations: ( p , q ) ∈ ≤ {\displaystyle (p,q)\in \,\leq \,} precisely when ( p , q ) ∈ R {\displaystyle (p,q)\in R} for some simulation R {\displaystyle R} . The set of simulations is closed under union; therefore, the simulation preorder is itself a simulation. Since it is the union of all simulations, it is the unique largest simulation. Simulations are also closed under reflexive and transitive closure; therefore, the largest simulation must be reflexive and transitive. From this follows that the largest simulation—the simulation preorder—is indeed a preorder relation. Note that there can be more than one relation that is both a simulation and a preorder; the term simulation preorder refers to the largest one of them (which is a superset of all the others). Two states p {\displaystyle p} and q {\displaystyle q} are said to be similar, written p ≤≥ q {\displaystyle p\leq \geq q} , if and only if p {\displaystyle p} can be simulated by q {\displaystyle q} and q {\displaystyle q} can be simulated by p {\displaystyle p} . Similarity is thus the maximal symmetric subset of the simulation preorder, which means it is reflexive, symmetric, and transitive; hence an equivalence relation. However, it is not necessarily a simulation, and precisely in those cases when it is not a simulation, it is strictly coarser than bisimilarity (meaning it is a superset of bisimilarity). To witness, consider a similarity that is a simulation. Since it is symmetric, it is a bisimulation. It must then be a subset of bisimilarity, which is the union of all bisimulations. Yet it is easy to see that similarity is always a superset of bisimilarity. From this follows that if similarity is a simulation, it equals bisimilarity. And if it equals bisimilarity, it is naturally a simulation (since bisimilarity is a simulation). Therefore, similarity is a simulation if and only if it equals bisimilarity. If it does not, it must be its strict superset; hence a strictly coarser equivalence relation.

… excerpt ends here. Continue reading the full article.

Worked examples

Example 1 — a first encounter with Simulation (computer science)

Start with the simplest possible case. Write down what Simulation (computer science) claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Simulation (computer science) before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Simulation (computer science) ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Simulation (computer science)

In research
Simulation (computer science) appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Simulation (computer science) in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Simulation (computer science) is common in secondary-school and first-year university syllabi. It links to neighbouring topics Theoretical computer science, Transition systems, so understanding it makes those chapters shorter.
In everyday life
Look for Simulation (computer science) outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study Simulation (computer science) in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Simulation (computer science) means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Simulation (computer science) out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Simulation (computer science) in simple terms?

In theoretical computer science, a simulation is a relation between state transition systems associating systems that behave in the same way in the sense that one system simulates the other. Intuitively, a system simulates another system if it can match all of its moves.

Why does Simulation (computer science) matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Simulation (computer science)?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Simulation (computer science).

Tags

  • Theoretical computer science
  • Transition systems

Keep exploring