I have a homework problem that was solved by our instructor: 

"Calculate the electric current of the inductor at \$t=0^+\$."



He calculated \$1/30\$ but the answer sheet was says \$-1/30\$.

Which of them is correct? 

Our instructor's work:








Question: Why is MapReduce in CouchDB called "incremental"?
Answer: Just to add slightly to what user1087981 said, the reduce functionality is incremental because of the way the reduce process is performed by CouchDB.

CouchDB uses the B-Tree that it creates from the view function, and in essence it performs the reduce calculations in clumps of values.  Here's a very simple mockup of a B-Tree from the O'Reilly Guide showing the leaf nodes for the example in the section you quoted from.



So, why is this incremental?  Well, the final reduce is only performed at query time and all the reduce calculations are stored in the B-Tree view index.  So, let's say that you add a new value to your DB that is another "fr" value.  The calculations for the 1st, 2nd and 4th nodes above don't need to be redone.  The new "fr" value is added, and the reduce function is re-calculated only for that 3rd leaf node.

Then at query time the final (rereduce=true) calculation is performed on the indexed values, and the final value returned.  You can see that this incremental nature of reduce allows the time taken to recalculate relative only to the new values being added, not to the size of the existing data set.

Having no side-effects is another important part of this process.  If, for example, your reduce functions relied on some other state being maintained as you walked through all the values, then that might work for the very first run, but then when a new value is added and an incremental reduce calculation is made it wouldn't have that same state available to it - and so it would fail to result in the correct result.  This is why reduce functions need to be side-effect free, or as user1087981 puts it "referentially transparent"