No BSD License  

Highlights from
Alternative Mathematics using MATLAB 7

image thumbnail

Alternative Mathematics using MATLAB 7

by

 

13 Mar 2003 (Updated )

Self-instructive text on undergraduate algebra, statistics, differential and integral calculus.

ex232.m
% ex232.m:  Plots of a Complex Polynomial					         
clear all
X=linspace(-1,3,53);					% Make a grid of nxn
Y=linspace(-2,2,61);
[X Y]=meshgrid(X,Y);					% Make grid matrices
Z=X+i*Y;							% Make complex Z
Pm=abs(2.1- 3*Z+ 3*Z.^2- 3*Z.^3+ Z.^4);  	% Magnitude of P(z)
figure(1), contour(X,Y, Pm, logspace(-3,2,50)),  colorbar,  title('|P(z)|') 
   xlabel('real'),  ylabel('imaginary')
figure(2),  surfc(X,Y, log(Pm)),  grid on,  colorbar 
   shading interp,  colormap(jet),   title('ln|P(z)|')
   xlabel('real'),  ylabel('imaginary')  

Contact us