Project Overview
The purpose of this project was to create a voting machine that could more efficiently decide a popular vote between a president, vice president, secretary and treasurer. In order to win the popular vote, you need the majority of the members to vote yes, however a tie is possible since there are 4 members. To solve this, we made it so that the president is the tie breaker, which means that whatever side the president took during the tie wins the popular vote. Our constraints were that we could only use 2-input AND and OR gates, as well as 2 input invertors.
Problem Conception
This is the truth table. The purpose of this truth table was to give an un-simplified logic expression that would represent what votes are necessary for the decision to pass. If a member voted "yes" then they got a 1 under their column, if they voted "no" then they got a zero. If the decision passed, it got a one under the D column, if it didn't pass it got a zero. The relationship between the number of outputs and the number of rows is 2^X. So since we had 4 inputs, we had 16 rows since 2^4 equals 16. If you observe the table, it shows that if there is a tie the president is the deciding vote. Which means if there is a 1 under the P column and a 1 under any other column, the decision will always pass.
Based on the truth table, I got the expression below. It is in SOP form. I got it by finding the midterms of all the input combinations that passed. I would rather have it in SOP form because it makes it easier since you can pull it straight from the truth table. |
Un-simplified Circuit
This is my un-simplified circuit. It consists of 4 invertor gates, 24 AND gates, and 7 OR gates. Which means in order to build this circuit, you would need 1 inverter chip, 6 AND chips, and 2 OR chips. This was time consuming since you needed a lot of gates and you needed to connect them all to the right places.
Boolean Algebra
This is my Boolean algebra. The purpose of Boolean algebra is to create an easier, more cost efficient version of the un-simplified version. So by using the laws and theorems of Boolean algebra, I was able to come up with the expression VST+PV+PS+PT.
This expression was a lot easier to build on multi sim and it was more efficient.
|
Simplified Circuit
This is my simplified circuit. All that was required for this one was 5 AND gates and 3 OR gates, no invertors. So in order to breadboard, you would only need 2 AND chips and one OR chip. That is because 4 gates are in each chip.
The simplified circuit was definetly easier to build and it is more efficient because it only requires 8 gates instead of 35 gates. This is huge because not only would you have fewer gates, but you would have fewer chips due to the fewer gates. Which means that a company would save a lot of money ecspecially if these were mass produced. It was also be quicker to run and it would be easier to detect any problems since there isn't so many gates.
Bill of materials
Bread Boarding
These 3 pictures are my breadboard. This breadboard is supposed to be assembled like the unsimplified circuit. Which means that there might have been a simpiler way to build this and have it perform the same function
My first breadboarding experience was awful. My first issue was that I had the green breadboard companion connected to close to the 5v, and this can't happen. Which meant that I had to move the companion over and then move all the wires over accordingly. When I did this some of the wires came undone and I forgot where they were supposed to go, so eventually I had to take everything apart and retry, but by then I had lost my train of thought. I eventually finished it though and everything was alright. But I have definetly learned some skills from my mistakes and I hope not to make the same mistakes again in the future.
Conclusion
I have 2 major "takeaways" from this project. One of them being realizing how useful Boolean algebra is and how much easier it is to build a simplified circuit than an unsimplified one. It also helped me realize how much more cost efficient they can be in the real world, since they require less work due to the smaller amounts of gates and chips needed. Unsimplified circuits are super stressful to build since it is so time consuming and it requires so many gates, and even though the Boolean algebra was difficult as well, it definetly payed off at the end when you had an easier expression to deal with compared to the unsimplified one pulled from the truth table, and then you got to build the simplified circuit. In other words, Boolean algebra may be hard with some expressions, but when you've already made the truth table based on your problem, filled in all your inputs, and then pulled out an expression, it will make your expression a lot easier to deal with, which will help you out when you are ready to build a finished circuit design. My other major takeaway from this project was learning from my mistakes with breadboarding, of course.