The heart develops from cardiogenic mesoderm and forms endothelial heart tubes that fuse to create a single heart tube located within the pericardial cavity. The heart tube undergoes looping to form the basic chambers and portions. Septae then develop to divide the heart into four chambers - the interatrial septum divides the atria while the interventricular and aorticopulmonary septa divide the ventricles. Various congenital malformations can occur if septation is incomplete or unequal. The great arteries also septate during development.