program to generate light curves