Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #3002 > unrolled thread

Re: plotting contours on a sphere

Started byBob Hanlon <hanlonr@cox.net>
First post2011-06-07 12:14 +0000
Last post2011-06-07 12:14 +0000
Articles 1 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Re: plotting contours on a sphere Bob Hanlon <hanlonr@cox.net> - 2011-06-07 12:14 +0000

#3002 — Re: plotting contours on a sphere

FromBob Hanlon <hanlonr@cox.net>
Date2011-06-07 12:14 +0000
SubjectRe: plotting contours on a sphere
Message-ID<isl4me$7mj$1@smc.vnet.net>
My response only provided the replacement definition for p3. At a minimum, the OP's definition of f must also be used.

f[\[Theta]_, \[Phi]_] = Sin[\[Theta] + \[Phi]];

p3 = SphericalPlot3D[1, {\[Phi], 0, Pi}, {\[Theta], 0, 2 Pi},
  ColorFunctionScaling -> False,
  ColorFunction -> Function[{x, y, z, \[Theta], \[Phi], r},
    ColorData["TemperatureMap"]
     [Rescale[f[\[Phi], \[Theta]], {-1, 1}]]],
  Mesh -> 9,
  MeshFunctions -> {Function[{x, y, z, \[Theta], \[Phi], r}, 
     f[\[Phi], \[Theta]]]},
  BoundaryStyle -> Transparent]

$Version

"8.0 for Mac OS X x86 (64-bit) (February 23, 2011)"


Bob Hanlon

---- "Nasser M. Abbasi" <nma@12000.org> wrote: 

=============
On 6/6/2011 3:23 AM, Bob Hanlon wrote:
> p3 = SphericalPlot3D[1, {\[Phi], 0, Pi}, {\[Theta], 0, 2 Pi},
>    ColorFunctionScaling ->  False,
>    ColorFunction ->  Function[{x, y, z, \[Theta], \[Phi], r},
>      ColorData["TemperatureMap"]
>       [Rescale[f[\[Phi], \[Theta]], {-1, 1}]]],
>    Mesh ->  9,
>    MeshFunctions ->
>     {Function[{x, y, z, \[Theta], \[Phi], r},
>       f[\[Phi], \[Theta]]]}]
>
>
> Bob Hanlon
>

Hi Bob;

what version of Mathematica did you use? on 8.0.1,
windows 7, I get an error message.

MeshFunctions::invmeshf: MeshFunctions->{At Line = 1, the input
was:,p3=SphericalPlot3D[1,{\[Phi],0,Pi},{\[Theta],0,2Pi},ColorFunctionScaling->False,
ColorFunction->Function[{x,y,z,\[Theta],\[Phi],r},
ColorData[TemperatureMap][Rescale[f[\[Phi],\[Theta]],{-1,1}]]],
Mesh->9,MeshFunctions->{Function[{x,y,z,\[Theta],\[Phi],r},f[\[Phi],
\[Theta]]]}],f[#5,#4]&} must be a pure function or a list of pure functions. >>

here is a screen shot also fyi

http://12000.org/tmp/june_5_2011/msg.png

--Nasser


--

Bob Hanlon

[toc] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web