How to combine 2 functions in one graph with different line

조회 수: 2 (최근 30일)
farizah
farizah 2014년 11월 17일
댓글: farizah 2014년 11월 17일
How do I combine this two functions x1=6sin((5.6309x10^9)t) and x2=sin((5.6309x10^9)t)in one graph with two different color of the line. The value of t=(0:0.1:5)

채택된 답변

MA
MA 2014년 11월 17일
clear all
close all
clc;
t=0:0.1:5;
x1=6*sin((5.6309*10^9)*t);
x2=sin((5.6309*10^9)*t);
plot(t,x1,'b',t,x2,'r')
legend('x1','x2')

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Graph and Network Algorithms에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by