9
$\begingroup$

How to show the (16 X 4) mesh intersection points by a tiny red dots?

ParametricPlot[v { Cos[u], Sin[u]},  {u, 0, 2 Pi},{v,1,3}, Mesh-> {15,3} ]

enter image description here

$\endgroup$
  • 1
    $\begingroup$ Narasimham, please consider reverting your latest edit, Your edit makes the answers completely irrelevant (although all three answers do work for your original question). I suggest you post a new question for the 3D version of the problem. $\endgroup$ – kglr Aug 19 '17 at 20:33
  • $\begingroup$ Thanks, got it, will do.. $\endgroup$ – Narasimham Aug 19 '17 at 20:39
9
$\begingroup$
ParametricPlot[
    v {Cos[u], Sin[u]}, {u, 0, 2 Pi}, {v, 1, 3}, 
    Mesh   -> {15, 3},
    Epilog -> {
        PointSize @ .02, Red, 
        Point @ Catenate @ Array[
            Function[{u, v}, v {Cos[u], Sin[u]}], 
            {15 + 2, 3 + 2}, 
            {{0, 2 Pi}, {1, 3}}
        ]
}]

enter image description here

As pointed by Shutao TANG, Catenate is new so one can replace it with Flatten[#,1]&.

Points on positive side of x axis are doubled since it is the beginning and the end of u domain. But I left them for generality, like u -> {0, 1} cases.

| improve this answer | |
$\endgroup$
5
$\begingroup$

Due to Catenate[] is a new function for V10, here is a solution for V9 or earlier version:

You just need to repalce ParametricPlot[] with Table[] and add the interval values Pi/8 and 1 to generate the intersection coordinates.

Show[
 {ParametricPlot[v {Cos[u], Sin[u]}, {u, 0, 2 Pi}, {v, 1, 3}, 
   Mesh -> {15, 3}], 
  Graphics[
   {Red, PointSize[Medium], 
    Point /@ 
     Table[
      v {Cos[u], Sin[u]}, 
      {u, 0, 2 Pi, Pi/8}, {v, 1, 3, 1/2}]}]}
]

enter image description here

| improve this answer | |
$\endgroup$
2
$\begingroup$

Use a one-parameter ParametricPlot to get the mesh points:

p2 = ParametricPlot[ # {Cos[u], Sin[u]} & /@ Range[1, 3, .5], {u, 0, 2 π}, 
   Mesh -> {Range[0, 2 Pi, 2 π/16]}, PlotStyle -> None, 
   MeshStyle -> Directive[Red, PointSize[Large]], Axes -> False]

enter image description here

Combine it with the original two-parameter plot using Show or using Epilog:

Show[ParametricPlot[v {Cos[u], Sin[u]}, {u, 0, 2 π}, {v, 1, 3}, Mesh -> {15, 3}], p2]

or

ParametricPlot[v {Cos[u], Sin[u]}, {u, 0, 2 π}, {v, 1, 3}, Mesh->{15, 3}, Epilog->p2[[1]]]

both give

enter image description here

Update: to see the nodes... sans the surface that spans them

Show[ParametricPlot[v {Cos[u], Sin[u]}, {u, 0, 2 \[Pi]}, {v, 1, 3}, 
  Mesh -> {15, 3}, BoundaryStyle -> Gray, PlotStyle -> None], p2]

enter image description here

| improve this answer | |
$\endgroup$
  • $\begingroup$ Is it possible to avoid repetition of parametrization with a single function definition? The aim of my question is to see the nodes... sans the surface that spans them. $\endgroup$ – Narasimham Aug 19 '17 at 20:38
  • $\begingroup$ @Narasimham, pp2 gives just the nodes. $\endgroup$ – kglr Aug 19 '17 at 20:54
  • $\begingroup$ Indeed. Just wanted to see small circles at the nodes generated using ParametricPlot3D as well. $\endgroup$ – Narasimham Aug 19 '17 at 21:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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