∵∠BPD=∠BPC+∠CPD=∠A+∠ABP,∠BPC=∠A
∴∠CPD=∠ABP
∵∠D=∠A
∴△ABP∽△DPC
∴AP/CD=AB/PD
∴AB*CD=AP*PD
设AP=x
则4=x(5-x)
x²-5x+4=0
x1=1,x2=4
所以AP=1或AP=4
∵∠BPD=∠BPC+∠CPD=∠A+∠ABP,∠BPC=∠A
∴∠CPD=∠ABP
∵∠D=∠A
∴△ABP∽△DPC
∴AP/CD=AB/PD
∴AB*CD=AP*PD
设AP=x
则4=x(5-x)
x²-5x+4=0
x1=1,x2=4
所以AP=1或AP=4