[Csnd] "sum" -opcode works differently compared to a simple "+" sign?

Dear list,

could it be that the "sum" -opcode works differently compared to a simple "+" sign?

For me it looks a lot like the first item (a1 in my example below) is summed twice in sum.

You can see it if you compare the output of the amplitude.

I have Csound 6.17 running on Linux ubuntu 20.04.


Jan Jacob

sound | movement | object | space
sonic architecture | site: http://www.sonicarchitecture.de
spatial electronic composition | higher order ambisonic music



- odac



sr = 48000

ksmps = 128

nchnls = 2

0dbfs = 1.0

instr 1

iamp = p4

a1 oscil iamp, 440

a2 oscil iamp, 440

a3 oscil iamp, 440

a4 oscil iamp, 440

aout sum a1, a2, a3, a4

;aout = a1 + a2 + a3 + a4 ; uncomment this for comparison

outs aout, aout




i1 0 1 .5



Csound mailing list
Send bugs reports to
        Issues · csound/csound · GitHub
Discussions of bugs and features can be posted here

There's a bug in it. It was introduced I think in 6.16 and it has been fixed after 6.17 was released.

Prof. Victor Lazzarini
Maynooth University

Very useful. I have some very long string of sums sometimes (no pun intended).
This would be very useful and helpful if all the bugs have been dealt with.
Got to try that one. Very cool.


That is a cool substitute for a long strings of sums using ‘+’ signs.
Works pretty good. I like it. That’s a keeper. Thank you.