PDA

View Full Version : C++ Graphing in xcode




falc0
Sep 14, 2009, 08:08 PM
How can I plot in C++ in XCode?
Say plotting x*sine(x) from -pi to +pi, or plotting y=x^2 from -2 to 2?
:confused:



chown33
Sep 15, 2009, 01:19 AM
How can I plot in C++ in XCode?
Say plotting x*sine(x) from -pi to +pi, or plotting y=x^2 from -2 to 2?
:confused:

Your question is vague. Do you want to write a C++ program to make arbitrary graphs of math functions? Or do you just want to use a program to graph math functions?

Writing a program to draw graphs usually involves a graphing library, so google for terms like C++ graphing library. Or search for other terms like C graphing library, or Cocoa graphing library. Or substitute chart for graph. Or use Google Charts and submit a URL to retrieve a graph.

If you just want to use a program to graph math functions, look at /Applications/Utilities/Grapher.app. You don't even have to write C++ or use Xcode.

falc0
Sep 16, 2009, 12:16 AM
Chown33 thank you.
I am trying to learn how to perform pixel-level operations using C++ on the mac. Essentially drawing objects, functions, color manipulation etc.
:rolleyes: