using a step function to generate a square
조회 수: 1 (최근 30일)
이전 댓글 표시
Hye. I want to generate a matrix A=[0 0 1 1 1 1 0 0] using step function. Basically, my understanding of it says that a step function can be defined as a matrix having output as B=[0 0 1 1] and to generate matrix A, i need to mirror B along the y-axis. Can someone help. I have to eventually solve a transfer function using A as the input.
댓글 수: 0
답변 (1개)
Ameer Hamza
2020년 3월 11일
If you have a vector like
B = [0 0 1 1];
You can create A by flipping and concatenating B
A = [B flip(B)];
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!