Ingeniería eléctrica
Utilice System Modeler para construir y estudiar circuitos eléctricos, electrónica de potencia y maquinaria eléctrica. Combine componentes eléctricos y mecánicos para crear modelos de sistemas completos. Realice tareas de análisis y mida el rendimiento.
8-Bit Adder
Binary adders are digital circuits often used in computers for basic arithmetic operations. Using the digital library in the standard Modelica library, we have constructed an 8-bit adder that takes two 8-bit integers and calculates their sum.
Para ejecutar este ejemplo necesitará
Las versiones más recientes de System Modeler y Mathematica.
Por favor haga una selección:
Obtener unaprueba gratuita Continuar
con la descarga
The 8-Bit Adder Principle
The 8-bit adder adds the numbers digit by digit, as can be seen in the schematic diagram below. In this example, the integers 170 and 51 represent input a and b, respectively, and the resulting output is the sum 221. The first adder does not have any carry‐in, and so it is represented by a half adder (HA) instead of a full adder (FA).

This schematic diagram explains the principle of using half and full adders to calculate the sum of two 8-bit integers.
Going down one level in the calculator model, we can see the eight full adders where the output, c, of one adder constitutes the input, cin, of another. The rightmost adder is in practice a half adder, since the SET component gives a carry‐in of 0. The other adder inputs, denoted a and b, are binary digits that are converted from the original integers. The last step at the bottom of the diagram shows the conversion of the binary result to the final integer sum.
Simulation Result

The input to the calculator is varied using IntegerTable from the Modelica Standard Library. For each set of integers, the sum is calculated and simulated.
Wolfram System Modeler
Probar
Comprar
System Modeler está disponible en inglés
y japonés
para Windows, macOS y Linux »
¿Preguntas? ¿Comentarios? Contacte a un experto de Wolfram »