I have pw(t):= piecewise([x > 0 and x < 1, 1], [Otherwise, 0])
When I try to evaluate: pw(1/2) it returns pw(1/2)... I wonder if the function is bugged Thanx

 채택된 답변

Sally Al Khamees
Sally Al Khamees 2016년 12월 23일

0 개 추천

If you have R2016b, you can just use the piecewise function:
Here is an example:

댓글 수: 1

Walter Roberson
Walter Roberson 2016년 12월 23일
Different piecewise functions: the user was asking about use while running in a MuPAD notebook.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

질문:

2015년 1월 1일

댓글:

2016년 12월 23일

Community Treasure Hunt

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

Start Hunting!

Translated by