create in python a specific F-curve
The Driver System

Can use the driver system for this.  An fcurve is a series of frame, value points. The value of an fcurve at any frame can be found via FCurve.evaluate(frame) A scripted expression driver evaluates its expression at each frame.  context.scene.current_frame is already known to the driver namespace as frame, as are a considerable number of math methods and properties including sin, cos and pi

Type simple expressions directly into the property preceded by a hash "#". 



Will show as purple if all is Ok.  Can edit at any time by clicking on the driver.