It is a wired design as these two materials are not to be used under the same service condition. If P1 can serve the purpose there would be no reason to select the costly P15E and if P15E is really necessary, P1 will not serve in the condition.
For length of the transition piece I'm afraid that you can not find it in Code book of B31.1. Similar topic such as minimum distance between two butt welds had been discussed somewhere else in this forum and it is believed to be a workmanship issue up to the requirement of the owner/customer other than to be mandated by ASME Codes.
See if anyone else on this forum can give more ideas.
Good luck~
J Z