cconroy20 / fsps

Flexible Stellar Population Synthesis
MIT License
85 stars 48 forks source link

ages #1

Closed Nolaa closed 8 years ago

Nolaa commented 8 years ago

I am pretty new to this code and I want to plot the spectra at time of 13 Gyr after the big bang in python. I set the input parameter as sfh=2 to give a tabulated SFH, Chabrier IMF and including no dust. Here is part of my code:

sp = fsps.StellarPopulation( sfh=2, imf_type=1, sf_start=0.9)
#sfh_filename='sfh.dat'

wave, spec = sp.get_spectrum(tage=13)

and I keep getting this error:

COMPSP ERROR, maxtime too small: 7.7640709935062136E-007

I am using the default file (sfh.dat file in data diractory) and the time values in this file begins from 0.96 Gyr up to 13 Gyr, so I think the time shouldn't be the problem. I don't know what other initial parameters I need to add to my code and what is "maxtime" parameter is referred to. Any help on that will be appreciated.

cconroy20 commented 8 years ago

I do not maintain the python-FSPS interface, but I am told that the SFH=2 option is currently not supported in that framework. You might want to try the standalone FSPS for this option. Or try the other SFH options first.

Charlie

On Nov 3, 2015, at 10:19 PM, Nolaa notifications@github.com wrote:

I am pretty new to this code and I want to plot the spectra at time of 13 Gyr after the big bang. I set the input parameter as sfh=2 to give a tabulated SFH, Chabrier IMF and including no dust. Here is part of my code:

sp = fsps.StellarPopulation( sfh=2, imf_type=1, sf_start=0.9)

sfh_filename='sfh.dat'

wave, spec = sp.get_spectrum(tage=13) and I keep getting this error:

COMPSP ERROR, maxtime too small: 7.7640709935062136E-007

I am using the default file (sfh.dat file in data diractory) and the time values in this file begins from 0.96 Gyr up to 13 Gyr, so I think the time shouldn't be the problem. I don't know what other initial parameters I need to add to my code and what is "maxtime" parameter is referred to. Any help on that will be appreciated.

— Reply to this email directly or view it on GitHub https://github.com/cconroy20/fsps/issues/1.

Nolaa commented 8 years ago

Oh! I see. The thing is I am dealing with bursty SFH and the only suitable option for my work is the type 2 of sfh in fsps. Thank you though Charlie. I appreciate that.