function [A b A_sys,b_sys] = ddm_lin_sys_fft_zp_fact(Q, R, win, win_der, mf_ders, sig, N, zp_fct, fs,all_zp_bins)
  
  assert(R == size(mf_ders, 2) );
  N_fft = N*zp_fct;
  win_mat  = repmat(win, 1, R);
  frqs_fft = [0:N_fft-1]'*fs*2*pi/N_fft;
  [str_idx end_idx] = zpzh_idxs(N);
  sig_mat  = repmat(sig, 1, R);
  fft_sig_mat_bffr     = win_mat .* sig_mat .* mf_ders;
  fft_sig_win_der_bffr = win_der .* sig;
  fft_sig_win_der = fft([fft_sig_win_der_bffr(str_idx,:);zeros(N_fft-N,1);fft_sig_win_der_bffr(end_idx,:)],N_fft,1);
  A =   fft([fft_sig_mat_bffr(str_idx,:);zeros(N_fft-N,R);fft_sig_mat_bffr(end_idx,:)], N_fft, 1); %zero padded sheeza
  b = -(fft_sig_win_der - 1j*frqs_fft.* A(:,1));
% create the actual matrixes
  A_sys = zeros(Q,Q,N_fft-Q+1);
  b_sys = zeros(Q,1,N_fft-Q+1);
  stp = zp_fct;
  if ~exists('all_cp_bins','var') || all_cp_bins == 1
    stp = 1;
  end
  for k=1:Q
    A_sys(k,:,:) = shiftdim(A(k:stp:N_fft-Q+k,:).',-1);
    b_sys(k,:,:) = shiftdim(b(k:stp:N_fft-Q+k).',-1);
  end
end
