Plot 3D in Mathematica: Getting Coordinates for Points

  • Context: Mathematica 
  • Thread starter Thread starter gaby287
  • Start date Start date
  • Tags Tags
    3d Mathematica Plot
Click For Summary
SUMMARY

The discussion focuses on extracting coordinates from a 3D plot in Mathematica using the Reap and Sow functions. The specific code provided is: Reap[Print[Plot3D[x^2 y + y^2 x + 2, {x, -1, 1}, {y, -1, 1}, EvaluationMonitor :> Sow[{x, y, x^2 y + y^2 x + 2}]]]][[2, 1]]. This method effectively captures all plotted points' coordinates, allowing for further analysis or manipulation. The discussion clarifies the syntax involving the colon and greater-than symbol, which is crucial for proper function execution.

PREREQUISITES
  • Familiarity with Mathematica programming language
  • Understanding of 3D plotting concepts
  • Knowledge of functional programming techniques in Mathematica
  • Basic grasp of coordinate systems in mathematical plots
NEXT STEPS
  • Explore advanced plotting techniques in Mathematica
  • Learn about the Reap and Sow functions in depth
  • Investigate data extraction methods from Mathematica plots
  • Study optimization techniques for rendering complex 3D plots
USEFUL FOR

Mathematica users, data analysts, and mathematicians interested in 3D plotting and coordinate extraction techniques.

gaby287
Messages
14
Reaction score
0
I have a 3D Plot in Mathematica and I would like to get coordinates for points (all points) that were plotted.
 
Physics news on Phys.org
Reap[
Print[Plot3D[x^2 y + y^2 x + 2, {x, -1, 1}, {y, -1, 1}, EvaluationMonitor :> Sow[{x, y, x^2 y + y^2 x + 2}]]]
][[2, 1]]

Note, despite it not being particularly that there is a : followed by > in that.
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 5 ·
Replies
5
Views
2K