The book "Unix Text Processing" by Dale Dougherty and Tim O&rsquo;Reilly (INTERNET "UTP Revi
val" RELEASE &mdash; 2004 available at https://home.windstream.net/kollar/utp/utp-1.0.pdf) features a very illuminating description of stream editing and sed on pp. 288. 