# ProSpect: BC03 Spectral Checks

#### 2018-03-02

``````library(ProSpect)
library(magicaxis)``````

** BC03 SSPs **

Make a colour vector.

``colvec=hsv(h=magmap(BC03lr\$Age,lo=1e6,hi=1e10,range=c(0,2/3), stretch = 'log', flip=T, type='num', bad=2/3)\$map, v=0.7, alpha=0.5)``

We can check how much luminosity is generated by different age stellar populations for the individual simple stellar populations provided by BC03.

``````for(j in 1:6){
par(mar=c(3.1,3.1,1.1,1.1))
magplot(BC03lr\$Wave, BC03lr\$Zspec[[j]][1,], type='l', log='xy', col=colvec[1], xlim=c(3e2,1e5), ylim=c(1e-7,10), majorn=c(5,8), xlab=BC03lr\$Labels\$Wavelab, ylab=BC03lr\$Labels\$Lumlab, grid=TRUE)
for(i in 2:221){lines(BC03lr\$Wave, BC03lr\$Zspec[[j]][i,], col=colvec[i])}
legend('topleft', legend=paste('Z=',BC03lr\$Z[j]))
magbar('topright',range = c(1e6,1e10),log = TRUE, col = hsv(h = seq(2/3, 0, len = 10), v=0.7), title = 'Age / Yrs', titleshift = 0.5)
}``````

We can check how much luminosity is generated by different age stellar populations for a constant 1 solar mass per year star formation rate for BC03.

``````for(j in 1:6){
par(mar=c(3.1,3.1,1.1,1.1))
magplot(BC03lr\$Wave, BC03lr\$Zspec[[j]][1,]*BC03lr\$AgeWeights[1], type='l', log='xy', col=colvec[1], xlim=c(3e2,1e5), ylim=c(1e-7,10)*1e6, majorn=c(5,8), xlab=BC03lr\$Labels\$Wavelab, ylab=BC03lr\$Labels\$LumAgelab, grid=TRUE)
for(i in 2:221){lines(BC03lr\$Wave, BC03lr\$Zspec[[j]][i,]*BC03lr\$AgeWeights[i], col=colvec[i])}
magbar('topright',range = c(1e6,1e10),log = TRUE, col = hsv(h = seq(2/3, 0, len = 10), v=0.7), title = 'Age / Yrs', titleshift = 0.5)
legend('topleft', legend=paste('Z=',BC03lr\$Z[j]))
}``````