How to simplify a symbolic expression sum of terms involving the Heaviside function

1 次查看(过去 30 天)
sympref('HeavisideAtOrigin', 1);
syms m n
assume(n, {'positive','integer'})
s(n) = simplify(symsum(heaviside(m), m, [0, n]), 50)
ans = 
How to obtain the symbolic sum ?

采纳的回答

Dyuman Joshi
Dyuman Joshi 2024-2-28
For that you have to assume the same for 'm' as well -
sympref('HeavisideAtOrigin', 1);
syms m n positive integer
s(n) = symsum(heaviside(m), m, [0, n])
s(n) = 

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Calculus 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by