Even though it doesn't matter which position within each table people sit at, we can include that information in our counting as long as we include it in the total number of arrangements too. Philosophically, the seats know which seat is which even if we don't care.
So there are 16 seats that can be sat in, and 16 people to sit in them. We could run through the people and each one chooses a seat, and then the next person chooses from the remaining seats etc. This argument gives 16! possible seating arrangements.
Now we need to count how many arrangements have the duplicated names together or apart.
First let's consider the number with the two Bens together:
The first Ben can sit in any one of 16 places. And then the second Ben has to sit at the same table, so that's 3 places. So far this is 16*3 ways. The remaining 14 people can sit anywhere in 14! ways so we have a total of 16*3*14! arrangements with the two Bens together.
This would be the same the number of arrangements with the two Sams together, and the number of arrangements with the two Katies together.
This is a total of 3*16*3*14! ways to have at least one pair of duplicate names together.
However, I have counted more than once the arrangements with more than one pair of duplicated names together.
Let's consider the ways with at least two pairs of duplicated names.
We've already considered the ones with two Bens together. Now let's place the Sams. The first Sam can either go at the same table as the Bens, or at a different table.
If the first Sam is at the same table as the Bens, then there are two seats to sit in. And then the second Sam has to sit in the last seat at this table. So that's 2 ways.
If the first Sam is at a different table as the Bens, then there are 12 seats to sit in. And then the second Sam has to sit in another seat at this same table, giving 3 choices.
In total we have 12*3 + 2 = 38 arrangements where the Sams sit together for each choice of where the Bens sit. There were 16*3 ways to seat the Bens together, so this is 16*3*38 ways to seat the Bens together and the Sams together. The remaining 12 people can be arranged in 12! ways, so we have in total 16*3*38 arrangements where the Bens and Sams are together.
This same counting would apply to sitting the Bens together and the Katies together, as well as the Sams together and the Katies together. So we have 3*16*3*38*12! arrangements. These were all double-counted when we counted the arrangements with at least one pair, so we'll need to take them off the previous total.
So now we have 3*16*3*14! - 3*16*3*38*12! ways to seat the students so that at least one pair of duplicate names are seated together. Except we've taken off any with all three pairs together more times than they should be. So we should add them back again.
There were 16*3 ways to place the two Bens together.
If the two Sams were at the same table as the Bens, then there were 2 ways to do this. And then the first Katie has 12 choices, while the second Katie has 3 choices. This is 2*12*3 ways for each way of placing the Bens.
If the two Sams were at a different table from the Bens, then there were 12*3 ways to do this. If the first Katie was at a table with Sams or Bens, there are 4 choices for a place to sit. Then the second Katie has one choice. On the other hand if the first Katie was at a table with no pair already there, then there are 8 choices for a place to sit, and 3 choices for the second Katie. So the Katies can be seated in 4*1 + 8*3=28 ways. Combining this with the Sams gives 12*3*28 ways for each way of placing the Bens.
So in total we have 2*12*3 + 12*3*28 = 12*3*30 ways to place the Sams and Katies, giving 16*3*12*3*30 ways to place the Bens, the Sams and the Katies.
After this, the remaining 10 people can be seated in 10! ways.
So this gives 16*3*12*3*30*10! arrangements with the Bens, the Sams and the Katies together.
Hence the number of ways to seat people and have at least one pair of duplicated names together is
3*16*3*14! - 3*16*3*38*12! + 16*3*12*3*30*10!
Therefore the number of ways to seat people and have NO pairs of duplicated names together is
16! - 3*16*3*14! + 3*16*3*38*12! - 16*3*12*3*30*10!
Thus the probability of having no pairs of duplicated names is:
(16! - 3*16*3*14! + 3*16*3*38*12! - 16*3*12*3*30*10!)/16! = 2584/5005
And the probability of having all pairs of duplicated names together is:
16*3*12*3*30*10!/16! = 9/1001