function [area] = circle_area (radius) % circle_area calculates the area of a circle from the radius. % Input arguments: % radius = radius of a circle % Output arguments: % area = area of the circle % This is an example of a MATLAB "function" file % % Programmer: Dick Furnstahl furnstahl.1@osu.edu % % Revision history: % 20-Mar-2005 -- original version for Physics 263 % % calculate the area (the ";" at the end suppresses the output) area = pi * radius^2;