js: optimistic value using linear relaxtion