如图,AD⊥AB,BC⊥AB,点P在AB上,且PD=PC.已知BC=2AD=2,AB=4.求AP,PC的长.