Taylor series in the complex plane

2D plot of complex functions using color wheel, and animates their Taylor series convergence
1.4K Downloads
Updated 14 Apr 2016

View License

Running the code taylor will show you several examples of visualizing functions on the complex plane, and animating their n-term Taylor series as n increased from 1 to say 20. This provides an educational tool to demonstrate analytic (entire) functions, singularities, and the fact that a region of convergence must take the form of a disk.
An aesthetically-pleasing color system has been used to represent a complex number: the unit circle is mapped to the color wheel (actually a circle perpendicular to the diagonal of the RGB color cube), then magnitudes tending to infinity desaturate to white whereas magnitudes tending to 0 decrease in intensity to black. Have a look at the plot of the identity function f(z)=z and it will become clear. In this way, poles and zeros or various order, branch cuts, etc, all become quickly recognizable.
I was influenced by code of Matthias Kawski.

The beef is the function show_zser.m which plots a named function or power series in the above way (see its documentation for calling arguments). It is very easy to modify the example calling commands in taylor.m to show any function or Taylor series you want. As a bonus it plots a `slice' of the real part of the function and its Taylor series along a line parallel to the real axis.

An invaluable tool for any class on complex analysis!

Cite As

Alex Barnett (2024). Taylor series in the complex plane (https://www.mathworks.com/matlabcentral/fileexchange/14289-taylor-series-in-the-complex-plane), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R13
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Line Plots in Help Center and MATLAB Answers

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.0.0.0

BSD licence