Skip to main content
edited body; edited body; edited body
Source Link

From this post here I am struggling with the matrix multiplication to get from:

$\log \pi _{k} - \frac{1}{2}(x-\mu _k)^T{\sum }^{-1}(x-\mu _k)$

to

$\log \pi _{k} - \frac{1}{2}[X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k] + X^{T}{\sum }^{-1}\mu _k$$\log \pi _{k} - \frac{1}{2}[x^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k] + x^{T}{\sum }^{-1}\mu _k$

I get the first two tersm but I struggle with the last term because when I do the foil multiplication I get:

$- \frac{1}{2}[(X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k) - (X^{T}{\sum }^{-1}\mu _k + \mu _k^{T}{\sum }^{-1}x) ]$$- \frac{1}{2}[(x^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k) - (x^{T}{\sum }^{-1}\mu _k + \mu _k^{T}{\sum }^{-1}x) ]$

I don't see how the last two terms are the same? Why do we say: $-(X^{T}{\sum }^{-1}\mu _k$$-(x^{T}{\sum }^{-1}\mu _k$ + $\mu _k^{T}{\sum }^{-1}x)$ = $-2\cdot X^{T}{\sum }^{-1}\mu _k$$-2\cdot x^{T}{\sum }^{-1}\mu _k$

From this post here I am struggling with the matrix multiplication to get from:

$\log \pi _{k} - \frac{1}{2}(x-\mu _k)^T{\sum }^{-1}(x-\mu _k)$

to

$\log \pi _{k} - \frac{1}{2}[X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k] + X^{T}{\sum }^{-1}\mu _k$

I get the first two tersm but I struggle with the last term because when I do the foil multiplication I get:

$- \frac{1}{2}[(X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k) - (X^{T}{\sum }^{-1}\mu _k + \mu _k^{T}{\sum }^{-1}x) ]$

I don't see how the last two terms are the same? Why do we say: $-(X^{T}{\sum }^{-1}\mu _k$ + $\mu _k^{T}{\sum }^{-1}x)$ = $-2\cdot X^{T}{\sum }^{-1}\mu _k$

From this post here I am struggling with the matrix multiplication to get from:

$\log \pi _{k} - \frac{1}{2}(x-\mu _k)^T{\sum }^{-1}(x-\mu _k)$

to

$\log \pi _{k} - \frac{1}{2}[x^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k] + x^{T}{\sum }^{-1}\mu _k$

I get the first two tersm but I struggle with the last term because when I do the foil multiplication I get:

$- \frac{1}{2}[(x^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k) - (x^{T}{\sum }^{-1}\mu _k + \mu _k^{T}{\sum }^{-1}x) ]$

I don't see how the last two terms are the same? Why do we say: $-(x^{T}{\sum }^{-1}\mu _k$ + $\mu _k^{T}{\sum }^{-1}x)$ = $-2\cdot x^{T}{\sum }^{-1}\mu _k$

Source Link

Struggling on second to last part deriving linear discriminant function

From this post here I am struggling with the matrix multiplication to get from:

$\log \pi _{k} - \frac{1}{2}(x-\mu _k)^T{\sum }^{-1}(x-\mu _k)$

to

$\log \pi _{k} - \frac{1}{2}[X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k] + X^{T}{\sum }^{-1}\mu _k$

I get the first two tersm but I struggle with the last term because when I do the foil multiplication I get:

$- \frac{1}{2}[(X^{T}{\sum }^{-1}x +\mu _k^{T}{\sum }^{-1}\mu _k) - (X^{T}{\sum }^{-1}\mu _k + \mu _k^{T}{\sum }^{-1}x) ]$

I don't see how the last two terms are the same? Why do we say: $-(X^{T}{\sum }^{-1}\mu _k$ + $\mu _k^{T}{\sum }^{-1}x)$ = $-2\cdot X^{T}{\sum }^{-1}\mu _k$