Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function Mole(x_o, y_o, z_o)
- clc; format compact; syms x y real
- if nargin == 0
- x_o = 1;
- y_o = 1;
- z_o = .4;
- end
- f = exp(-(y-x.^2).^2);
- %f = x.^2+y.^2;
- domain = [-3 3];
- % Schnitt yz-ebene
- subplot(2,2,1)
- ezplot( subs(f,x,x_o));title('Schnitt der yz-Achse');
- % Schnitt xz-Ebene
- subplot(2,2,2)
- ezplot( subs(f,y,y_o) );title('Schnitt der xz-Achse');
- % Isohypse zum Niveau z0
- subplot(2,2,3)
- ezplot(f==z_o, domain )
- subplot(2,2,4)
- ezsurf(f, domain); hold on;
- % Schnitt in yz Ebene
- %yz = ezplot3(x_o,y,subs(f,x,x_o), domain);
- % Schnitt in xz Ebene
- %xz = ezplot3(x,y_o,subs(f,y,y_o), domain); set(xz, 'color', 'red')
- % Isohypse zum Niveau z_o in in xy Ebene projeziert
- iso = ezplot( f ==z_o , domain); set(iso, 'color', 'green')
- hold off;
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement