This paper uses Matlab to simulate Fourier series decomposition and synthesis of square wave,sawtooth wave and triangle wave,and presents a lively and direct view of harmonic synthesis process and the Gibbs phenomenon.It uses Matlab to draw the square wave decomposition 3Dgraphics and analyses the relationship between signal waveform and spectrum by adjust angle of view.The teaching activity shows that adding the vivid Matlab simulation into the abstract theory teaching is helpful to deepen students' unders...