linear independent set formation

4 ビュー (過去 30 日間)
sanket neharkar
sanket neharkar 2022 年 9 月 3 日
コメント済み: Bruno Luong 2022 年 9 月 5 日
show that {1,cost,cos2t.......cos6t} is linearly independent
using matlab code
can anyone help

採用された回答

Bruno Luong
Bruno Luong 2022 年 9 月 3 日
t = rand(1,7)*2*pi;
independent = rank(cos((0:6)'.*t)) == 7
independent = logical
1
  4 件のコメント
Matt J
Matt J 2022 年 9 月 5 日
@sanket neharkar but surely you can modify the answer appropriately.
Bruno Luong
Bruno Luong 2022 年 9 月 5 日
t = rand(1,7)*2*pi;
independent = rank(cos(t).^((0:6)')) == 7
independent = logical
1

サインインしてコメントする。

その他の回答 (1 件)

Paul
Paul 2022 年 9 月 5 日
A set of functions fi(t) is linearly indepenedent if the only solution to
a1*f1(t) + a2*f2(t) .... an*fn(t) = 0 (1)
is ai = 0 for all values of t.
If eqn(1) is true, then derivatives of the lhs are also zero.
Define the coefficients ai
a = sym('a',[1 7]);
Define the test eqn and its derivatives
syms t
for ii = 0:6
eqn(ii+1) = diff(sum(a.*cos(t).^(0:6)),t,ii);
end
Put the set of equations into the form M*a = 0
[M,b] = equationsToMatrix(eqn,a); % b = 0
The only way this equation has a nonzero solution for a for all values of t is if M is singular for all t. Check the determinant
simplify(det(M))
ans = 
It is, in general, nonzero, so the only solution for all t that satisfies (1) is ai = 0. Therefore, the functions cos(t)^n (n=0:6) are linearly independent.

カテゴリ

Help Center および File ExchangeMATLAB についてさらに検索

製品


リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by