575:
446:
427:
420:
413:
566:
subtracts depending on a control signal. It is also possible to construct a circuit that performs both addition and subtraction at the same time.
463:
1275:
862:
The adder–subtractor above could easily be extended to include more functions. For example, a 2-to-1 multiplexer could be introduced on each
232:
510:
1290:
482:
337:
529:
815:
for the bit arriving at the adder as the multiplexer solution does since the XOR gate output will be what the input bit is when
489:
467:
1285:
496:
78:
367:
478:
1280:
362:
1191:
By adding more logic in front of the adder, a single adder can be converted into much more than just an adder—an
390:
331:
227:
456:
395:
138:
1209:
1192:
844:
838:
574:
559:
400:
128:
133:
503:
260:
1204:
884:
638:
579:
551:
385:
108:
73:
68:
265:
153:
123:
1245:
308:
303:
298:
293:
288:
283:
222:
1214:
313:
242:
158:
148:
859:
input to the adder–subtractor above would be one such control line from the control unit.
543:
204:
199:
58:
1219:
1269:
53:
848:
237:
812:
684:
445:
17:
1224:
724:
that is also connected to the initial carry, then the modified adder performs
555:
194:
143:
118:
113:
63:
793:
as positive or negative without using a multiplexer on each bit is to use an
578:
A 4-bit ripple-carry adder–subtractor based on a 4-bit adder that performs
794:
656:
852:
912:
to a 4-to-1 with the third input being zero, then replicating this on
439:
851:
decides which operations an ALU should perform (based on the
908:
A further step would be to change the 2-to-1 multiplex on
804:
The second input for each XOR gate is the control input
801:
The first input to the XOR gate is the actual input bit
676:, which is easy to do with a slightly modified adder.
651:, two's complement theory says to invert each bit of
470:. Unsourced material may be challenged and removed.
855:being executed) and sets the ALU operation. The
919:thus yielding the following output functions:
421:
8:
876:; this could be used (in conjunction with
428:
414:
96:
26:
530:Learn how and when to remove this message
776:and 1 yields the desired subtraction of
573:
1236:
383:
360:
329:
281:
258:
220:
192:
174:
106:
94:
51:
34:
683:input bit on the adder with a 2-to-1
7:
843:Adders are a part of the core of an
468:adding citations to reliable sources
869:that would switch between zero and
637:. Then, assume the numbers are in
25:
833:Role in the arithmetic logic unit
822:and the inverted input bit when
562:). Below is a circuit that adds
550:is a circuit that is capable of
444:
233:Booth's multiplication algorithm
766:and the carry in is 1. Adding
455:needs additional citations for
797:to precede each bit instead.
1:
1246:"Binary Adder and Subtractor"
760:input to the adder is really
338:Multiply–accumulate operation
79:Signed number representations
1276:Telecommunications equipment
368:Category:Computer arithmetic
1307:
836:
789:A way you can mark number
659:then add one. This yields
363:Category:Binary arithmetic
1291:Arithmetic logic circuits
1244:Teja, Ravi (2021-04-21).
35:Arithmetic logic circuits
749:This works because when
558:numbers (in particular,
332:Kochanski multiplication
228:Multiplication algorithm
961:inputs set to zero and
937:inputs set to zero and
811:This produces the same
720:that has control input
74:Two's complement number
69:Ones' complement number
1033:input set to zero and
1010:input set to zero and
608:
1210:Carry-lookahead adder
845:arithmetic logic unit
839:Arithmetic logic unit
577:
401:Mechanical calculator
129:Carry-lookahead adder
1286:Adders (electronics)
464:improve this article
171:Adder–subtractor (±)
1205:Adder (electronics)
30:Part of a series on
994:input set to zero)
981:input set to zero)
679:By preceding each
641:. Then to perform
609:
479:"Adder–subtractor"
334:(exponentiation)
266:Division algorithm
154:Carry-select adder
124:Ripple-carry adder
1281:Binary arithmetic
1180:set to zero; and
1152:set to zero; and
1123:set to zero; and
1095:set to zero; and
947:1 (with both the
923:0 (with both the
738:subtraction when
540:
539:
532:
514:
438:
437:
346:
345:
284:Bitwise operation
223:Binary multiplier
139:Kogge–Stone adder
16:(Redirected from
1298:
1260:
1259:
1257:
1256:
1241:
1215:Carry-save adder
1186:
1158:
1137:
1129:
1101:
1080:
1073:
1062:
1051:
1039:
1025:
1016:
1002:
967:
943:
904:
902:
885:two's complement
882:
828:
821:
785:
775:
765:
755:
744:
734:
716:
675:
673:
650:
639:two's complement
636:
606:
592:
580:two's complement
548:adder–subtractor
544:digital circuits
535:
528:
524:
521:
515:
513:
472:
448:
440:
430:
423:
416:
314:Bit manipulation
243:Dadda multiplier
177:Adder–subtractor
159:Carry-skip adder
149:Carry-save adder
134:Brent–Kung adder
97:
40:Quick navigation
27:
21:
18:Adder-subtracter
1306:
1305:
1301:
1300:
1299:
1297:
1296:
1295:
1266:
1265:
1264:
1263:
1254:
1252:
1250:Electronics Hub
1243:
1242:
1238:
1233:
1201:
1181:
1178:
1173:set to invert;
1171:
1153:
1150:
1145:set to invert;
1143:
1133:
1124:
1121:
1116:set to invert;
1114:
1096:
1093:
1088:set to invert;
1086:
1076:
1065:
1054:
1043:
1034:
1031:
1020:
1011:
1008:
997:
992:
979:
962:
959:
952:
938:
935:
928:
917:
898:
892:
883:) to yield the
877:
874:
867:
841:
835:
823:
816:
777:
771:
761:
750:
739:
729:
712:
710:
697:
669:
660:
642:
624:
615:-bit adder for
594:
587:
572:
536:
525:
519:
516:
473:
471:
461:
449:
434:
405:
382:
381:
372:
359:
358:
349:
342:
328:
327:
318:
280:
279:
270:
257:
256:
247:
219:
218:
209:
205:Half subtractor
200:Full subtractor
191:
190:
181:
173:
172:
163:
105:
104:
93:
92:
83:
59:Boolean algebra
50:
49:
23:
22:
15:
12:
11:
5:
1304:
1302:
1294:
1293:
1288:
1283:
1278:
1268:
1267:
1262:
1261:
1235:
1234:
1232:
1229:
1228:
1227:
1222:
1220:Adding machine
1217:
1212:
1207:
1200:
1197:
1189:
1188:
1176:
1169:
1160:
1148:
1141:
1131:
1119:
1112:
1103:
1091:
1084:
1074:
1063:
1052:
1041:
1029:
1018:
1006:
995:
990:
982:
977:
969:
957:
950:
945:
933:
926:
915:
872:
865:
837:Main article:
834:
831:
809:
808:
802:
747:
746:
736:
728:addition when
718:
717:
708:
702:
695:
571:
568:
538:
537:
452:
450:
443:
436:
435:
433:
432:
425:
418:
410:
407:
406:
404:
403:
398:
393:
388:
379:
378:
377:
374:
373:
371:
370:
365:
356:
355:
354:
351:
350:
348:
347:
344:
343:
341:
340:
335:
325:
324:
323:
320:
319:
317:
316:
311:
306:
301:
296:
291:
286:
277:
276:
275:
272:
271:
269:
268:
263:
261:Binary Divider
254:
253:
252:
249:
248:
246:
245:
240:
235:
230:
225:
217:Multiplier (×)
216:
215:
214:
211:
210:
208:
207:
202:
197:
189:Subtractor (−)
188:
187:
186:
183:
182:
180:
179:
170:
169:
168:
165:
164:
162:
161:
156:
151:
146:
141:
136:
131:
126:
121:
116:
111:
102:
101:
100:
90:
89:
88:
85:
84:
82:
81:
76:
71:
66:
61:
56:
47:
46:
45:
42:
41:
37:
36:
32:
31:
24:
14:
13:
10:
9:
6:
4:
3:
2:
1303:
1292:
1289:
1287:
1284:
1282:
1279:
1277:
1274:
1273:
1271:
1251:
1247:
1240:
1237:
1230:
1226:
1223:
1221:
1218:
1216:
1213:
1211:
1208:
1206:
1203:
1202:
1198:
1196:
1194:
1184:
1179:
1172:
1165:
1161:
1156:
1151:
1144:
1136:
1132:
1127:
1122:
1115:
1108:
1104:
1099:
1094:
1087:
1079:
1075:
1072:
1068:
1064:
1061:
1057:
1053:
1050:
1046:
1042:
1037:
1032:
1023:
1019:
1014:
1009:
1000:
996:
993:
986:
983:
980:
973:
970:
965:
960:
953:
946:
941:
936:
929:
922:
921:
920:
918:
911:
906:
901:
896:
890:
886:
880:
875:
868:
860:
858:
854:
850:
846:
840:
832:
830:
826:
819:
814:
807:
803:
800:
799:
798:
796:
792:
787:
784:
780:
774:
769:
764:
759:
753:
742:
737:
732:
727:
726:
725:
723:
715:
707:
703:
701:
694:
690:
689:
688:
686:
682:
677:
672:
667:
663:
658:
654:
649:
645:
640:
635:
631:
627:
622:
618:
614:
605:
601:
597:
590:
585:
581:
576:
569:
567:
565:
561:
557:
553:
549:
545:
534:
531:
523:
512:
509:
505:
502:
498:
495:
491:
488:
484:
481: –
480:
476:
475:Find sources:
469:
465:
459:
458:
453:This article
451:
447:
442:
441:
431:
426:
424:
419:
417:
412:
411:
409:
408:
402:
399:
397:
394:
392:
389:
387:
384:
376:
375:
369:
366:
364:
361:
353:
352:
339:
336:
333:
330:
322:
321:
315:
312:
310:
307:
305:
302:
300:
297:
295:
292:
290:
287:
285:
282:
274:
273:
267:
264:
262:
259:
251:
250:
244:
241:
239:
236:
234:
231:
229:
226:
224:
221:
213:
212:
206:
203:
201:
198:
196:
193:
185:
184:
178:
175:
167:
166:
160:
157:
155:
152:
150:
147:
145:
142:
140:
137:
135:
132:
130:
127:
125:
122:
120:
117:
115:
112:
110:
107:
99:
98:
95:
87:
86:
80:
77:
75:
72:
70:
67:
65:
62:
60:
57:
55:
54:Binary number
52:
44:
43:
39:
38:
33:
29:
28:
19:
1253:. Retrieved
1249:
1239:
1190:
1182:
1174:
1167:
1163:
1154:
1146:
1139:
1134:
1125:
1117:
1110:
1106:
1097:
1089:
1082:
1077:
1070:
1066:
1059:
1055:
1048:
1044:
1035:
1027:
1021:
1012:
1004:
998:
988:
984:
975:
971:
963:
955:
948:
939:
931:
924:
913:
909:
907:
899:
894:
888:
878:
870:
863:
861:
856:
849:control unit
842:
824:
817:
810:
805:
790:
788:
782:
778:
772:
767:
762:
757:
751:
748:
740:
730:
721:
719:
713:
705:
699:
692:
680:
678:
670:
665:
661:
652:
647:
643:
633:
629:
625:
620:
616:
612:
610:
603:
599:
595:
588:
583:
570:Construction
563:
547:
541:
526:
517:
507:
500:
493:
486:
474:
462:Please help
457:verification
454:
238:Wallace tree
176:
847:(ALU). The
813:truth table
685:multiplexer
556:subtracting
278:Bitwise ops
255:Divider (÷)
1270:Categories
1255:2022-06-01
1231:References
1225:Subtractor
1026:(with the
1003:(with the
987:(with the
974:(with the
611:Having an
490:newspapers
357:Categories
309:Bit shifts
195:Subtractor
144:Ling adder
119:Full adder
114:Half adder
91:Components
64:Logic gate
704:Input 1 (
691:Input 0 (
593:to yield
520:June 2022
103:Adder (+)
1199:See also
795:XOR gate
657:NOT gate
380:See also
326:See also
853:op code
687:where:
655:with a
623:, then
504:scholar
1166:(with
1138:(with
1109:(with
1081:(with
891:since
560:binary
552:adding
506:
499:
492:
485:
477:
48:Theory
711:) is
698:) is
586:when
546:, an
511:JSTOR
497:books
109:Adder
954:and
930:and
756:the
735:, or
619:and
483:news
1193:ALU
1185:= 1
1157:= 0
1128:= 1
1100:= 0
1038:= 1
1024:+ 1
1015:= 1
1001:+ 1
966:= 1
942:= 0
903:+ 1
887:of
881:= 1
827:= 1
820:= 0
770:to
754:= 1
743:= 1
733:= 0
674:+ 1
591:= 1
582:on
554:or
542:In
466:by
396:AGU
391:GPU
386:FPU
304:XOR
294:AND
289:NOT
1272::
1248:.
1195:.
1069:−
1058:−
1047:+
905:.
897:=
829:.
786:.
781:−
668:+
664:=
646:−
632:+
628:=
602:−
598:=
564:or
299:OR
1258:.
1187:)
1183:D
1177:i
1175:A
1170:i
1168:B
1164:B
1162:−
1159:)
1155:D
1149:i
1147:A
1142:i
1140:B
1135:B
1130:)
1126:D
1120:i
1118:B
1113:i
1111:A
1107:A
1105:−
1102:)
1098:D
1092:i
1090:B
1085:i
1083:A
1078:A
1071:A
1067:B
1060:B
1056:A
1049:B
1045:A
1040:)
1036:D
1030:i
1028:A
1022:B
1017:)
1013:D
1007:i
1005:B
999:A
991:i
989:A
985:B
978:i
976:B
972:A
968:)
964:D
958:i
956:B
951:i
949:A
944:)
940:D
934:i
932:B
927:i
925:A
916:i
914:B
910:A
900:A
895:A
893:−
889:A
879:D
873:i
871:B
866:i
864:B
857:D
825:D
818:D
806:D
791:A
783:A
779:B
773:A
768:B
763:A
758:A
752:D
745:.
741:D
731:D
722:D
714:A
709:1
706:I
700:A
696:0
693:I
681:A
671:A
666:B
662:S
653:A
648:A
644:B
634:B
630:A
626:S
621:B
617:A
613:n
607:.
604:A
600:B
596:S
589:D
584:A
533:)
527:(
522:)
518:(
508:·
501:·
494:·
487:·
460:.
429:e
422:t
415:v
20:)
Text is available under the Creative Commons Attribution-ShareAlike License. Additional terms may apply.