Added triple-linear function; corrected others. Progress towards mode-specific graphics.