在大的背景下添加相关坐标
$ Q: _7 U3 U7 H' l1 Yclose all;figure('position',[50 100 1850 900],'color','w')& r1 O" p0 E! O* \ x* I4 U1 h; I
axes('position',[0.055 0.2 0.9 0.7])
, J' M$ j/ k0 [itv=linspace(min(rho_xi_eta( ),max(rho_xi_eta( ),30);
; @( O# E0 ?% `- x0 V" x8 K( econtourf(xi,eta,rho_xi_eta,itv,'edgecolor','none')3 @3 S: {! o' \7 s$ q6 I. P
hold on;1 D$ v d, _" r
contour(xi,eta,rho_xi_eta,itv,'k-','linewidth',1.5)0 Y s0 c7 P: \
......
) k# [1 a2 I. U4 U
" \! `3 h( _7 Y. C+ O0 g. N3 `/ E7 p. E# ?7 m! j5 H+ e% J
% 添加坐标
& W) E+ k6 K# k, Y6 {aa=get(gca,'position');
}, x% c, a3 x' E# }" vh1=axes('position',[0.5 aa(2) 0.05 aa(end)]);: H+ Y- ]' Y6 b% h! ~. l
set(h1,'color','none') %设置透明背景
, V% n i' k; Cset(gca,'ycolor','none') %隐藏y轴' H- t; N' e% j& ~% Z1 L
set(gca,'xcolor','none') %隐藏x轴: u, t9 h7 a2 d' m# m9 l
box off;
6 G$ r/ ?- z# K# L
$ D: N+ w. x+ N7 k) [/ {! |+ ^( T% N) c8 R& N$ M
colorseq=mycolor.color94;% Y1 d- J" p+ G1 }* {( X; A
color_str=colorseq(1:70:end, ;
0 f8 P2 X+ C) G8 zfor nn=2' g( z0 \8 s. l
hold on;
: @0 C, j& ]. S# e# Z: U9 q* Y ii=find(xi(1, ==nn);
' F7 @1 }3 U% A& l# K h1=plot(f_eta(:,ii),eta(:,ii),'color',color_str(nn+1, ,'linewidth',2);8 s7 x7 R1 M n
end# _! w& W9 L7 s7 b- [
legend('\xi=2')
: q) u6 b. Y1 K' e) P
: q& Q. n, i" ?
3 j5 o5 `! c% ^1 |. s: G' O2 th=line([0 0],[0 0.9],'color','k');
, w a0 H+ p5 @! w0 j# K! h) q; eset(h,'linestyle','--','linewidth',1.5)$ y4 F. N: V3 f2 T0 @1 g* c* T8 X
set(get(get(h,'Annotation'),'LegendInformation'),'IconDisplayStyle','off'); %设置不显示这条线的legend
9 Z4 Z7 `# u8 x& w- Q* Y+ ^- Txlim([-1.5 1.5]*1e-8)9 n8 v& Y/ o+ B# V. S4 i
set(gca,'xtick',[-10:5:5]*1e-9)
# c8 D! _; }* s7 h h! jh1=line([-10 5]*1e-9,[delta delta],'color','k');
: E9 N$ e; N9 j- r2 lset(h1,'linestyle','--','linewidth',1.5)
. V: r3 i k& Q/ D: ~; g: x. p% oset(get(get(h1,'Annotation'),'LegendInformation'),'IconDisplayStyle','off');
x: ?; y& K7 ^7 ]2 ?: H8 \ylim([0 1])5 M$ z" T' R8 E: J! z/ _
. K4 u }9 s( L Q1 F
8 B. i& z" M8 U
% Z. b1 u7 e e& _8 N
, V# o% N- _3 I' Q
转载本文请联系原作者获取授权,同时请注明本文来自叶瑞杰科学网博客。 |