Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #13382 > unrolled thread
| Started by | Christopher Young <cy56@comcast.net> |
|---|---|
| First post | 2013-02-04 06:25 +0000 |
| Last post | 2013-02-04 06:25 +0000 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.soft-sys.math.mathematica
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: Any way to get gradient lines as well as contour lines? Christopher Young <cy56@comcast.net> - 2013-02-04 06:25 +0000
| From | Christopher Young <cy56@comcast.net> |
|---|---|
| Date | 2013-02-04 06:25 +0000 |
| Subject | Re: Any way to get gradient lines as well as contour lines? |
| Message-ID | <kenk9m$959$1@smc.vnet.net> |
On Feb 3, 2013, at 2:18 PM, Bob Hanlon <hanlonr357@gmail.com> wrote:
> Grad[Sin[x + y^2], {x, y}]
>
> {Cos[x + y^2], 2*y*Cos[x + y^2]}
>
> Plot3D[Sin[x + y^2], {x, -Pi, Pi}, {y, -2, 2},
> MeshFunctions -> {
> Cos[#1 + #2^2] &,
> 2 #2 Cos[#1 + #2^2] &},
> Mesh -> {10, 20},
> PlotPoints -> 35]
>
>
> Bob Hanlon
Thanks, I'm getting the contour lines with this but the other mesh lines
aren't in general at right angles to the contour lines.
I'm wondering if the mesh complex functions could be used to get both
contour lines and gradient lines in some cases.
In the cases shown, though, they're not quite contours and gradients,
although they are conjugate sets of curves, i.e., at right angles to
each other.
$TrigFunctions =
{
Sin, Cos, Sec, Csc, Tan, Cot,
ArcSin, ArcCos, ArcSec, ArcCsc, ArcTan, ArcCot,
Sinh, Cosh, Sech, Csch, Tanh, Coth,
ArcSinh, ArcCosh, ArcSech, ArcCsch, ArcTanh, ArcCoth
};
plots = Table[
Plot3D[
Abs[f[x + I y]],
{x, -2, 2}, {y, -2, 2},
MeshFunctions ->
Function @@@ {
{{x, y, z}, Re[f[x + I y]]},
{{x, y, z}, Im[f[x + I y]]}},
MeshStyle -> {Orange, Green},
PlotLabel -> f,
Ticks -> None
],
{f, $TrigFunctions}
];
Chris Young
Back to top | Article view | comp.soft-sys.math.mathematica
csiph-web