Square Wave Generator

Generate an array of values that represent a square wave.

이 제출물을 팔로우합니다

This is a simple function that returns an array of values that represent a square wave based on two essential inputs (total time and period) and four optional inputs (plot option, minimum amplitude, maximum amplitude, and resolution).

[f] = squareWave(time,per,plotChk,Amin,Amax,res)

Units are arbitrary, but time and amplitude are assumed.

The following examples illustrate its use:

[y] = squareWave(10,1);
OR
[y] = squareWave(10,1,1);
OR
[y] = squareWave(10,1,-1,1);
OR
[y] = squareWave(10,1,-1,1,1);
OR
[y] = squareWave(10,1,-1,1,1,1e5);

인용 양식

John Pritchard (2026). Square Wave Generator (https://kr.mathworks.com/matlabcentral/fileexchange/33622-square-wave-generator), MATLAB Central File Exchange. 검색 날짜: .

카테고리

Help CenterMATLAB Answers에서 Fourier Analysis and Filtering에 대해 자세히 알아보기

일반 정보

MATLAB 릴리스 호환 정보

  • 모든 릴리스와 호환

플랫폼 호환성

  • Windows
  • macOS
  • Linux
버전 퍼블리시됨 릴리스 정보 Action
1.3.0.0

Updated examples in help section of M-file to be more intuitive.

1.2.0.0

Examples in file description appropriately updated.

1.0.0.0