4
$\begingroup$

I have been wiring my house with ethernet cables, and was testing the connections with a simple ethernet tester: you plug two cable ends into the tester, and it tells you if the cable ends are connected to each other and the 8 wires are in the correct order.

Let's say you have unlimited patch cables which are known good, and you want to verify that all wiring has been done as intended. You also want to do it without walking between buildings any more than is necessary.

The wiring is between two buildings, A and B, and there are 6 lines to test, 6 ports in one building, and 6 ports in the other: A(1-6) and B(1-6). All lines are wired from one building to the other: line 1 connects port A1 to port B1, line 2 connects A2 to B2, and so on.

For example, you could patch A1 and A2 together and go to building B to test that B1-B2 are connected as expected. However, this is not enough to prove that lines 1 and 2 are wired correctly, because if the connections cross, (B1-A2-patch-A1-B2) you'd get a false positive.

What's the minimal number of trips between buildings you have to do to make sure that all the wiring works, and every line is connected as expected?

$\endgroup$
7
  • $\begingroup$ Can you patch 3 wires together? Or only 2? $\endgroup$
    – Dr Xorile
    Dec 6, 2018 at 17:39
  • $\begingroup$ @DrXorile a patch cable has two ends, each end can connect to a port, or to the tester. $\endgroup$
    – Bass
    Dec 6, 2018 at 20:36
  • $\begingroup$ Sorry someone has edited out the fact we are not just testing if wires are connected to each other, but if in fact, the 4 pairs inside an ethernet cable are in the correct order. To also confirm we know that A1 is cabled to B1 etc. @Bass what was the reason for removing that detail? $\endgroup$ Dec 6, 2018 at 21:27
  • $\begingroup$ Sorry, I thought it was inconsequential, but seems like I have misunderstood the question. Please re-edit the puzzle as you see fit, I was only trying to make things easier to read, since most of the folks here aren't net techs, and don't know how the wiring is supposed to be connected. $\endgroup$
    – Bass
    Dec 7, 2018 at 0:20
  • $\begingroup$ Possible duplicate of Labeling wires in a *damaged* bundle $\endgroup$
    – boboquack
    Aug 26, 2019 at 4:08

2 Answers 2

1
$\begingroup$

Suppose you have the wires in a are 1-6. We'll call the wiring at b 1',2',...,6'. Then there are $6!=720$ possibilities on the other side for how the wires come out.

I believe it can be done in two trips:
1. You first connect 2 pairs at location a (1-2, 3-4) and walk across to b. This reduces it to 16 possibilities. You will know what the three pairs are, but will not know which pair is which (apart from whether it's connected or not) or which order. (1,2)(3,4)(5,6); (3,4)(1,2)(5,6). Because you don't know which wire is which, each of these pairs can be either way around, so it's 8 possibilities per group or 16 possibilities.
2. Next, you connect e.g. 2'-3' and 4'-5' at b and go back to test them at a. This reduces it to 1 possibility. E.g. suppose you discover that 1 and 6 are not connected while 2-3 and 4-5 are connected. Then you know that b is 1,2,3,4,5,6. Or if 4 and 6 are not connected while 1-3 and 2-5 are connected, then you know that b is 4,3,1,2,5,6. Etc.

I suspect this is optimal.

$\endgroup$
2
  • $\begingroup$ I don't think this detects whether the line from A6 to B6 is faulty or not? $\endgroup$
    – Bass
    Dec 6, 2018 at 20:34
  • $\begingroup$ Yeah, I misunderstood the question $\endgroup$
    – Dr Xorile
    Dec 6, 2018 at 21:48
1
$\begingroup$

It requires ...

1 trip only

... to find out that (1) either all are good or all are opposite or that (2) some are wired wrongly

How to find this ?

In room A, connect A1 to A2, A3 to A4 & A5 to A6.
Now go to room B and check by all combinations of Pairs, say B1 to B{2,3,4,5,6} which forms chains of 4 end Points.
If less than 3 Pairs show good, then some are bad. We figured that in one trip.
No more than 3 Pairs can show good. If exactly 3 Pairs show good, then connect one end Point of a Pair to one end Point of another Pair, and connect one end Point of the last Pair to either of the remaining end Points, which gives a chain of all 12 end Points.
If this chain shows good, then either all are good or all are opposite. We have figured that in one trip.

$\endgroup$
8
  • $\begingroup$ The cables are all known to be good. It's the order which is the issue. $\endgroup$
    – Dr Xorile
    Dec 6, 2018 at 18:08
  • $\begingroup$ @DrXorile , If the order is the issue and all are opposite, then how can we ever find out ? $\endgroup$
    – Prem
    Dec 6, 2018 at 18:24
  • $\begingroup$ @DrXorile , In the last line, OP says "What the minimal number of trips you would have to do to test all lines are good?" , which I assume, means to find if all lines are good, which implies that it is not known if all lines are good. $\endgroup$
    – Prem
    Dec 6, 2018 at 18:28
  • 1
    $\begingroup$ Ahh. I guess I misunderstood the question then. $\endgroup$
    – Dr Xorile
    Dec 6, 2018 at 19:14
  • $\begingroup$ @DrXorile , no Problem, but I would not be surprised if the question wording got changed and this valid answer becomes invalid $\endgroup$
    – Prem
    Dec 6, 2018 at 19:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.