在大的背景下添加相关坐标
! C) s8 r8 q& c S* ^close all;figure('position',[50 100 1850 900],'color','w')
# e9 x0 g' r, J* ]axes('position',[0.055 0.2 0.9 0.7])% |/ Z5 y4 J# v' Q6 n( c
itv=linspace(min(rho_xi_eta( ),max(rho_xi_eta( ),30);
3 U) U. [7 B$ o; o" G/ x, ^1 Ucontourf(xi,eta,rho_xi_eta,itv,'edgecolor','none')1 Y: P0 _. i7 i! ~$ B
hold on;
. @- ]4 J( j8 {$ l2 rcontour(xi,eta,rho_xi_eta,itv,'k-','linewidth',1.5)
( z4 f% [: m$ V9 _7 e......
8 b1 R1 l7 ]" o5 d( v
: e# n2 S2 M! {' q* W
6 S' G7 o3 h" A; ~/ l2 ?+ E2 |% 添加坐标
; J5 L( [* u- N1 A/ [& k uaa=get(gca,'position');6 ~+ d# o' e" Q5 ^6 F8 Z7 s
h1=axes('position',[0.5 aa(2) 0.05 aa(end)]);* B2 f8 e3 D% X0 q$ \$ H
set(h1,'color','none') %设置透明背景
' o! w9 M4 ]& |set(gca,'ycolor','none') %隐藏y轴3 K/ l/ I& y y7 i6 f
set(gca,'xcolor','none') %隐藏x轴
: z. z' u B+ fbox off;, ~: B& J+ q7 I* `' B
1 c/ y8 }1 C6 l( X5 S, Y
" M, ^" x0 V0 v2 f) V7 Zcolorseq=mycolor.color94;
. ?9 g- y- d6 x5 w. Q' }, o+ qcolor_str=colorseq(1:70:end, ;. o& T0 d; O. o i1 b
for nn=2
C9 Y5 q$ N, T hold on;
3 _* f$ v- b4 P8 t$ v6 [ ii=find(xi(1, ==nn);
$ u/ M1 K$ }8 o/ j2 \2 K. M# H9 d h1=plot(f_eta(:,ii),eta(:,ii),'color',color_str(nn+1, ,'linewidth',2);; c: W& {3 a# V/ Z( m4 ?/ W
end1 y# @5 _* L# u+ L3 Z6 Q' \- b
legend('\xi=2')- M2 s3 W+ P9 b: C' S
N: @6 _" w3 S) C% {* k3 {
1 c( ~4 F+ q% @4 e1 _h=line([0 0],[0 0.9],'color','k');
/ p: n0 Q3 L g7 Dset(h,'linestyle','--','linewidth',1.5)# s% J+ Y/ Q, o. @. m' }) i
set(get(get(h,'Annotation'),'LegendInformation'),'IconDisplayStyle','off'); %设置不显示这条线的legend
* z9 J9 M- A" ?; l$ S- h! ^* Jxlim([-1.5 1.5]*1e-8)2 z# g. q) M; a7 _* q6 H6 v
set(gca,'xtick',[-10:5:5]*1e-9)3 J ~0 D5 _! B0 L3 \& J" e8 @1 x
h1=line([-10 5]*1e-9,[delta delta],'color','k');
% b, z D% m- g8 k/ x+ bset(h1,'linestyle','--','linewidth',1.5)
* k4 A* j& m/ l. }/ Kset(get(get(h1,'Annotation'),'LegendInformation'),'IconDisplayStyle','off');5 x8 l6 B4 L9 a9 d2 A* t
ylim([0 1])
$ V% D5 Q/ Q8 v% ~' B3 S9 ?- s& N# q$ \/ I1 G4 c4 [* F1 P
4 g+ L, v- s4 @/ b ! x0 Y" s/ u7 x* Y/ c! i1 S
# Z3 V; s8 @1 v" \- K2 a/ v& } 转载本文请联系原作者获取授权,同时请注明本文来自叶瑞杰科学网博客。 |