As pointed in the comments : "an easy way to go from your first image to your second image would be to use the direct selection tool (white arrow, a), select the points at the corner of each triangle (holding shift), then copy and paste just those points. – user568458 3 hours ago" would work. Remember to close your shapes afterwards if you want to be able to use Pathfinder on them. (select two points you want to close and cmd+j to join)
You can also select your square, go to the object menu > Path > Add anchor points. This will add halfway anchor points which should make your job easier. Just use scissors afterwards and close the shapes.
Or just use the minus pen tool to remove one corner of your square, and you'll get a square triangle. Copy paste that 4 times. You can use the rotate tool and change the pivot to the center of the square on top if you want to get perfect alignement as shown in the screenshot you provided.
Remember to hold shift when rotating your shape to maintain steps of 45 degree angles.
a
), select the points at the corner of each triangle (holding shift), then copy and paste just those points.