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

Regarding matlab

  1. Jul 30, 2009 #1
    Plot the parabola which has the equation y = x^2+2x+3 for -20<x<20 using Matlab.
     
  2. jcsd
  3. Jul 30, 2009 #2
    need the solution
     
  4. Jul 30, 2009 #3
    Hey, mishal,

    This is the simple solution to your problem:
    x = -20:0.01:20;
    y = x.^2 + 2*x + 3;
    plot(x,y);

    You can copy and paste this into your Matlab Command Prompt. If you need more information, feel free to ask me.

    By the way, you can search Matlab Help, that's very good source for self learning. And you can go to: http://www.mathworks.com/matlabcentral/index.html" [Broken] to find more .m files that might help you.

    PS: Mathematics is a suitable source for this kind of question. (Or Homework or Coursework questions)
     
    Last edited by a moderator: May 4, 2017
  5. Jul 31, 2009 #4

    MATLABdude

    User Avatar
    Science Advisor

    TChi, this is a particularly simple question, so what you did isn't particularly egregious, but we here at PhysicsForums try to help people work through their problems (especially when it's homework). Homework should be in the Homework section (there's an Engineering and CompSci section), but there's also a Computer Science and Programming subforum as well (and there's a Mathematical Software section within that--for things like MATLAB, Octave and/or Mathematica)

    EDIT: mods will occasionally delete responses that out-and-out answer questions (that should be answered by the question asker), and move homework to appropriate subforums. Not to snerk, just to let you know.
     
  6. Aug 2, 2009 #5
    hey thankyou so much for your kind information
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Regarding matlab
  1. Regarding generators (Replies: 5)

  2. Matlab Question (Replies: 2)

  3. Regarding batteries (Replies: 7)

  4. Matlab dmodce (Replies: 1)

Loading...