How do you calculate angular velocity (rad/s) of an object based on it's speed?


i’m currently working on a car.
the car has 4 wheels, all of which should be spinning.

how can i calculate how much to rotate the wheels each frame just based on velocity?

i’ve tried to solve the problem by getting how far ive moved within the last frame and trying to get an angle based on that, although it isnt in rad/s and i still have no idea where to go.

any help is appreciated :slight_smile:

With a wheel the movement foward is based off the size of the wheel and the speed it turns at, if you know the size and foward movement you can calc the rotation speed

So speed / (Pie * Diameter) should = rotational speed

I still haven’t finished high school math so ye not the best when it comes to such matters. Regardless with my limited and questionable knowledge, maybe this would work:

local wheelRadius = 8 --// in studs
local vehicleSpeed = 20 --// in studs per second

local wheelCircumference = 2 * math.pi * wheelRadius

local rotationsPerSecond = vehicleSpeed / wheelCircumference