虽然我理解模拟和模拟的一般含义,但我几乎总是对它们感到困惑。假设我创建了一个模仿现有硬件/软件的软件,我应该如何称呼它?模拟器还是模拟器?

有人能从编程的角度来解释一下吗?

福利:这两个词在英语中有什么区别?(对不起,我的母语不是英语:))


当前回答

模拟是模拟外部可观察到的行为以匹配现有目标的过程。模拟机制的内部状态不必准确地反映它所模拟的目标的内部状态。

另一方面,仿真涉及到对目标的基本状态进行建模。一个好的仿真的最终结果是,仿真模型将模拟它所模拟的目标。

理想情况下,您应该能够查看模拟并观察到您在查看原始目标时也会看到的属性。在实践中,由于性能原因,模拟可能存在一些快捷方式——也就是说,模拟的某些内部方面实际上可能是模拟。

MAME是一款街机游戏模拟器;Hyperterm是一个(不是很好的)终端仿真器。没有必要为街机或终端详细建模以获得所需的模拟行为。

《Flight Simulator》是一款模拟器;SPICE是一个电子模拟器。他们尽可能地模拟目标的每个细节,以表示目标在现实中的行为。

EDIT: Other responses have pointed out that the goal of an emulation is to able to substitute for the object it is emulating. That's an important point. A simulation's focus is more on the modeling of the internal state of the target -- and the simulation does not necessarily lead to emulation. In particular, a simulation may run far slower than real-time. SPICE, for example, cannot substitute for an actual electronics circuit (even if assuming there was some kind of magical device that perfectly interfaces electrical circuits to a SPICE simulation.) A simulation does not always lead to emulation --

其他回答

我不认为模拟器和模拟器可以比较。两者都模仿某些东西,但不是同一推理范围的一部分,它们不在同一上下文中使用。

简而言之:模拟器被设计用来复制原始程序的某些特性,甚至可以在真实环境中替换它。模拟器的设计不是为了复制原物的特征,而是为了在人类看来与原物相似。没有了原有的功能,仿真器无法在实际环境中代替原有的功能。

An emulator is a device that mimics something close enough so that it can be substituted to the real thing. E.g you want a circuit to work like a ROM (read only memory) circuit, but also wants to adjust the content until it is what you want. You'll use a ROM emulator, a black box (likely to be CPU-based) with a physical and electrical interfaces compatible with the ROM you want to emulate. The emulator will be plugged into the device in place of the real ROM. The motherboard will not see any difference when working, but you will be able to change the emulated-ROM content easily. Said otherwise the emulator will act exactly as the actual thing in its motherboard context (maybe a little bit slower due to actual internal model) but there will be additional functions (like re-writing) visible only to the designer, out of the motherboard context. So emulator definition would be: something that mimic the original, has all of its functional features, can actually replace it to some extend in the real world, and may have additional features not visible in the normal context.

A simulator is used in another thinking context, e.g a plane simulator, a car simulator, etc. The simulation will take care only of some aspect of the actual thing, usually those related to how a human being will perceive and control it. The simulator will not perform the functions of the real stuff, and cannot be sustituted to it. The plane simulator will not fly or carry someone, it's not its purpose at all. The simulator is not intended to work, but to appear to the pilot somehow like the actual thing for purposes other than its normal ones, e.g. to allow ground training (including in unusual situations like all-engine failure). So simulator definition would be: something that can appear to human, to some extend, like the original, but cannot replace it for actual use. In addition the pilot will know that the simulator is a simulator.

我认为我们不会看到ROM模拟器,因为ROM不与人类交互,我们也不会看到任何平面模拟器,因为在现实世界中,飞机无法有一个替代物来执行相同的功能。

在我看来,模拟器或模拟器中的模型可以是任何东西,并且不必与原始模型相似。一个ROM模拟器模型将很可能是软件而不是硬件,MS飞行模拟器不能比它更软件。

这两个术语的比较将与当前选择的答案(来自Toybuilder)相矛盾,后者将差异放在内部模型上,而我的建议是,差异在于假的是否可以用于执行实际世界中的实际功能(确实在某些可接受的范围内)。

注意,飞机模拟器还必须模拟地球、太阳、风等,这些都不是飞机的一部分,所以飞机模拟器必须模拟飞机的某些方面,以及飞机的环境,因为它不是在这个实际环境中使用,而是在一个训练室中使用。

This is a big difference with the emulator which emulates only the orginal, and its purpose is to be used in the environment of the original with no need to emulate it. Back to the plane context... what could be a plane emulator? Maybe a train that will connect two airports -- actually two plane steps -- carrying passengers, with stewardesses onboard, with car interior looking like an actual plane cabin, and with captain saying "ladies and gentlemen our altitude is currenlty 10 kms and the temperature at our destination is 24°C". Its benefit is difficult to see, hum...

总之,模拟器是一个真实的东西,旨在工作,模拟器是一个假的,旨在欺骗用户。

在计算机科学中,模拟和仿真都从相同的输入产生与原始系统相同的输出;但是,仿真也使用相同的过程来实现它,并且由相同的材料制成。模拟使用与原始系统不同的进程。同样值得注意的是术语复制,它是两者的中间——使用相同的过程,但由不同的材料制成。

所以如果我想在我的PC上运行我的旧《超级马里奥兄弟》游戏,我会使用SNES模拟器,因为它使用相同或类似的计算机代码(进程)来运行游戏,并使用相同或类似的材料(硅芯片)。 然而,如果我想在我的个人电脑上驾驶波音747喷气式飞机,我会使用飞行模拟器,因为它使用的过程与原来的完全不同(没有实际的机翼、升力或空气动力学!)。

以下是摘自计算机科学术语表的准确定义:

模拟是一种系统模型,它捕捉了系统输入和输出之间的功能连接,但不一定基于与系统本身相同或相似的过程。

复制是一种系统模型,它捕获系统输入和输出之间的功能连接,并基于与系统本身相同或相似的过程。

仿真是某种系统的模型,它捕获系统输入和输出之间的功能连接,基于与该系统相同或类似的过程,并且由与该系统相同的材料构建。

参考文献:The Open University, M366 Glossary 1.1, 2007

模拟器是一个比模拟器更广泛的东西,似乎这个术语的双重性在上面的帖子中被过度考虑了。

模拟器

人们决定在“计算机世界”中使用一个新词模拟,当他们开始以直接的方式替换现有系统的一些硬件部分时——模仿它们的行为,并依赖于计算性质,以确保不会破坏某些东西,并使所有东西都处于等效状态。所以我们模拟了这个部分!(整个系统仍然像以前一样工作)

模拟器通常在数字领域的狭义上用于替代和虚拟化——以数字形式作为一个软件——以前已知和存在的东西(虚拟芯片、电路板、电子设备)。因此,当世界变得更加数字化,并将模拟器这个词带给大众时,大众也为它增加了不确定性(或额外的原因)。

模拟器

首先,我看到许多关于模拟器可以代替真实的东西的评论,但是模拟器不能。

但是飞行模拟器是用来做真实的事情的——它训练飞行员,提高他们的技能和知识,它取代了昂贵的真实飞机,节省了很多钱。我们不能只是说一个飞机模拟器,因为我们有内心的感觉,这远远不止于此,所以我们叫它模拟器:)飞机模拟器可以包含模拟雷达或应答器,这是真的。

相反,模拟器用于分析和研究(模拟器用于真实的东西),但这种分析和研究并不比模拟GSM板更真实(在我们生活的信息时代更是如此)。分析为业务增加了价值,降低了成本或指出了不低于替换(模拟)硬件的利润。

模拟器类似于对我们由于某些原因(成本、技术、物理不可能性)而无法获得的东西进行建模。它通常是模拟一些新的、无形的、复杂的或者我们不太了解的东西,比如市场、天气、燃烧、用户。这就是飞行,黑洞,股票交易,模拟。

最后:

模拟器比模拟器更广泛 模拟器倾向于模拟/建模更多的全局过程/事物,并具有缩小模仿范围的能力(例如,带有代表一些已知模型的预置的电容器模拟器) 模拟器倾向于模仿具有特定规格、已知特征和属性的特定硬件设备(例如SNES模拟器、Intel 8087或Roland TB-303)

至于词源

它们都来自拉丁语,意思是:

“仿效”是“平等”(看起来更有侵略性和更直接-竞争) 模拟是“相似”(看起来更狡猾和狡猾-模仿)

模拟是一种行为类似于其他事物,但以完全不同的方式实现的系统。它提供了系统的基本行为,但不一定遵守被模拟系统的所有规则。它的存在是为了让你了解事物是如何工作的。

模拟是一种行为完全类似于其他系统的系统,并且遵守所模拟系统的所有规则。它实际上是另一个系统的完全复制,甚至与仿真系统的输入和输出二进制兼容,但在与原始仿真系统的环境不同的环境中运行。规则是固定的,不能更改,否则系统会失败。

虚拟PC试图从程序员的角度模拟计算机,但同时,它也从电气工程师的角度模拟计算机。