Can I use an accelerometer to measure the velocity of a car in a curve? I am making an application that is used to measure the velocity, it has an accelerometer that measures the component acceleration in the XYZ-axis. When the car is moving just straight the measurement is ok, as only linear components are involved.
My doubt came when the car is on a curve, I am not sure if the accelerometer can measure correctly in such situation or if it is necessary to apply a gyroscope to measure any missing component.
The code snippet for measure the total acceleration is shown below, I measure the acceleration in each axis and I remove the gravitational to finally calculate the velocity and the speed
    float AccTotal_X = ((AcX - grav_X)*9.81);
    float AccTotal_Y = ((AcY - grav_Y)*9.81);
    float AccTotal_Z = ((AcZ - grav_Z)*9.81);

    float Vx = vx_0 + AccTotal_X*dt;
    vx_0 = Vx;
    float Vy = vy_0 + AccTotal_Y*dt;
    vy_0 = Vy;
    float Vz = vz_0 + AccTotal_Z*dt;
    vz_0 = Vz;

    speed_dt = sqrt(pow(Vx,2)+pow(Vy,2)+pow(Vz,2))*3.6;
I found out the answer to the question in the following article SenSpeed: Sensing Driving Conditions to Estimate Vehicle Speed in Urban Environments
According to the article

When a vehicle makes a turn, it experiences a centripetal force, which
is related to its speed, angular speed and turning radius. Thus, by
utilizing the accelerometer and the gyroscope, we can derive the
tangential speed of a vehicle.

Therefore, just with the accelerometer is not possible to measure the velocity when an object is making a turn, it is necessary a gyroscope also.
The equation to measure the tangential velocity is:
v = Rω (1),
Where v is the tangential speed, R the radius of the curve and ω the angular speed.
As the centripetal acceleration is given by a = ω²R (2), reformulating (2) and substituting in (1), it is obtained:
v = a/ω (3).
Both a and ω are given by the accelerometer and the gyroscope respectively.