Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Simple Mathematica Question

  1. Apr 2, 2012 #1
    Could someone tell me how I would go about plotting a function in Mathematica over say, x^2? or sqrt(x)?

    Thanks!
     
  2. jcsd
  3. Apr 3, 2012 #2
    Perhaps more appropriate posted here:

    https://www.physicsforums.com/forumdisplay.php?f=189

    To do this use

    Plot[x^2,{x,-3,3}]

    which is documented here

    http://reference.wolfram.com/mathematica/ref/Plot.html

    or when you are running the software hit <f1> and when the help browser pops up type in Plot or any other likely keyword you want documentation on.

    Mathematica is fanatic about exact use of {} versus [] versus (), := versus = versus == versus even === and correct capitalization. Make an error in any one of those and you will get possibly incomprehensible error messages.
     
  4. Apr 3, 2012 #3
    Thanks!

    Edit: Gah, replied before I really looked over what you said! Yeah, I know how I should go about plotting a function like that. What I am looking for is something similar to LogPlot, but where the scale of the x axis can be changed to another function.
     
    Last edited: Apr 3, 2012
  5. Apr 9, 2012 #4

    NascentOxygen

    User Avatar

    Staff: Mentor

    You want to compress the scale on the x-axis, but not logarithmically? It's difficult to see why you might want to do that. I think you would have to do the compression yourself and then re-label the axis after the computer has done the plotting.

    Exactly what are you wanting to plot?
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Similar Discussions: Simple Mathematica Question
  1. Mathematica question (Replies: 1)

  2. Mathematica question (Replies: 4)

Loading...