# v_lpcfq2zz

## PURPOSE

V_LPCFQ2ZZ Convert frequencies and q factors to z-plane poles ZZ=(F,Q)

## SYNOPSIS

function zz=v_lpcfq2zz(f,q)

## DESCRIPTION

    V_LPCFQ2ZZ Convert frequencies and q factors to z-plane poles ZZ=(F,Q)
    all input values are in normalized Hz
     roots are at exp(2*pi*f*(-1/(2q) +- j)
     if f has more columns than q, remaining columns are real roots at -f

## CROSS-REFERENCE INFORMATION

This function calls:

This function is called by:

## SOURCE CODE

    0001 function zz=v_lpcfq2zz(f,q)
    0002 %V_LPCFQ2ZZ Convert frequencies and q factors to z-plane poles ZZ=(F,Q)
    0003 %all input values are in normalized Hz
    0004 % roots are at exp(2*pi*f*(-1/(2q) +- j)
    0005 % if f has more columns than q, remaining columns are real roots at -f
    0006
    0007 %      Copyright (C) Mike Brookes 1998
    0008 %      Version: $Id: v_lpcfq2zz.m 10865 2018-09-21 17:22:45Z dmb $
    0009 %
    0010 %   VOICEBOX is a MATLAB toolbox for speech processing.
    0011 %   Home page: http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/voicebox.html
    0012 %
    0013 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    0014 %   This program is free software; you can redistribute it and/or modify
    0015 %   it under the terms of the GNU Lesser General Public License as published by
    0016 %   the Free Software Foundation; either version 3 of the License, or
    0017 %   (at your option) any later version.
    0018 %
    0019 %   This program is distributed in the hope that it will be useful,
    0020 %   but WITHOUT ANY WARRANTY; without even the implied warranty of
    0021 %   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    0022 %   GNU Lesser General Public License for more details.
    0023 %
    0024 %   You can obtain a copy of the GNU Lesser General Public License from
    0025 %   https://www.gnu.org/licenses/ .
    0026 %
    0027 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    0028
    0029 [nf,pf]=size(f);
    0030 if nargin < 2
    0031    pq=0;
    0032 else
    0033    pq=size(q,2);
    0034 end;
    0035 zz=zeros(nf,pf+pq);
    0036 if pq
    0037    ii=1:pq;
    0038    zz(:,2*ii-1)=exp(pi*f(:,ii).*(2i-q.^(-1)));
    0039    zz(:,2*ii)=conj(zz(:,2*ii-1));
    0040 end
    0041 if pf>pq
    0042    ii=1+pq:pf;
    0043    zz(:,ii+pq)= exp(-2*pi*f(:,ii));
    0044 end