if i have:

for even n,

An= 4[(-1)^(n/2)-1]/(π^2n^2)

and for odd n,

An= 2[πn(-1)^((n-1)/2)-2]/(π^2n^2)

can i use proper notation to write this all in one line?

Printable View

- May 19th 2011, 07:16 PMlinalg123notation.
if i have:

for even n,

An= 4[(-1)^(n/2)-1]/(π^2n^2)

and for odd n,

An= 2[πn(-1)^((n-1)/2)-2]/(π^2n^2)

can i use proper notation to write this all in one line? - May 20th 2011, 03:32 AMSudharaka
Dear linalg123,

This is a piecewise function. So you could write,

$\displaystyle A_n=\left\{\begin{array}{cc}\dfrac{4\left((-1)^{\frac{n}{2}}-1\right)}{\pi^{2n^2}}&\mbox{ if n is even}\\\dfrac{2\left(\pi n(-1)^{\frac{n-1}{2}}-2\right)}{\pi^{2n^2}} & \mbox{ if n is odd}\end{array}\right.$ - May 21st 2011, 01:43 AMHallsofIvy
If $\displaystyle A_n$ is equal to A for n odd and B for n even you can also write it as

$\displaystyle A\frac{1- (-1)^n}{2}+ B\frac{1+ (-1)^n}{2}$

Do you see why?