|
matlab 版本的。 你需要定义你的x,y,以及你的三层的数据。文字和原子,其实是可能通过其它的软件vmd, pymol画好后,用gimp 加到里面,这里只画一个。
clear all clc clf %% outline % plot diff layer potential surfs %% main % the x,y x=[1:10]; y=[0:8]; [X,Y]=meshgrid(x,y); % your potential values, Z1 = sin(0.2*X+0.7*Y ); Z2 = exp(0.1*X.*cos(0.5*Y.^1.1))+3; Z3 = 0.1*((X-5).^2 + (Y-6).^2)+7; % atom x,y,z [s_x,s_y,s_z]=sphere(50); x_shift = 3; y_shift = 2; z_shift = 12; r=0.6; %% plot hold on % surf 3 layers h1=surf(X,Y,Z1); h2=surf(X,Y,Z2,Z2+10); % you can modify 10 to change the color of the layer h3=surf(X,Y,Z3,Z3+20); % you can modify 20 to change the color of the layer alpha(h1,0.95); alpha(h2,0.9); alpha(h3,0.8); % plot atom surf(r*s_x+x_shift,r*s_y+y_shift,r*s_z+z_shift,'edgecolor','none','markerfacecolor','w') % Text text(3,4,10,'S_2','fontsize',16) % plot point on surf plot3(X(6,5),Y(6,5),Z3(6,5),'yo','markerfacecolor','y','markersize',10); % other settings view(150,30); axis off axis equal camlight %% logs % mod : 2018年 11月 21日 星期三 08:52:09 CST % mod by mm % contact : meatball1982@163.com |
|
注意求助帖应当在帖子标题明确体现出提问、求助及具体内容(见http://bbs.keinsci.com/thread-9348-1-1.html),我已把你的标题“势能面图”改了,望以后注意 做势能面扫描,然后用surfer、sigmaplot、Origin、matlab之类绘制 |
手机版 Mobile version|北京科音自然科学研究中心 Beijing Kein Research Center for Natural Sciences|京公网安备 11010502035419号|计算化学公社 — 北京科音旗下高水平计算化学交流论坛 ( 京ICP备14038949号-1 )|网站地图
GMT+8, 2026-2-19 10:19 , Processed in 1.003842 second(s), 25 queries , Gzip On.