#!/bin/sh
set -e

#   sk: re-write for new timavg and spcdns.
#
#                  spectrum            gjb,ml,dl. oct 24/00 - sk.
#   ---------------------------------- standing and transient spectral
#                                      terms ignoring mountains.
#   Usage: spectrum x tx txtx txp2
#

#   ---------------------------------- specdens of time mean term.
      timavg $1  $2  xp.
      spcdns $2   _  $3

#   ---------------------------------- specdens of transients.
      spcdns xp.  _  xp2.
      timavg xp2. $4

      rm xp. xp2.
#   ....................................................................spectrum
