2
$\begingroup$

I'm trying to plot a simple picture: a plane with a circle in it, and three vectors in the curve. Mathematica keeps saying that the array "has the wrong dimensions for a graphics coordinate list" and I don't know what it wants me to do. My code so far is:

Show[
  ParametricPlot3D[{Cos[s], Sqrt[3] Sin[s]/2, Sin[s]/2 }, {s, 0, 3 π/2}, 
    PlotStyle -> Red], 
  Plot3D[y/Sqrt[3], {x, -4, 4}, {y, -4, 4}, 
    Mesh -> Automatic, 
    MeshStyle -> 
      Directive[RGBColor[.3, .32, 0.], Opacity[.1], AbsoluteThickness[.755], DotDashed], 
    PlotStyle -> RGBColor[.82, .69, 0.]], 
  Graphics3D[
    Arrow[{{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
           {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}}]], 
  Graphics3D[
    Arrow[{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
          {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, -Sqrt[6]/4, -Sqrt[2]/4}]], 
  Graphics3D[
    Arrow[{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
          {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {0, -1/2, -Sqrt[3]/2}]], 
  Boxed -> False,  
  AspectRatio -> 1, 
  AxesOrigin -> {0, 0, 0}, 
  PlotRange -> {{-2, 2}, {-2, 2}, {-1, 1.5}}]

I know I don't need to use a separate Graphics3D expression for every arrow, but my code doesn't do what I want if I put everything together like:

Graphics3D[{
  Arrow[{{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
         {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}}],
  Arrow[{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
        {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, -Sqrt[6]/4, -Sqrt[2]/4}], 
  Arrow[{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, 
        {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {0, -1/2, -Sqrt[3]/2}]}]

Help?

$\endgroup$

closed as off-topic by m_goldberg, Yves Klett, Karsten 7., bbgodfrey, Dr. belisarius Feb 28 '15 at 18:26

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – m_goldberg, Yves Klett, Karsten 7., bbgodfrey, Dr. belisarius
If this question can be reworded to fit the rules in the help center, please edit the question.

4
$\begingroup$

Try this. You had problem with too few { in the Arrow calls

Show[ParametricPlot3D[{Cos[s], Sqrt[3] Sin[s]/2, Sin[s]/2}, {s, 0, 3 π/2}, PlotStyle -> Red], 
 Plot3D[y/Sqrt[3], {x, -4, 4}, {y, -4, 4}, Mesh -> Automatic, 
  MeshStyle -> Directive[RGBColor[0.3`, 0.32`, 0.`], Opacity[0.1`], AbsoluteThickness[0.755`], DotDashed], 
  PlotStyle -> RGBColor[0.8200000000000001`, 0.6900000000000001`, 0.`]], 
 Graphics3D[Arrow[{{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}}]], 
 Graphics3D[Arrow[{{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {Sqrt[2]/2, -Sqrt[6]/4, -Sqrt[2]/4}}]], 
 Graphics3D[Arrow[{{-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4}, {-Sqrt[2]/2, Sqrt[6]/4, Sqrt[2]/4} + {0, -1/2, -Sqrt[3]/2}}]], 
 Boxed -> False, AspectRatio -> 1, AxesOrigin -> {0, 0, 0}, PlotRange -> {{-2, 2}, {-2, 2}, {-1, 1.5}}]

Mathematica graphics

ref comment: The third arrow is there. Just need to rotate the plot to see it.

Mathematica graphics

$\endgroup$
  • $\begingroup$ I got something similar to this here, but the tips weren't showing. Yours is better, thanks. However, we had three arrows, and our pictures only show two of them. I tried messing with PlotRange to see if the third arrow would show, but nothing. Any ideas? $\endgroup$ – Ivo Terek Feb 28 '15 at 3:33
  • $\begingroup$ @IvoTerek I just pasted your code as is, just fixed the syntax error. The third arrow is there, you just need to rotate the 3D to see it. it is hiding. It is your arrows, so the directions are setup by you and I did not change these. $\endgroup$ – Nasser Feb 28 '15 at 3:37
  • $\begingroup$ You are right. I thought that the plane was more transparent. Thanks. Now I'll try to make this better :) $\endgroup$ – Ivo Terek Feb 28 '15 at 3:40

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