Loading [MathJax]/jax/output/HTML-CSS/fonts/TeX/fontdata.js

 Boolean algebra  - In mathematics and mathematical logicBoolean algebra is the branch of algebra in which the values of the variables are the truth values true and false, usually denoted 1 and 0 respectively. Instead of elementary algebra where the values of the variables are numbers, and the prime operations are addition and multiplication, the main operations of Boolean algebra are the conjunction and denoted as ∧, the disjunction or denoted as ∨, and the negation not denoted as ¬. It is thus a formalism for describing logical relations in the same way that elementary algebra describes numeric relations.

NOT 
True = false
false = true

BOOLEAN GATE  
               

                                                  electrode in-current
                                                   |  
                                                   /
control wire (input - on) -----|
                                                   \ output - on

                                                    electrode in-current
                                                    |
                                                    / 
control wire (input - off) -----|
                                                    \ output - off

 

NOT ▶●

     
                                                   electrode in-current
                                                   |------ output (off)                            
                                                   / 
control wire (input - on) -----|
                                                   \
                                                   |
                                                   V
                                                   ground
                                                  

                                                   electrode in-current
                                                   |------> output (on)                            
                                                   / 
control wire (input - off) -----|
                                                   \
                                                   |
​​                                                   ground

 

AND ⍾

True + True = True
False + False = False
False + True = False
True + False = False

                         
                                                    current
                                                    |                        
                                                   / 
 Transistor (input A on)  -----|
                                                   \
                                                   |
                                                  / 
 Transistor (input B on)  -----|
                                                   \
                                                   |Output
                                                   V

 

                                                    current
                                                    |                        
                                                   / 
 Transistor (input A off)  -----|
                                                 X
                                                   |
                                                  / 
 Transistor (input B on)  -----|
                                                   \
                                                   |Output
                                                   V

                                                    current
                                                    |                        
                                                   / 
 Transistor (input A on)  -----|
                                                   \
                                                   |
                                                   / 
 Transistor (input B off)  -----|
                                                  X
                                                   |Output
                                                   V

 

OR  ⍲

                                                                                                        

                                                            current                                                              
                                                     _____|_____                    
                                                   /                   |
 Transistor (input A on)  -----|                    |
                                                   \                   |
                                                   |                  | 
                                                   |                 / 
 Transistor (input B on)  -------(-------------|
                                                   |                 \ 
                                                   |__________|
                                                            |
                                                            V

                                                           current
                                                     ____|______                    
                                                   /                   |
 Transistor (input A off)  -----|                    |
                                                   X                  |
                                                   |                  | 
                                                   |                 / 
 Transistor (input B on)  -------(-------------|
                                                   |                 \ 
                                                   |__________|
                                                            |
                                                            V

                                                           current
                                                     ____|______                    
                                                   /                   |
 Transistor (input A on)  -----|                    |
                                                   \                  |
                                                   |                  | 
                                                   |                 / 
 Transistor (input B off)  -------(-------------|
                                                   |                X
                                                   |__________|
                                                            |
                                                            V

                                                           current
                                                     ____|______                    
                                                   /                   |
 Transistor (input A off)  -----|                    |
                                                   X                   |
                                                   |                  | 
                                                   |                 / 
 Transistor (input B off)  -------(-------------|
                                                   |                X
                                                   |__________|
                                                            |
                                                            X

 

XOR GATE IS NOT COVERED

Converting between base 10 and 2


BASE 10
263
100 X 2
+
10   X 6
+
1     X 3

BASE 2

101
1 X 1
+
2 X 0
+
4 X 1   = 5

another example

11011

1  X  1
+
2  X  0
+
4  X  1
+​
8  X   1​​​​​​ = 27


 

8Bit size = Byte
 

 

      1           2          3              4            5       6        7      8
 _________________________________________________________
|   128's |  64's |  32's  |  16's  |  8's  |  4's  |  2's  |  1's  |
|________|______|______|______|_____|_____|_____|_____|
|      1            1          1          1          1         1         1       1   = 255       in UTF8 is ÿ

|______________________________________________________
_________________________________________________________
|   128's |  64's |  32's  |  16's  |  8's  |  4's  |  2's  |  1's  |
|________|______|______|______|_____|_____|_____|_____|
|      0          1          1          1          1         1         1       1   =  127       in ASCII is DEL
|______________________________________________________
_________________________________________________________
|   128's |  64's |  32's  |  16's  |  8's  |  4's  |  2's  |  1's  |
|________|______|______|______|_____|_____|_____|_____|
|      0          1          1          1          0        1         1       1   =  119      in ASCII is w
|______________________________________________________

_________________________________________________________
|   128's |  64's |  32's  |  16's  |  8's  |  4's  |  2's  |  1's  |
|________|______|______|______|_____|_____|_____|_____|
|      0          1          1          0          0        0        1       1   =  99     in ASCII is c
|______________________________________________________

16bit encoding came out later.
32bit & 64bit are the standard today.

TAKE NOTE

This is just like in decimal count 
 

The number 1,654 is:
 __________________________________
|  1000's  |  100's  |  10's  |  1's  |
|_________|________|______|_____|
|      1            6              5          4          
|_________________________________

A number at each place is just a multiplacation of 10.

Representing floating numbers:

A floating number, lets say 625.9 can be represented in the following way
0.6259 * 10^3 
   |___|           ^

       |              | exponent
Segnificant

Floating numbers are represented in a 32bit number storage.

______________________________________________________________________________________________________________________________________________________________
|  1 | 2  | 3 | 4 | 5  | 6 |  7  | 8  | 9 | 10  | 11 | 12 | 13  | 14 |  15  | 16  |  17 | 18 | 19 | 20 | 21  | 22 |  23  | 24 |25 | 26  | 27 | 28 | 29 | 30 |  31  | 32  |

|__||_______________________________||______________________________________________________________________________________________________________________|
   ^                                ^                                                                                                            ^
   |                                |                                                                                                            |
  sign                exponent                                                                                              Segnificant
   (-/+)                   8bits                                                                                                         23bits  

  1bit