Main Content

FVTool

필터 시각화 툴

설명

필터 시각화 툴은 필터의 응답, 계수 및 기타 정보를 표시하고 분석할 수 있는 대화형 방식 앱입니다. FVTool필터 디자이너를 동기화하여 필터 설계에서 변경된 내용을 즉시 시각화할 수도 있습니다.

이 앱에서는 다음을 볼 수 있습니다.

  • 크기 응답

  • 위상 응답

  • 군지연

  • 위상 지연

  • 임펄스 응답

  • 계단 응답

  • 극점-영점 플롯

  • 필터 계수

  • 필터 정보

자세한 내용은 분석 유형 항목을 참조하십시오.

DSP System Toolbox™가 설치되어 있는 경우 FVTool은 필터 System object™의 주파수 응답을 시각화할 수도 있습니다. 스트리밍 데이터를 실시간으로 필터링해야 하는 경우 System Object를 사용하는 것이 좋습니다. 자세한 내용은 fvtool (DSP System Toolbox) 항목을 참조하십시오.

Filter Visualization Tool

FVTool 열기

프로그래밍 방식 사용에 설명된 방법 중 하나를 사용하여 프로그래밍 방식으로 FVTool을 열 수 있습니다.

예제

모두 확장

3dB의 통과대역 리플, 50dB의 저지대역 감쇠량, 1kHz의 샘플 레이트 및 300Hz의 정규화된 통과대역 경계를 갖는 6차 타원 필터가 있다고 가정하겠습니다. 필터의 크기 응답을 표시합니다.

[b,a] = ellip(6,3,50,300/500);
fvtool(b,a)

Figure Figure 1: Magnitude Response (dB) contains an axes object. The axes object with title Magnitude Response (dB), xlabel Normalized Frequency ( times pi blank r a d / s a m p l e ), ylabel Magnitude (dB) contains an object of type line.

150Hz 및 350Hz의 저지대역 주파수와 200Hz 및 300Hz의 통과대역 주파수를 갖는 50차 대역통과 FIR 필터를 설계합니다. 샘플 레이트는 1000Hz입니다. 필터의 크기 응답과 위상 응답을 시각화합니다.

N = 50;
Fstop1 = 150;
Fstop2 = 350;

Fpass1 = 200;
Fpass2 = 300;

Fs = 1e3;

bpFilt = designfilt("bandpassfir",FilterOrder=N, ...
StopbandFrequency1=Fstop1,StopbandFrequency2=Fstop2,...
PassbandFrequency1=Fpass1,PassbandFrequency2=Fpass2,...
SampleRate=Fs);

fvtool(bpFilt,Analysis="freq")

Figure Figure 1: Magnitude Response (dB) and Phase Response contains an axes object. The axes object with title Magnitude Response (dB) and Phase Response, xlabel Frequency (Hz), ylabel Magnitude (dB) contains an object of type line.

툴스트립에서 분석 파라미터 버튼을 선택합니다. 플롯과 관련된 파라미터를 표시하는 분석 파라미터 창이 나타납니다.

fvtool_analysisparams2.png

6차 타원 필터의 크기 응답을 표시합니다. 통과대역 리플을 3dB로, 저지대역 감쇠량을 50dB로, 샘플 레이트를 1kHz로, 정규화된 통과대역 경계를 300Hz로 지정합니다. FVTool의 핸들을 가져옵니다.

[b,a] = ellip(6,3,50,300/500);
h = fvtool(b,a)

Figure Figure 1: Magnitude Response (dB) contains an axes object. The axes object with title Magnitude Response (dB), xlabel Normalized Frequency ( times pi blank r a d / s a m p l e ), ylabel Magnitude (dB) contains an object of type line.

h = 
  Figure (filtervisualizationtool) with properties:

      Number: []
        Name: 'Figure 1: Magnitude Response (dB)'
       Color: [0.9400 0.9400 0.9400]
    Position: [348 376 583 437]
       Units: 'pixels'

  Use get to show all properties

FVTool 핸들을 사용하여 필터의 위상 응답을 표시합니다.

h.Analysis = "phase"

Figure Figure 1: Phase Response contains an axes object. The axes object with title Phase Response, xlabel Normalized Frequency ( times pi blank r a d / s a m p l e ), ylabel Phase (radians) contains an object of type line.

h = 
  Figure (filtervisualizationtool) with properties:

      Number: []
        Name: 'Figure 1: Phase Response'
       Color: [0.9400 0.9400 0.9400]
    Position: [1 1 1024 657]
       Units: 'pixels'

  Use get to show all properties

플롯 범례를 활성화하고 텍스트를 추가합니다.

legend(h,"Phase plot")

Figure Figure 1: Phase Response contains an axes object. The axes object with title Phase Response, xlabel Normalized Frequency ( times pi blank r a d / s a m p l e ), ylabel Phase (radians) contains an object of type line. This object represents Phase plot.

샘플 레이트를 1kHz로 지정합니다. 중심이 맞춰진 양측 응답을 표시합니다.

h.Fs = 1000;
h.FrequencyRange = "[-Fs/2, Fs/2)"

Figure Figure 1: Phase Response contains an axes object. The axes object with title Phase Response, xlabel Frequency (Hz), ylabel Phase (radians) contains an object of type line. This object represents Phase plot.

h = 
  Figure (filtervisualizationtool) with properties:

      Number: []
        Name: 'Figure 1: Phase Response'
       Color: [0.9400 0.9400 0.9400]
    Position: [1 1 1024 657]
       Units: 'pixels'

  Use get to show all properties

플롯의 모든 속성을 봅니다. FVTool 특정 속성은 목록 끝부분에 있습니다.

get(h)
                     Grid: on
                   Legend: 'on'
               DesignMask: 'off'
          SOSViewSettings: [1x1 dspopts.sosview]
                       Fs: 1000
                 Alphamap: [0 0.0159 0.0317 0.0476 0.0635 0.0794 0.0952 0.1111 0.1270 0.1429 0.1587 0.1746 0.1905 0.2063 0.2222 0.2381 0.2540 0.2698 0.2857 0.3016 0.3175 0.3333 0.3492 0.3651 0.3810 0.3968 0.4127 0.4286 0.4444 0.4603 0.4762 0.4921 ... ]
          CloseRequestFcn: 'closereq'
                    Color: [0.9400 0.9400 0.9400]
                 Colormap: [256x3 double]
              ContextMenu: [0x0 GraphicsPlaceholder]
              CurrentAxes: [1x1 Axes]
         CurrentCharacter: ''
            CurrentObject: [0x0 GraphicsPlaceholder]
             CurrentPoint: [0 0]
             DockControls: off
                 FileName: ''
            IntegerHandle: off
           InvertHardcopy: on
              KeyPressFcn: ''
            KeyReleaseFcn: ''
                     Name: 'Figure 1: Phase Response'
                 NextPlot: 'add'
              NumberTitle: off
               PaperUnits: 'inches'
         PaperOrientation: 'portrait'
            PaperPosition: [-0.8700 2.2150 10.2400 6.5700]
        PaperPositionMode: 'auto'
                PaperSize: [8.5000 11]
                PaperType: 'usletter'
                  Pointer: 'arrow'
        PointerShapeCData: [16x16 double]
      PointerShapeHotSpot: [1 1]
                 Position: [1 1 1024 657]
                 Renderer: 'opengl'
             RendererMode: 'auto'
                   Resize: on
                ResizeFcn: @(~,~)fix_listbox_position(this,hFVT)
            SelectionType: 'normal'
                  ToolBar: 'none'
                     Type: 'figure'
                    Units: 'pixels'
      WindowButtonDownFcn: ''
    WindowButtonMotionFcn: ''
        WindowButtonUpFcn: ''
        WindowKeyPressFcn: ''
      WindowKeyReleaseFcn: ''
     WindowScrollWheelFcn: ''
              WindowStyle: 'docked'
             BeingDeleted: off
            ButtonDownFcn: ''
                 Children: [5x1 Graphics]
                 Clipping: on
                CreateFcn: ''
                DeleteFcn: ''
               BusyAction: 'queue'
         HandleVisibility: 'off'
                  HitTest: on
            Interruptible: on
                   Parent: [1x1 Root]
                 Selected: off
       SelectionHighlight: on
                      Tag: 'filtervisualizationtool'
                 UserData: []
                  Visible: on
               PhaseUnits: 'Radians'
                 Analysis: 'phase'
           FrequencyRange: '[-Fs/2, Fs/2)'
             PhaseDisplay: 'Phase'
        OverlayedAnalysis: ''
           FrequencyScale: 'Linear'
            PolyphaseView: 'off'
          FrequencyVector: [0 0.0039 0.0078 0.0118 0.0157 0.0196 0.0235 0.0275 0.0314 0.0353 0.0392 0.0431 0.0471 0.0510 0.0549 0.0588 0.0627 0.0667 0.0706 0.0745 0.0784 0.0824 0.0863 0.0902 0.0941 0.0980 0.1020 0.1059 0.1098 0.1137 0.1176 0.1216 ... ]
            ShowReference: 'on'
           NumberofPoints: 8192
      NormalizedFrequency: 'off'

관련 예제

프로그래밍 방식으로 사용

모두 확장

fvtool(b,a)는 FVTool을 열고 분자 b와 분모 a로 정의된 디지털 필터의 크기 응답을 표시합니다. ba 계수를 거듭제곱(z-1)의 오름차순으로 지정합니다.

fvtool(sos)는 FVTool을 열고 L×6 2차섹션형 행렬로 정의된 디지털 필터의 크기 응답을 표시합니다.

sos=[b01b11b211a11a21b02b12b221a12a22b0Lb1Lb2L1a1La2L]

sos의 행에는 H(z)에 대한 2차섹션형 종속 연결의 분자 계수와 분모 계수인 bik와 aik가 포함되어 있습니다.

H(z)=gk=1LHk(z)=gk=1Lb0k+b1kz1+b2kz21+a1kz1+a2kz2.

섹션 개수 L은 2보다 크거나 같아야 합니다. 섹션 개수가 2보다 작으면 fvtool이 입력값을 분자 벡터로 간주합니다.

fvtool(d)는 FVTool을 열고 디지털 필터 d의 크기 응답을 표시합니다. designfilt를 사용하여 주파수-응답 사양을 기반으로 d를 생성합니다.

fvtool(b1,a1,b2,a2,...,bN,aN)은 FVTool을 열고 분자 b1, …, bN과 분모 a1, ..., aN으로 정의된 여러 필터의 크기 응답을 표시합니다.

fvtool(sos1,sos2,...,sosN)은 FVTool을 열고 2차섹션형 행렬 sos1, sos2, ..., sosN으로 정의된 여러 필터의 크기 응답을 표시합니다.

fvtool(Hd)는 FVTool을 열고 dfilt 필터 객체 Hd 또는 dfilt 필터 객체의 배열에 대한 크기 응답을 표시합니다.

fvtool(Hd1,Hd2,...,HdN)은 FVTool을 열고 dfilt 객체 Hd1, Hd2, ...HdN에 포함된 필터의 크기 응답을 표시합니다.

h = fvtool(___)은 Figure 핸들 h를 반환합니다. 이 핸들을 사용하여 명령줄에서 FVTool과 상호 작용할 수 있습니다. 자세한 내용은 Controlling FVTool from the MATLAB Command Line 항목을 참조하십시오.

세부 정보

모두 확장

버전 내역

R2006a 이전에 개발됨

모두 확장