# Coordinate transformations

Today I started to get involved to the coordinate transformation especially the Alpha–beta transformation and Dqo transformation:

According to the wikipedia: $$\frac{2}{3}\begin{bmatrix} 1 & -\frac{1}{2} & -\frac{1}{2} \\ 0 & -\frac{\sqrt{3}}{2} & \frac{\sqrt{3}}{2} \\ \frac{1}{2} & \frac{1}{2} & \frac{1}{2} \\ \end{bmatrix}$$ this is the Clarke transformation, according to my teacher the transformation matrix is the following: $$\begin{bmatrix} 1 & -\frac{1}{2} & -\frac{1}{2} \\ 0 & \frac{\sqrt{3}}{2} & -\frac{\sqrt{3}}{2} \\ \frac{1}{2} & \frac{1}{2} & \frac{1}{2} \\ \end{bmatrix}$$ Which one is right?

I had made some test in Matlab from three axis I made a transformation to two axis, after that I made a transformation from alpha-beta to dq. The result is: $$\begin{bmatrix}0.12 \\ 0.32 \\ 4\end{bmatrix}$$ Afterwards I used the Park transformation, but the two result not equal. The result is $$\begin{bmatrix}0.12 \\ -0.32 \\ 4\end{bmatrix}$$ Also the Matlab is using the Park's transformation instead of dqo transformation, according the Wikipedia the Park's transformation is not power invariant, also I noticed that Vd is repleaced with Vq, Isn't it?

## EDITED

Any three-phase sinusoidal set of quantities in the stator can be transformed to an orthogonal reference frame by $$\frac{2}{3}\begin{bmatrix} \cos(δ) & \cos(δ - \frac{2\pi}{3}) &\cos(δ - \frac{4\pi}{3}) \\ \sin(δ) & \sin(δ - \frac{2\pi}{3}) &\sin(δ - \frac{4\pi}{3}) \\ \frac{1}{2} & \frac{1}{2} & \frac{1}{2} \\ \end{bmatrix}$$ where δ is the angle of the orthogonal set a–b–0 with respect to any arbitrary reference. If the a–b–0 axes are stationary and the a axis is aligned with the stator a axis, then δ =0 at all times, Thus $$\frac{2}{3}\begin{bmatrix} 1 & -\frac{1}{2} & -\frac{1}{2} \\ 0 & \frac{\sqrt{3}}{2} & \frac{\sqrt{3}}{2} \\ \frac{1}{2} & \frac{1}{2} & \frac{1}{2} \\ \end{bmatrix}$$

According to my calculation this have to be $$\frac{2}{3}\begin{bmatrix} 1 & -\frac{1}{2} & -\frac{1}{2} \\ 0 & -\frac{\sqrt{3}}{2} & \frac{\sqrt{3}}{2} \\ \frac{1}{2} & \frac{1}{2} & \frac{1}{2} \\ \end{bmatrix}$$

because the $$\sin(-\frac{2\pi}{3}) = -\frac{\sqrt{3}}{2}$$

I found this example in the POWER ELECTRONICS HANDBOOK written by MUHAMMAD H. RASHID

Did I miss something on the math class?

-
On your "EDITED" comment, you are correct; there's a minus sign missing -- one of the second row elements is negative and the other is positive. Which one is negative/positive depends on the phase ordering, as I stated in my answer. –  Jason S Apr 12 '12 at 18:04
Thank you very much for your help. –  run Apr 12 '12 at 18:07

3->2 symmetric component transforms (a.k.a. "Clarke") are not unique -- in fact there are infinitely many, depending on how you define the axes and how you define the transform (whether it preserves power or magnitude, or whether it is an orthonormal matrix which preserves neither but has certain useful mathematical properties). What is important is that the matrix has orthogonal rows (the way you've shown it) and one row is along the "common-mode" axis with identical components.

I've always used

$$\begin{bmatrix} 2/3 & -\frac{1}{3} & -\frac{1}{3} \\ 0 & \frac{\sqrt{3}}{3} & -\frac{\sqrt{3}}{3} \\ \frac{1}{3} & \frac{1}{3} & \frac{1}{3} \\ \end{bmatrix}$$

myself, which matches the Wikipedia entry you mentioned.

The first row maps a vector ABC onto the two-phase component X, where if ABC is a 3-phase sine wave set with 0 mean, then X is equal to A in magnitude and phase. The second row maps ABC onto the two-phase component Y, where if ABC is a 3-phase sine-wave set with 0 mean, then Y is equal to A in magnitude but 90 degrees out of phase (and I can never remember whether it leads or lags so I have to derive that every time). The third row computes the common-mode voltage of the set.

(The verification test is this: Use $$ABC = \begin{matrix}[cos 0 & cos(2\pi/3) & cos(4\pi/3)]\end{matrix}^T$$ for θ = 0 and θ = π/2, multiply by the transformation matrix to get the X, Y, and common mode components, and make sure you get unit vectors in the X and Y directions.

If $$ABC = \begin{matrix}[cos 0 & cos(2\pi/3) & cos(4\pi/3)]\end{matrix}^T = \begin{matrix}[1 & -1/2 & -1/2]\end{matrix}^T$$ then multiplication by the transformation matrix should yield $$XYn = \begin{matrix}[1 & 0 & 0]\end{matrix}$$

and if $$ABC = \begin{matrix}[sin 0 & sin(2\pi/3) & sin(4\pi/3)]\end{matrix}^T = \begin{matrix}[0 & \sqrt 3/2 & -\sqrt 3/2]\end{matrix}^T$$

then multiplication by the transformation matrix should yield $$XYn = \begin{matrix}[0 & 1 & 0]\end{matrix}$$

which if you do the matrix multiplication, you should be able to verify this.

The rotation matrix that transforms from XY <-> DQ (a.k.a. "Park transform") is also not unique and depends on your axes reference. It should only rotate and preserve vector magnitude without any anisotropy, so it must be a 2x2 orthonormal matrix. In my systems, I use a transform matrix defined by X = Q when the rotation angle is 0 and Y = Q when the rotation angle is 90. The resulting matrix is a little bit different than the one cited in most motor control literatore.

The most egregious error, in my opinion, in using Park and Clarke transforms without citing a definition that you have verified is appropriate for your use. (And even worse is someone who implements a Park and Clark transform for someone else's use without defining it.) If you just use what's on Wikipedia or what's in a motor control software library, you may end up not understanding it, and creating signals that are incompatible with someone else's system unless you swap X and Y or D and Q, or negate one of the signals, or rotate it in the opposite direction.