Calculation of the side apothem of a pyramid
We can calculate the side apothem of the pyramid by knowing the height and the apothem of the base, applying Pythagoras' theorem in the shaded triangle: $$$\text{Ap}=\sqrt{h^2+\text{ap}^2}$$$
Calculation of the side apothem of a truncated pyramid
We calculate the side apothem of the truncated pyramid by, knowing the height, the apothem of the biggest base and apothem of the least base, applying the Pythagoras' theorem in the shaded triangle: $$$\text{Ap}=\sqrt{h^2+(\text{ap}_2-\text{ap}_1)^2}$$$
Calculation of the side edge of a pyramid
We calculate the side edge of the pyramid by, knowing the height and the radius of the base or radius of the limited circumference, applying the Pythagoras' theorem in the shaded triangle: $$$a=\sqrt{h^2+r^2}$$$