JSFiddle - React, Tailwind, and code Playground
JavaScript
var v = {};
speed = 50;
alpha = 15; // theta
beta = 0;
v.x = speed * Math.sin (alpha) * Math.cos(beta);
v.y = speed * Math.sin (beta)
v.z = speed * Math.cos (alpha) * Math.cos(beta);
console.log(v);