Need to figure out why the linear interpolation is being weird, maybe rewrite the cfc code again making careful use of poitners