フィルターのクリア

Symbolic entry of rem function

2 ビュー (過去 30 日間)
Nate
Nate 2014 年 9 月 27 日
コメント済み: DmArcher 2017 年 4 月 24 日
When entering the following symbolic code using the remainder (rem) function, Matlab returns x(t,P) = 0, which is clearly wrong.
syms t P
x(t, P) = rem(t,P);
x
I have tried all combinations of sym, syms, symfun, but the result is the same. I need to enter the symbolic function x = rem(t,P) to perform symbolic integration on it over the period t = [0:P].
Help is appreciated, thanks

採用された回答

Star Strider
Star Strider 2014 年 9 月 27 日
Wrong function. Use mod instead for symbolic operations:
syms t P
x(t, P) = mod(t,P);
x
returns:
x(t, P) =
t*(1 mod P)
  5 件のコメント
Star Strider
Star Strider 2014 年 9 月 28 日
My pleasure!
It was a fun challenge for me!
DmArcher
DmArcher 2017 年 4 月 24 日
When I type your code I get some errors. Is it possible that you can tell me where I did it wrong? Thx.

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

その他の回答 (0 件)

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by