[ 3 / biz / cgl / ck / diy / fa / ic / jp / lit / sci / vr / vt ] [ index / top / reports ] [ become a patron ] [ status ]
2023-11: Warosu is now out of extended maintenance.

/sci/ - Science & Math

Search:


View post   

>> No.9671410 [View]
File: 13 KB, 260x260, sadpanda.jpg [View same] [iqdb] [saucenao] [google]
9671410

I'm trying to draw contours with Octave, but I'm having no luck at all.
It works out with a simple

x = 1:2;
y = x;
z = x' * y;
contour(x, y, z);

but I'm having no luck with something like

a = -2.5; b = 0.5;
c = -1.5; d = 1.5;
x = linspace(a,b,1000);
y = linspace(c,d,1000);
[X,Y] = meshgrid(x,y);
Z = complex(X,Y);
region = abs(1 + Z) < 1;
contour(x, y, region);

Navigation
View posts[+24][+48][+96]