how to sine wave plot

.

3 Comments

What have you attempted yet?
Raouf
Raouf on 25 Apr 2023
Nothing yet
Then we can't help you. MATLAB Answers doesn't entertain homework questions.

Sign in to comment.

Answers (2)

Vilém Frynta
Vilém Frynta on 25 Apr 2023

0 votes

Hello,
I'm sorry to tell you but Mathworks Answers is not a homework service. We do believe that it's best for you to try on your own, and then seek help when you are struggling.
You can ask your Matlab tutor or use Youtube or Matlab Documentation to get started on basics.
You can scroll down and find one example that is related to plotting a sine wave. 😉
help fplot
FPLOT Plot 2-D function FPLOT(FUN) plots the function FUN between the limits of the current axes, with a default of [-5 5]. FPLOT(FUN,LIMS) plots the function FUN between the x-axis limits specified by LIMS = [XMIN XMAX]. FPLOT(...,'LineSpec') plots with the given line specification. FPLOT(X,Y,LIMS) plots the parameterized curve with coordinates X(T), Y(T) for T between the values specified by LIMS = [TMIN TMAX]. H = FPLOT(...) returns a handle to the function line object created by FPLOT. FPLOT(AX,...) plots into the axes AX instead of the current axes. Examples: fplot(@sin) fplot(@(x) x.^2.*sin(1./x),[-1,1]) fplot(@(x) sin(1./x), [0 0.1]) If your function cannot be evaluated for multiple x values at once, you will get a warning and somewhat reduced speed: f = @(x,n) abs(exp(-1j*x*(0:n-1))*ones(n,1)); fplot(@(x) f(x,10),[0 2*pi]) See also FPLOT3, FSURF, FCONTOUR, FIMPLICIT, PLOT, FUNCTION_HANDLE. Documentation for fplot doc fplot Other uses of fplot symbolic/fplot

Categories

Find more on Just for fun in Help Center and File Exchange

Tags

Asked:

on 25 Apr 2023

Answered:

on 25 Apr 2023

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!