Stats

Popular Posts

Followers

Mathematica 教學 互換X-Y座標軸

戴忠淵 於 2010年8月10日星期二 下午7:39 發表
ClearAll["Global`*"]

nv=0.001;
chi=0.1;
detF0[lambda0_]:=lambda0^3;

mu0KT[lambda0_]:=
nv*(1/lambda0-1/detF0[lambda0])+Log[1-1/detF0[lambda0]]+
1/detF0[lambda0]+chi/detF0[lambda0]^2;

lambda0=Range[1.5,3.5,0.05];

(*畫出mu0KT[lambda0]的圖形*)
myplot=Plot[mu0KT[lambda0],{lambda0,1.5,3.5},PlotRange->All,
Frame->True,PlotStyle->Thickness[0.0125]]

(*將圖形資料取出,接著對調座標,最後以ListLinePlot畫出*)
ListLinePlot[Cases[myplot,Line[x__]:>Reverse/@x,Infinity],
PlotRange->{All,{1.5,3.5}},
PlotStyle->Thickness[0.0125],
Frame->True]
Tags: , ,

讀者回應 ( 0 意見 )

發佈留言

Please leave your name and tell me what you thought about this site. Comments, suggestions and views are welcomed.

如果這篇文章對你有幫助,那請留個訊息給我~