What is the difference between simulation and emulation?

11 points by docdot ↗ HN

6 comments

[ 3.3 ms ] story [ 26.0 ms ] thread
Emulation is often used to mean a rougher less exact simulation.
I think simulation is, as the name implies, to simulate the behavior of something. For example, games like Gran Turismo and Assetto Corza are simulators because they implement the logic so the cars behave as close as real life as they can.

On the other hand, emulation is about implementing the behavior of a hardware or device via software. For example a console emulator implements the logic so the API calls made by the game are interpreted by the emulator and tries to execute as if the game was communicating with the real hardware (CPU, Memory, etc).

Emulator: make a CPU architecture run (exactly) on a different one. Example: x86 on M1. See also QEMU https://www.qemu.org/

Simulator: run (approximately) a physical system on a computer. Example: weather forecasts.

As always in practice close words are used interchangeably.

I'd say emulation is to replicate a known behaviour of a system while simulation is to build an internal odel of a system in order to observe its behaviour.

For instance, a CPU emulator is only concerned with executing instructions in the same way as the actual CPU whereas a CPU simulator would be a internal model of the CPU at some level of details (e.g. transistor level) in order to observe how it behaves (which you perhaps don't know).

To me: emulation attempts to a 1:1 recreation, whereas simulation cannot; the system is too complicated or poorly understood to emulate 1:1 so simulation is a possible model of some aspects of the underlying reality.
https://www.geeksforgeeks.org/difference-between-emulation-a...

> 1. Emulation :

> Emulation, as name suggests, is a technique that enables host system to run software or use peripheral devices especially designed for guest system. Its main purpose is to replace hardware or software components with function equivalents when original modules are not available. It mimics hardware and software of target device on computer.

> Example : Android SDK, etc.

> 2. Simulation :

> Simulation, as name suggests, is a technique that helps computer to run certain programs developed for different OS. It usually provides essential method of analysis that is easily communication, verified and understood. Its main purpose is to shed light on mechanism that usually control behavior of system. It is totally computer based and uses algorithms and equations.

> Example : iOS Simulator, flight simulator, etc.

Also worth reading: https://www.perfecto.io/blog/emulation-vs-simulation