       Re: Give arrow a certai color

• To: mathgroup at smc.vnet.net
• Subject: [mg104803] Re: [mg104775] Give arrow a certai color
• From: DrMajorBob <btreat1 at austin.rr.com>
• Date: Tue, 10 Nov 2009 06:01:17 -0500 (EST)
• References: <200911091046.FAA05764@smc.vnet.net>

```I do NOT recommend using ReplacePart that way, since the structure of the
plot, in that detail, could easily change from one version of Mathematica
to the next. That is, the coordinates {1, 1, 3, 2, 0} may change. They
probably vary from one plot to another within a version, as well.

Now here's a way to make the plot black:

pl1 = ParametricPlot[{r[t]*Cos[\[Theta][t]],
r[t]*Sin[\[Theta][t]]}, {t, 0, 1.1}, Ticks -> None,
AxesLabel -> {"z", "z'"}, PlotRange -> {-1, 1},
PlotStyle -> Black] /. Line -> Arrow;
pl2 = ParametricPlot[{r[t]*Cos[\[Theta][t]],
r[t]*Sin[\[Theta][t]]}, {t, 1, 7}, Ticks -> None,
AxesLabel -> {"z", "z'"}, PlotRange -> {-1, 1}, PlotStyle -> Black];
Show[{pl1, pl2}]

and here's another:

save = Options[ParametricPlot, PlotStyle];
SetOptions[ParametricPlot, PlotStyle -> Black];
pl1 = ParametricPlot[{r[t]*Cos[\[Theta][t]],
r[t]*Sin[\[Theta][t]]}, {t, 0, 1.1}, Ticks -> None,
AxesLabel -> {"z", "z'"}, PlotRange -> {-1, 1}] /. Line -> Arrow;
pl2 = ParametricPlot[{r[t]*Cos[\[Theta][t]],
r[t]*Sin[\[Theta][t]]}, {t, 1, 7}, Ticks -> None,
AxesLabel -> {"z", "z'"}, PlotRange -> {-1, 1}];
Show[{pl1, pl2}]
SetOptions[ParametricPlot, save];

Bobby

On Mon, 09 Nov 2009 04:46:30 -0600, Alexei Boulbitch <boulbitch at gmx.de>
wrote:

> Dear community,
>
> we discussed recently how to make curved arrows. Here is an example:
>
> r[t_] := Exp[-t];
> \[Theta][t_] := 3 t + 0.7;
>
> pl1 = ReplacePart[
>    ParametricPlot[{r[t]*Cos[\[Theta][t]], r[t]*Sin[\[Theta][t]]}, {t,
>      0, 1.1}, Ticks -> None, AxesLabel -> {"z", "z'"},
>     PlotRange -> {-1, 1}], {1, 1, 3, 2, 0} -> Arrow];
> pl2 = ParametricPlot[{r[t]*Cos[\[Theta][t]],
>     r[t]*Sin[\[Theta][t]]}, {t, 1, 7}, Ticks -> None,
>    AxesLabel -> {"z", "z'"}, PlotRange -> {-1, 1}];
>
> Show[{pl1, pl2}]
>
> However, I cannot force Mathematica to make the graph black (or any
> other color) instead of blue. The option PlotStyle->Black as below
>
> ReplacePart[
>  ParametricPlot[{r[t]*Cos[\[Theta][t]], r[t]*Sin[\[Theta][t]]}, {t, 0,
>     1.1}, PlotStyle -> Black, Ticks -> None, AxesLabel -> {"z", "z'"},
>    PlotRange -> {-1, 1}], {1, 1, 3, 2, 0} -> Arrow]
>
> does not work.
>
> Could you please give me a hint, of how to do this?
>
> Thank you, Alexei

--
DrMajorBob at yahoo.com

```

• Prev by Date: Re: Ten chess-players...
• Next by Date: Re: Give arrow a certain color
• Previous by thread: Give arrow a certai color
• Next by thread: Re: Give arrow a certai color