在大的背景下添加相关坐标% C, k# H/ |; S3 y2 F, ?1 [
close all;figure('position',[50 100 1850 900],'color','w')
; _- x7 j1 a4 v0 h, b# H N' ~axes('position',[0.055 0.2 0.9 0.7])# T$ D( ?% i: \" |: U: O. J
itv=linspace(min(rho_xi_eta(),max(rho_xi_eta(),30);: M- R5 i: p9 M$ k' G* r# Q
contourf(xi,eta,rho_xi_eta,itv,'edgecolor','none')
/ w9 l# T0 F* J2 N/ N! rhold on;
: o% K8 ~! g5 P# [7 g( Rcontour(xi,eta,rho_xi_eta,itv,'k-','linewidth',1.5)
& a/ d, f2 g" N W/ n......
" Y5 c9 F% N* ^3 C/ r# W! P& S4 E3 `& h7 u
2 B! U3 [+ q, l# e1 d8 s% 添加坐标
7 i, F5 Z5 b% X5 M# }' R: saa=get(gca,'position');
/ q1 L [# G8 @h1=axes('position',[0.5 aa(2) 0.05 aa(end)]);9 L1 I7 f. j/ E# [1 A2 ^
set(h1,'color','none') %设置透明背景
: \( T6 P8 N w h/ Jset(gca,'ycolor','none') %隐藏y轴
+ D# G1 a; D" e! p2 wset(gca,'xcolor','none') %隐藏x轴, d2 ~8 @5 U: e0 y6 A8 x& Q) o6 r
box off;
1 o( Q; m4 e2 H6 b3 l* M1 h0 D( s4 k: J: [1 R7 V
" o8 r3 M0 {* V! mcolorseq=mycolor.color94;
* _+ l6 @1 A9 f; ?4 Scolor_str=colorseq(1:70:end,;
! f% m4 u% P* R! c3 `for nn=2' c( j' \1 k1 Z: z0 q5 u0 j: A- X
hold on;
" s" p% V1 @3 V% [5 ` ii=find(xi(1,==nn);
# W2 O- r! b; b4 d O h1=plot(f_eta(:,ii),eta(:,ii),'color',color_str(nn+1,,'linewidth',2);
% i+ X$ O5 J1 Bend) D& G9 L. t) m7 ~
legend('\xi=2')0 _) M8 a' k/ b! B5 |
) P/ a3 @' W3 Z5 o# h+ e1 t2 k: _# J9 E, n6 I+ i0 Y5 F3 b
h=line([0 0],[0 0.9],'color','k');
0 |; D6 _5 s) \5 c( _# `+ Pset(h,'linestyle','--','linewidth',1.5)
1 D) G$ m9 |* g" [set(get(get(h,'Annotation'),'LegendInformation'),'IconDisplayStyle','off'); %设置不显示这条线的legend
! f) B# J/ g; o- oxlim([-1.5 1.5]*1e-8), Y$ r5 p# b* v4 j4 L, H9 Q. P8 W5 F
set(gca,'xtick',[-10:5:5]*1e-9)
6 X' q \/ [- |6 Nh1=line([-10 5]*1e-9,[delta delta],'color','k');. g/ `% Q& `' \' c5 i) x6 d
set(h1,'linestyle','--','linewidth',1.5)
3 T' t4 n7 V" O# dset(get(get(h1,'Annotation'),'LegendInformation'),'IconDisplayStyle','off');
- u4 m2 P6 X. R, R7 }) ?7 _ylim([0 1])
" |( w8 M) U1 g q& e8 i0 N: K5 o# X4 n. h t1 N; A+ q
* R% o7 ?* |5 T7 L0 B1 B
9 m0 w% x8 O9 [9 {# a" P
9 m" U% h& V/ H 转载本文请联系原作者获取授权,同时请注明本文来自叶瑞杰科学网博客。 |