function pi = compute_pi_adder(bnode, bnet)

n = bnode.self;
arity = bnode.self_size;
pi = zeros(arity, 1);
pi_msg = bnet.pearl.msg{n}.pi_from_parent{1};
for x=1:arity
  % P(x|u)=1 iff x=u+delta
  u = wrap(x-bnode.delta, arity);
  pi(x) = pi_msg(u);
end
