Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #2373
| From | Dushan Mitrovich <dushanm@spinn.net> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: color-coding two sets of plotted curves? |
| Date | 2011-05-14 07:14 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <iqla4t$a07$1@smc.vnet.net> (permalink) |
Bob Hanlon wrote:
> The two ParametricPlots can be collapsed down to a single one
>
> ParametricPlot[Evaluate[
> Thread[
> Table[{
> xy[(j + 1)/4, Pi u],
> xy[6 (u + 1), j Pi/6]},
> {j, 0, 11}]]],
> {u, -1, 1},
> PlotPoints -> 50,
> PlotStyle -> {Red, Blue},
> PlotRange -> {{0, 4.2}, {-2, 2}}] // Quiet
>
> Bob Hanlon
>
>
Thank you. I didn't know about 'Thread' but had a vague feeling
something like it ought to exist. Now to get familiar with it.
- Dushan
> ---- Dushan Mitrovich<dushanm@spinn.net> wrote:
>
> =============
> After a lot of experimentation I finally found a way to plot two sets of
> curves orthogonal using one color per set. The following relates
> Bipolar and Cartesian coordinates, then plots the sets of coordinate
> lines Red and Blue:
>
> xy[Xi_, Theta_] := { Sinh[Xi]/(Cosh[Xi]+Cos[Theta]),
> Sin[Theta]/(Cosh[Xi]+Cos[Theta])}
>
> pXi = ParametricPlot[Evaluate@Table[xy[(j+1)/4, Pi u], {j,0,11}],
> {u,-1,1}, PlotRange->{{0,4.2},{-2,2}},
> PlotPoints->50, PlotStyle->{Red}];
>
> pTheta = ParametricPlot[Evaluate@Table[xy[6 (u+1), j Pi/6], {j,0,11}],
> {u,-1,1}, PlotRange->{{0,4.2},{-2,2}},
> PlotPoints->50, PlotStyle->{Blue}];
>
> Show[pXi,pTheta]
>
> Everything else I tried plotted all the curves the same color. Am I
> using the recommended approach or is there another, more direct one?
>
> - Dushan
>
>
>
>
Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread
Re: color-coding two sets of plotted curves? Dushan Mitrovich <dushanm@spinn.net> - 2011-05-14 07:14 +0000
csiph-web