sr = 44100; % the sample rate in Hz
f0 = 250; % the frequency of the tone in Hz
d = 1; % the tone?s duration in sec
t = linspace(0, d, sr*d); % a time vector
first_component = sin(2*pi*f0*t);
second_component = sin(2*pi*(f0*2)*t);
third_component = sin(2*pi*(f0*3)*t);
harmonic = first_component + second_component + third_component;
harmonic = harmonic/max(abs(harmonic));
sound(harmonic, sr);