pro parmblkintrp,logt2,logg2,logl,bcc,vmrc,vabsc,bmvc,rabsc,logmassc
; This routine interpolates on a previously-computed set of tables to return
; stellar parameters on a vector of values of log(Teff), log(g).
; On input,
;  logt2 = vector of log(Teff) values for which parameters are desired
;  logg2 = vector of log(g) values ditto
; On output,
;  logl = vector of log(Lum) values (solar units)
;  bcc = vector of bolometric correction values
;  vmrc = vector of values of (V-r)
; All output values have the same dimensionality as the inputs.

; all of the tabular data live in common area 'tables'
common tables,logln,logtn,hrb,$
              logtp,loggp,bcp,bmvp,loglump,logmassp,rabsp,vabsp,vmrp,$
              teffu,loggu,logzu,colblock

; how many arguments?
nn=n_params()

; do the work
t0=logtp(0)
dt=logtp(1)-logtp(0)
g0=loggp(0)
dg=loggp(1)-loggp(0)
kt=(logt2-t0)/dt
kg=(logg2-g0)/dg

logl=interpolate(loglump,kt,kg)
bcc=interpolate(bcp,kt,kg)
vmrc=interpolate(vmrp,kt,kg)
if(nn gt 5) then vabsc=interpolate(vabsp,kt,kg,/cubic)
if(nn gt 6) then bmvc=interpolate(bmvp,kt,kg,/cubic)
if(nn gt 7) then rabsc=interpolate(rabsp,kt,kg)
if(nn gt 8) then logmassc=interpolate(logmassp,kt,kg)

end