hax1 = axes ("position", [.5 .5 .4 .4]); hold on x1=0:.01:.8; Is=10^-12; vt=.015; n=1.9; vd=x1; y1=Is*(exp(vd/(n*vt))-1); plot (x1, y1) hax2 = axes ("position", [.1 .1 .4 .4], "xaxislocation", "top", "yaxislocation", "right"); hold on count=0; y33=0; for x2=-101:.1:0 count=count+1; if (x2>-50 ) y3=-.0004; #reverse bias leakage current elseif (x2<-50) # the next line should be the formula for the breakdown chracteristics # but I just made this one up so the graph would look close. y3=-1e-6*(exp(x2/(-5))-1); endif x22(count)=x2; y33(count)=y3; endfor plot (x22, y33) % Remove ambiguous/overlapping tick labels at the origin xl = get (hax1, "xticklabel"); xl{1} = ""; set (hax1, "xticklabel", xl) xl = get (hax2, "xticklabel"); xl{end} = ""; set (hax2, "xticklabel", xl) yl = get (hax1, "yticklabel"); yl{1} = ""; set (hax1, "yticklabel", yl) yl = get (hax2, "yticklabel"); yl{end} = ""; set (hax2, "yticklabel", yl)