Titles/Labels in Graphics
- To: mathgroup at smc.vnet.net
- Subject: [mg96200] Titles/Labels in Graphics
- From: "Jeff Albert" <albertj001 at hawaii.rr.com>
- Date: Mon, 9 Feb 2009 05:34:11 -0500 (EST)
To all: The code that follows produces the two graphics at bottom. I want to have a label above the rightmost vertical line in each graphic ("Detector") that is the same size and placement as the label above the y axis. Using the "Text" command Mathematica keeps squeezing the graphics. I want them to retain their same size and proportionality. Anyone have any ideas? Thanks, Jeff Albert <<Graphics`FilledPlot` f1[x_]= a+.4*(b*x); f2[x_]=a-.4*(b*x); f3[x_]= a1+.4*(b*x); f4[x_]=a1-.4*(b*x); a=4; a1=-4; b=1; RG1u=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,0,10},Fills ->{{{1,2},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; RG1uB=FilledPlot[{f1[x],f2[x]},{x,0,20},Fills ->{{{1,2},GrayLevel[.8]}}]; RG2u=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,10,20},Fills ->{{{1,3},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; RG2uB=FilledPlot[{f1[x],f2[x]},{x,10,20},Fills ->{{{1,2},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; LG1u=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,-20,-10},Fills ->{{{2,4},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; LG2u=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,-10,0},Fills ->{{{2,1},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; RG1d=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,0,10},Fills ->{{{4,3},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; RG2d=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,10,20},Fills ->{{{2,4},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; LG1d=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,-20,-10},Fills ->{{{1,3},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; LG2d=FilledPlot[{f1[x],f2[x],f3[x],f4[x]},{x,-10,0},Fills ->{{{4,3},GrayLevel[.8]}},PlotStyle->{Dashing[{}],Dashing[{}],Dashing[{.03}] ,Dashing[{.03}]}]; $TextStyle={FontFamily->"Times", FontSize->10}; Screen1={{40,60},{40,-60}}; Scr=ListPlot[%,PlotJoined->True]; Show[Scr,RG1u, RG2u,RG1d,RG2d,Ticks->{None,{ {4,"SLIT 1 (open) *"},{-4,"SLIT 2 (open) *" }}},Axes->{False,True},AxesLabel->" DOUBLE SLIT SCREEN"]; Show[Scr,RG1uB, RG2uB,Ticks->{None,{ {4,"SLIT 1 (open) *"},{-4,"SLIT 2 (shut) *" }}},Axes->{False,True},AxesLabel->" DOUBLE SLIT SCREEN "];