~ubuntu-branches/debian/sid/octave3.0/sid

« back to all changes in this revision

Viewing changes to scripts/polynomial/deconv.m

  • Committer: Bazaar Package Importer
  • Author(s): Rafael Laboissiere
  • Date: 2009-04-28 15:17:35 UTC
  • mfrom: (6.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20090428151735-gm59wmfcmwec3f9e
Tags: 1:3.0.5-3
debian/in/PACKAGE.postinst: Add -verbose option when calling 'pkg
rebuild' in octave and redirect stdin from /dev/null.  This is just to
help debugging the hang up on the mipsel buildd when installing
octave3.0 for building other packages (Bug#524745).

Show diffs side-by-side

added added

removed removed

Lines of Context:
49
49
 
50
50
  lb = ly - la + 1;
51
51
 
 
52
  ## Ensure A is oriented as Y.
 
53
  if (diff (size (y)(1:2)) * diff (size (a)(1:2)) < 0)
 
54
    a = permute (a, [2, 1]);
 
55
  endif
 
56
 
52
57
  if (ly > la)
53
58
    b = filter (y, a, [1, (zeros (1, ly - la))]);
54
59
  elseif (ly == la)
61
66
  if (ly == lc)
62
67
    r = y - conv (a, b);
63
68
  else
64
 
    r = [(zeros (1, lc - ly)), y] - conv (a, b);
 
69
    ## Respect the orientation of Y"
 
70
    if (size (y, 1) <= size (y, 2))
 
71
      r = [(zeros (1, lc - ly)), y] - conv (a, b);
 
72
    else
 
73
      r = [(zeros (lc - ly, 1)); y] - conv (a, b);
 
74
    endif
 
75
    if (ly < la)
 
76
      ## Trim the remainder is equal to the length of Y.
 
77
      r = r(end-(length(y)-1):end);
 
78
    endif
65
79
  endif
66
80
 
67
81
endfunction