You're trying to calculate the Torque. Torque depends on the applied force F, the point of application, and the center of mass of the object.
1) Center of Mass. Define the center of mass of the object.
2) Point of Application: Define the point at which the force acts on.
3) Moment Arm: The distance between the two points defined above.
Point centerofMass
Point applicationPoint
Vector momentArm = applicationPoint - centerofMass
4) Angular force: Divide your force F into two orthogonal vectors, one Parallel to the line in 3) and one Perpendicular. The parallel component does not affect angular momentum. The perpendicular one does. You can calculate the parallel component by vector projection. You can subtract that from the original to get the perpendicular component. In pseudocode (dot
means dot-product)
Vector myForce
Vector momentArm
parallelComponent = momentArm * (dot(myForce, momentArm) / dot(momentArm, momentArm))
angularForce = myForce - parallelComponent
5) Torque: The perpendicular component of the force multiplied by the length of the moment arm.
Vector angularForce
Vector torque = angularForce * momentArm.Length
To get from Torque to angular velocity:
1) Moment of Inertia: A definition of how much rotational inertia a given object has. For example, it takes more torque to rotate a long bar than a sphere of the same mass. If you aren't concerned about realism, you can pretend the moment of inertia is relative to the mass, or you could ignore the shape and mass of the object entirely.
2) Angular acceleration:
Vector angularAcceleration = torque / momentOfInertia
3) Angular Velocity: The Angular velocity will keep increasing as long as torque is being applied. So a formula will roughly be "Angular Velocity at time T is the cumulative sum of Angular acceleration up until T." This is expressed in pseudocode as
void Update(float elapsedSeconds):
orientation += 0.5 * angularVelocity * elapsedSeconds;
angularVelocity += angularAcceleration * elapsedSeconds;
orientation += 0.5 * angularVelocity * elapsedSeconds;