This reply may be late, but I'll post it anyway. To my memory there isn't any requirement as to the specific positioning of thermocouples for heat treat in B31.3, notwithstanding any correction from someone with more knowledge and code in hand. It is important however that the homogeneity, or lack thereof, of the inevitable temperature gradient be properly demonstrated and controlled. Pipe size, wall thickness, thermal conductivity, hardenability, number of pieces in the batch, variability of pieces in the batch, location of heat source, type of heat source, temperature ramping rates, and most likely others, are all variables to be considered.
According to Cooperheat 7th Handbook of Stress Relieving, for pipes up to and including 10 inches, one thermocouple attached on the 6 o'clock position in horizontal pipes is sufficient. For pipes 12 inches and larger, two thermocouples, one on the 6 o'clock and the other one on the 12 o'clock positions are necessary. Never attach them on the 3 o'clock nor on the 9 o'clock positions. In vertical pipes, of course, you can attach them in any position.
Also according to the Handbook, the thermocouples leads must run along the pipe surface for at least 8 inches before bending outwards. The leads should be insulated by means of insulating ceramics beads.
The thermocouple end should be attached at a distance of 1/2 inch from the weld centerline. One way to do this is to tack weld a small piece of tube to the pipe, insert the thermocouple end into the tube and flatten it with a hammer. Of course, you can follow any other suitable method you can envision.
Giovanni S. Crisi
Sao Paulo - Brazil