Truth Table to check if 4-Bit binary numbers are in the set?
If I understand you correctly then you just need a 5 column table indicating if a number is or isn't in a set? Assuming an output of 1 is true.


Set: {1, 2, 3, 5, 9, 11, 13, 14}
A/8 B/4 C/2 D/1 |   N   In Set
0   0   0   0   |   0   0/false
0   0   0   1   |   1   1/true
0   0   1   0   |   2   1/true
0   0   1   1   |   3   1/true
0   1   0   0   |   4   0/false
0   1   0   1   |   5   1/true
0   1   1   0   |   6   0/false
0   1   1   1   |   7   0/false
1   0   0   0   |   8   0/false
1   0   0   1   |   9   1/true
1   0   1   0   |   10  0/false
1   0   1   1   |   11  1/true
1   1   0   0   |   12  0/false
1   1   0   1   |   13  1/true
1   1   1   0   |   14  1/true
1   1   1   1   |   15  0/false


I'm not as experienced at sleuthing out the logic that drives the last column, but hopefully this will help. Drawing the output as squares of different dimensions can help with visualization of patterns. My thought process usually involves finding an expression that makes some part of the table work without any false negatives (no incorrect trues) and then OR'ing all the parts together.


0 1 1 1 :  0- 3
0 1 0 0 :  4- 7
0 1 0 1 :  8-11
0 1 1 0 : 12-15


The first and second columns stand out here; which correspond to b0001,b0101,b1001,b1101 being true, the first and second bits being irrelevant and third and fourth being constant points you toward those (bXX01)


!C & D
0 1 0 0
0 1 0 0
0 1 0 0
0 1 0 0 


Fixing the first row could be done with C | D; but to capture limit it to only the first row requires negating A and B


!A & !B & ( C | D )
0 1 1 1
0 0 0 0
0 0 0 0
0 0 0 0
OR together the parts.
(!C & D) | (!A & !B & ( C | D ))
0 1 1 1
0 1 0 0
0 1 0 0
0 1 0 0


Close, but 11 and 14 (b1011 and b1110) are the two that are left


- - - -
- - - -
- - 0 1
- - 1 0


Which looks just like an XOR function. B XOR D (when A and C are true).


A & C & (B xor D)
0 0 0 0
0 0 0 0
0 0 0 1
0 0 1 0
OR together the parts
(!C & D) | (!A & !B & ( C | D )) | (A & C & (B xor D))
0 1 1 1
0 1 0 0
0 1 0 1
0 1 1 0