I'm going to quickly gloss over a few equations for reference since it's been a while since I've had to do any major physics calculations.
Displacement, velocity, acceleration, mass and force in the time domain
d = v * t
v = a * t
F = m * a
Displacement, velocity, and acceleration using delta time by applying Newton's Method
d[n] = d[n-1] + v[n] * dt
v[n] = v[n-1] + a * dt
a = F / m
Some terms:
I = Inertia
H = Momentum
r = radius
theta(θ) = angular position, or rotation
omega(ω) = angular velocity
alpha(α) = angular acceleration
Tau(τ) = torque
v = ω * r
θ = ω * t
ω = α * t
τ = r' cross F'
H = I * ω
H = m * v'
H = r' cross (m*v')
In order to do a cross product in 2D you have to use a complex number. [ i x y ], so you will use [ i 0 0 ] = [ 0 x y ] cross [ 0 x y ]. i is considered an imaginary number since it doesn't exist on the 2D plane.
Offline
Nice. Great summary of all the equations involved.
Offline
Hey Canthiar, how old are you?
And anyways, nice equations. I haven't learned cross product so I kinda lost you at the end, but I almost learned everything leading up to it.
Offline
The cross product is a mathematical operation with the identity
a' cross b' = |a'|*|b'| * sin θ
where θ is the angle between the two vectors a' and b'.
The calculation is derived from the calculation of a matrix determinant. Where the determinant generates a scalar, the cross product generates a scalar.
If you have a 2x2 matrix
| a b |
| c d |
the determinant is calculated as
det = a*d - b*c
If you have a 3x3 matrix you actually do small determinant calculations on 2x2 matrices in the 3x3 matrix and multiply them by the first row and alternate the sign and add the results together.
| a b c |
| d e f |
| g h i |
the determinant is calculated as
det = a * (e*i - f*h) - b * (d*i - f*g) + c * (d*h - e*g)
To do a cross product you put your 1x3 vectors into a 3x3 matrix like this
| i j k |
| a.x a.y a.z |
| b.x b.y b.z |
where a' and b' are known vectors and i, j, and k are the unknown values in the cross product. Then do the determinant calculation.
The cross product will be:
i = a.y*b.z - a.z*b.y
j = a.z*b.x - a.x*b.z
k = a.x*b.y - a.y*b.x
This is all from memory so there may be some subtle detail in the description that I may have wrong, but the final equation for the cross product should be correct.
Note:
I'm still working on a Scratch project that incorporates the physics functions that I posted previously.
Offline
So basically the cross product of
| i j k |
| a.x a.y a.z |
| b.x b.y b.z |
finds the vectors in a matrix by using method similar to LaPlace expansion to determine which determinant each vector is equal to? (Although it really has nothing to do with LaPlace expansion.)
Oh, and now your other post makes sense because you have 3 1x3 matrices.
Offline
Canthiar wrote:
thecooltodd, I'm 33.
Oh cool. How old are most of the people on Scratch? I always assumed them to be more around my age (high school) that's why.
Offline