How to combine 2 functions in one graph with different line

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 日

0 投票

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 件)

カテゴリ

ヘルプ センター および File ExchangeGraph and Network Algorithms についてさらに検索

質問済み:

2014 年 11 月 17 日

コメント済み:

2014 年 11 月 17 日

Community Treasure Hunt

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

Start Hunting!

Translated by