indadd#

indadd($input, $ind, $sum) – broadcasting index-add.

Scatter-accumulates values from $input into $sum at positions given by $ind: sum[ind[n]] += input[n]. Mirrors upstream PDL::indadd (Primitive.pd pp_def 'indadd', Pars => 'input(n); indx ind(n); [io] sum(m)').

Delegates to the engine’s pdl_run_indadd(input, ind, sum). The engine handles type dispatch, broadcasting, bad-value propagation (bad ind croaks; bad input marks the target element bad), and out-of-range index detection.