A diagnostic test which uses ultrasound waves to make images of the heart chambers, valves and surrounding structures. It can measure cardiac output and is a sensitive test for inflammation around the heart (pericarditis). It can also be used to detect abnormal anatomy or infections of the heart valves. Also known as an echocardiography.