I've got data that, when plotted on a log-log scale, looks like two straight lines that gently bend and blend into each other. See the picture below.
I don't know how to find a function to fit that. Now, I know that I should use some kind of broken power law, and I know how to make one that asymptotically converges to a constant, but I don't know how to combine two power laws. I've found something that looks just right as far as its shape is concerned, and even some Python code to generate it, but I can't figure out how to tweak it to fit my data without breaking the continuity between the two power laws:
def chabrier03individual(m):
k = 0.158 * exp(-(-log(0.08))**2/(2 * 0.69**2))
return numpy.where(m <= 1,
0.158*(1./m) * exp(-(log(m)-log(0.08))**2/(2 * 0.69**2)), k*m**-2.3)
Note that here, log means $log_{10}$. Am I even on the right track?
