Trying to close some loose plotting

• To: mathgroup at smc.vnet.net
• Subject: [mg124661] Trying to close some loose plotting
• Date: Mon, 30 Jan 2012 05:08:04 -0500 (EST)
• Delivered-to: l-mathgroup@mail-archive0.wolfram.com

```Hi -  I am trying to plot the real roots of a cubic equation as
functions of one parameter called rc, using the code below, on Mathematica 5.2.
The plotted curves, however,  show some dead spots that should not be
there.
How can I get them to fill up?  I tried getting rid of the imaginary part when its absolute value is less that a given tolerance, but that trick does not
work.

Thanks for any suggestions.

ClearAll[\[Mu],\[Lambda],\[Beta],a,b,rc];
\[Lambda]1=(2*\[Mu]-(2*2^(1/3)*(-3+2*\[Mu]^2))/(27*rc-18*\[Mu]+20*\
[Mu]^3+
Sqrt[4*(-3+2*\[Mu]^2)^3+(27*rc-18*\[Mu]+20*\
[Mu]^3)^2])^(1/3)+2^(2/3)*
(27*rc-18*\[Mu]+20*\[Mu]^3+Sqrt[4*(-3+2*\[Mu]^2)^3+(27*rc-18*\[Mu]
+20*\[Mu]^3)^2])^(1/3))/6;
\[Lambda]2=(4*\[Mu]+(2*2^(1/3)*(1+I*Sqrt[3])*(-3+2*\[Mu]^2))/(27*rc-18*
\[Mu]+20*\[Mu]^3+
Sqrt[4*(-3+2*\[Mu]^2)^3+(27*rc-18*\[Mu]+20*\[Mu]^3)^2])^(1/3)+
I*2^(2/3)*(I+Sqrt[3])*(27*rc-18*\[Mu]+20*\[Mu]^3+Sqrt[4*(-3+2*\
[Mu]^2)^3+
(27*rc-18*\[Mu]+20*\[Mu]^3)^2])^(1/3))/12;
\[Lambda]3=(4*\[Mu]+(2*2^(1/3)*(1-I*Sqrt[3])*(-3+2*\[Mu]^2))/(27*rc-18*
\[Mu]+20*\[Mu]^3+
Sqrt[4*(-3+2*\[Mu]^2)^3+(27*rc-18*\[Mu]+20*\[Mu]^3)^2])^(1/3)-
2^(2/3)*(1+I*Sqrt[3])*(27*rc-18*\[Mu]+20*\[Mu]^3+Sqrt[4*(-3+2*\
[Mu]^2)^3+
(27*rc-18*\[Mu]+20*\[Mu]^3)^2])^(1/3))/12;
thick=AbsoluteThickness[1.25];
p1style={{thick,RGBColor[0,0,0]},
{thick,RGBColor[1,0,0]},  {thick,RGBColor[0,1,0]},
{thick,RGBColor[0,0,1]},  {thick,RGBColor[1,1/2,0]},
{thick,RGBColor[1/2,0,1]},{thick,RGBColor[1,0,1]},
{thick,RGBColor[1,0,1/2]},{thick,RGBColor[1,0,0]},
{thick,RGBColor[0,1,0]},  {thick,RGBColor[0,0,1]},
{thick,RGBColor[1,1/2,0]},{thick,RGBColor[1/2,0,1]},
{thick,RGBColor[1,0,1]},  {thick,RGBColor[1,0,1/2]}};
rctab={0, 0.04, 0.08, 0.15, 0.3, 0.5, 1, 2,
-0.04,-0.08,-0.15,-0.3,-0.5,-1,-2};
Np=Length[rctab];
\[Lambda]1tab=Table[\[Lambda]1/.rc->rctab[[i]],{i,1,Np}];
\[Lambda]2tab=Table[\[Lambda]2/.rc->rctab[[i]],{i,1,Np}];
\[Lambda]3tab=Table[\[Lambda]3/.rc->rctab[[i]],{i,1,Np}];
\[Lambda]123=Flatten[{\[Lambda]1tab,\[Lambda]2tab,\[Lambda]3tab}];
Off[Plot::"plnr"];
Plot[Evaluate[\[Lambda]123],{\[Mu],-1,1},PlotStyle->p1style,
PlotRange->{-1.5,1.5},AspectRatio->1.5,Frame->True,
ImageSize->300,DisplayFunction->\$DisplayFunction]

```

• Prev by Date: Re: Get rid of left margin reserved for In/Out labels
• Next by Date: Re: navigate notebook, further question
• Previous by thread: Fit data
• Next by thread: Re: Trying to close some loose plotting