help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Contour plots


From: Henry F. Mollet
Subject: Contour plots
Date: Sun, 06 Mar 2005 10:22:13 -0800
User-agent: Microsoft-Entourage/10.1.1.2418

GNU Octave, version 2.1.46 (powerpc-apple-darwin6.6).
G N U P L O T
        Version 3.8i patchlevel 0

octave:1> help contour
contour is the user-defined function from the file
/sw/share/octave/2.1.46/m/plot/contour.m
 - Function File:  contour (Z, N)
 - Function File:  contour (X, Y, Z, N)
     Make a contour plot of the three-dimensional surface described by
     Z.  Someone needs to improve `gnuplot''s contour routines before
     this will be very useful.

Second function file does not work for me to get better control over the
number of contours. There are additional difficulties when used in
combination with multiplot.

See attached for the best I was able to come up with. Of *most concern* is
the jaggedness of the contours as the parameter w/al increases. It does not
appear to be related to the meshgrid. 35x35 produces a similar plot as
350x350 (see below), and my computer cannot handle 1000x1000 and I have to
force quit the terminal window.
How is this problem best defined so that I could search for a solution?
Additional problems are the placement of the y-scale on the right instead of
on the left and the horizontal instead of vertical placement of the y-label.

I could calculate the contours as y = y(x) but that might be a lot of work.
Well, perhaps easy with fsovle for a good number of x-values for each
contour (about 10-15 for each subplot) if I were more familiar with it?
However, I assume that this would really be a work around?
Henry

% Code for last of 4 contour subplots:
% x = Sa/la from 0 to 1.2
% y = alpha from 1 to 35
% w = 12* alpha
subplot (2,2,4)                                        %  subplot (2,2,4)
gset origin 0.30,-0.07
axis ([0.2,1.2,0,35], "square"); % problems with "normal"
gset label 4 " D)  w/al = 12.0 " at 0.25, 27.5
grid "on"
x=linspace(0,1.2,350);
y=linspace(1,35,350);
[xx,yy]=meshgrid(x,y);
z=xx./(yy.*(1-xx)) -
(12*yy-yy+1).*xx.^(12*yy-yy+1)./yy./(1-xx.^(12*yy-yy+1)) + eps;
xlabel ("Sa/lambda1")
ylabel (" alpha")
contour (x,y,z)




Attachment: Figure 1025.pdf
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]