[X,Y,Z] = sphere(16);x = [0.5*X(:); 0.75*X(:); X(:)];y = [0.5*Y(:); 0.75*Y(:); Y(:)];z = [0.5*Z(:); 0.75*Z(:); Z(:)];scatter3(x,y,z) |
|
z = linspace(0,4*pi,250);x = 2*cos(z) + rand(1,250);y = 2*sin(z) + rand(1,250);scatter3(x,y,z,'filled')view(-30,10) |
|
z = linspace(0,4*pi,250);x = 2*cos(z) + rand(1,250);y = 2*sin(z) + rand(1,250);scatter3(x,y,z,'*')view(-30,10) |
x = 1:3;y = 1:5;[X,Y] = meshgrid(x,y) |
|
x = -2:0.25:2;[X,Y] = meshgrid(x);F = X.*exp(-X.^2-Y.^2);surf(X,Y,F) |
|
x = -2:0.25:2;y = x;surf(x,y,x.*exp(-x.^2-(y').^2)) |
x = linspace(-2*pi,2*pi);y = linspace(0,4*pi);[X,Y] = meshgrid(x,y);Z = sin(X)+cos(Y);contour(X,Y,Z) |
[X,Y,Z] = peaks;contour(X,Y,Z,20) |
x = -2:0.2:2;y = -2:0.2:3;[X,Y] = meshgrid(x,y);Z = X.*exp(-X.^2-Y.^2);contour(X,Y,Z,'ShowText','on') |
Z = peaks(20);contourf(Z,10) |
x = -2:0.25:2;[X,Y] = meshgrid(x);Z = X.*exp(-X.^2-Y.^2);contour3(X,Y,Z,30) |
f = @(x,y) sin(x) + cos(y);fcontour(f) |
fcontour(@(x,y) sin(x)+cos(y))hold onfcontour(@(x,y) x-y)hold off |
theta = -pi/2:pi/16:pi/2;r = 2*ones(size(theta));[u,v] = pol2cart(theta,r);feather(u,v) |
[x,y] = meshgrid(0:0.2:2,0:0.2:2);u = cos(x).*y;v = sin(x).*y;quiver(x,y,u,v) |
|
[X,Y] = meshgrid(-2:.2:2);Z = X.*exp(-X.^2 - Y.^2);[DX,DY] = gradient(Z,.2,.2);contour(X,Y,Z)hold onquiver(X,Y,DX,DY)hold off |
x = -3:0.5:3;y = -3:0.5:3;[X,Y] = meshgrid(x, y);Z = Y.^2 - X.^2;[U,V,W] = surfnorm(Z);quiver3(Z,U,V,W)view(-35,45) |
|
vz = 10; % velocity constanta = -32; % acceleration constantt = 0:.1:1;z = vz*t + 1/2*a*t.^2;vx = 2;x = vx*t;vy = 3;y = vy*t;u = gradient(x);v = gradient(y);w = gradient(z);scale = 0;quiver3(x,y,z,u,v,w,scale)view([70,18]) |
load windstreamslice(x,y,z,u,v,w,[],[],[5])axis tight |
[x,y] = meshgrid(0:0.1:1,0:0.1:1);u = x;v = -y;quiver(x,y,u,v)startx = 0.1:0.1:1;starty = ones(size(startx));streamline(x,y,u,v,startx,starty) |
[X,Y,Z] = peaks(30);waterfall(X,Y,Z) |
[X,Y,Z] = peaks(25);surf(X,Y,Z); |
[X,Y,Z] = peaks(30);surfc(X,Y,Z); |
[X,Y] = meshgrid(-2:0.2:2,-2:0.2:2);Z = X.*exp(-X.^2 - Y.^2);surface(X,Y,Z)view(3) |
fsurf(@(x,y) sin(x)+cos(y)) |
|
r = @(u,v) 2 + sin(7.*u + 5.*v);funx = @(u,v) r(u,v).*cos(u).*sin(v);funy = @(u,v) r(u,v).*sin(u).*sin(v);funz = @(u,v) r(u,v).*cos(v);fsurf(funx,funy,funz,[0 2*pi 0 pi])camlight |
[X,Y] = meshgrid(-8:.5:8);R = sqrt(X.^2 + Y.^2) + eps;Z = sin(R)./R;mesh(Z) |
[X,Y] = meshgrid(-3:.125:3);Z = peaks(X,Y);meshc(Z) |
r = @(s,t) 2 + sin(7.*s + 5.*t);x = @(s,t) r(s,t).*cos(s).*sin(t);y = @(s,t) r(s,t).*sin(s).*sin(t);z = @(s,t) r(s,t).*cos(t);fmesh(x,y,z,[0 2*pi 0 pi])alpha(0.8) |
cylinder |
|
t = 0:pi/10:2*pi;[X,Y,Z] = cylinder(2+cos(t));surf(X,Y,Z)axis square |
sphere |
|
[x,y,z] = sphere;surf(x,y,z)hold onsurf(x+3,y-2,z) % centered at (3,-2,0)surf(x,y+1,z-3) % centered at (0,1,-3) |
[x, y, z] = ellipsoid(0,0,0,5.9,3.25,3.25,30);surf(x, y, z)axis equal |
load windxmin = min(x(:));xmax = max(x(:));ymax = max(y(:));zmin = min(z(:));wind_speed = sqrt(u.^2 + v.^2 + w.^2);hsurfaces = slice(x,y,z,wind_speed,[xmin,100,xmax],ymax,zmin);set(hsurfaces,'FaceColor','interp','EdgeColor','none')colormap jethcont = ...contourslice(x,y,z,wind_speed,[xmin,100,xmax],ymax,zmin);set(hcont,'EdgeColor',[0.7 0.7 0.7],'LineWidth',0.5)[sx,sy,sz] = meshgrid(80,20:10:50,0:5:15);hlines = streamline(x,y,z,u,v,w,sx,sy,sz);set(hlines,'LineWidth',2,'Color','r')view(3)daspect([2,2,1])axis tight |
"I think war is a dangerous place." |
"He is proposing to privatize a big part of Social Security and he's proposing to take $1 trillion, a million billion dollars
out of the Social Security trust fund and give it as a tax incentive to young workers." |
Any logical model of reality is incomplete (and possibly inconsistent) and must be continuously refined/adapted in the face of new observations.
This principle shows that we cannot simultaneously fix or determine the velocity and position of a particle or body.
Just as a closed system in nature will have increasing entropy, or disorder, so too will a person experience mental entropy or disorder if they’re cut off from the outside world and new information.