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

Matlab question

  1. Dec 16, 2011 #1
    Hello everyone, thanks for reading my post.
    Issue 1:
    Example:
    Suppose I want to draw a graph for sec θ=x + 1/4x
    I want 'θ' on the y-axis and different values of 'x' on x-axis. Can I plot the graph using Matlab?

    Issue 2: I want to know if it's possible to plot graph of complex mathematical functions after performing complex mathematical calculations(calculations involving Calculus, Algebra, Trigonometry, Probability), both done in the Matlab software. I want to do calculations and also graph plotting in Matlab. Is this possible in Matlab? I will be doing Digital and Analog Signal Processing and Analysis. Purpose is to analyze signals/graph and generate manipulated, random signals/graph. I only know that Matlab can do things like recognition/detection.
    Please don't just tell me "Yes, you can draw graphs in Matlab".

    Issue 3: I want to write some script and the function-in-question in Matlab such that when I give different values to the variables in the function it must display the corresponding graph. Can this be done, in Matlab?
     
  2. jcsd
  3. Dec 16, 2011 #2

    S_Happens

    User Avatar
    Gold Member

    So, you haven't used matlab much/at all have you?

    1) Yes, Matlab handles inverse secant and this would be easy to do.

    2) I haven't graphed any complex functions, but it handles calculation of complex numbers just fine. As far as basic plotting, when you simply use the plot command, Matlab will ONLY plot the imaginary part if that's all you ask it to plot. If there is both real and imaginary, only the real part will be plotted. I'm assuming this means you can simply plot the real and imaginary parts separately.

    3) Sure. Since you have to define the variables in the first place, it kind of goes hand in hand with being easy to change those variables. You can simply go into the script file and change the value, write the script file in a way so that you call for an input for those values (Matlab then asks you to enter a value), or write a function file (probably the best way). If you write the function file, then you can simply call it in your script or command window using the input values that you want.
     
  4. Dec 16, 2011 #3
    I have used it few years ago, in a way which is not going to give me excellent command over this software. But now luckily, I have some serious business to do with this software. Thank you for the help. :smile:
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Matlab question
  1. MATLAB question (Replies: 3)

  2. MATLAB questions (Replies: 0)

  3. MATLAB question (Replies: 2)

  4. MATLAB question (Replies: 1)

  5. Matlab question (Replies: 10)

Loading...