Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I am trying to write a code for an arrow that points upwards from the center of the circle in a Graphics3D.

Manipulate[
Plot3D[RandomReal[{-0.5, 0.5}]*
UnitStep[(x - a)^2 + (y - b)^2 - 1.5^2], {x, -3, 3}, {y, -3, 3}, 
PlotRange -> All], {a, -1, 1}, {b, -1, 1}]

I want an arrow to point perpendicular from the center of this circle, how can I do that ?

share|improve this question
    
Just use VectorPlot3D. –  Spawn1701D Apr 25 '13 at 22:20

2 Answers 2

up vote 5 down vote accepted
Manipulate[
 Show[Plot3D[ RandomReal[{-0.5, 0.5}] UnitStep[(x - a)^2 + (y - b)^2 - 1.5^2], 
                                                 {x, -3, 3}, {y, -3, 3},  PlotRange -> All], 
      Graphics3D[Arrow[{{a, b, 0}, {a, b, 1/2}}]]], 
{a, -1, 1}, {b, -1, 1}]

enter image description here

share|improve this answer

Or, to make a bigger point, a solid arrow:

Manipulate[Show[
  Plot3D[
   RandomReal[{-0.5, 0.5}]*UnitStep[(x - a)^2 + (y - b)^2 - 1.5^2],
   {x, -3, 3},
   {y, -3, 3},
   PlotRange -> All],
  Graphics3D[{
    White, Specularity[1],
    Cylinder[{{a, b, 0}, {a, b, 1/2}}, .2],
    Cone[{{a, b, 1/2}, {a, b, 7/8}}, .3]}]],
 {a, -1, 1}, {b, -1, 1}]

plot

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.