1
$\begingroup$

I tried like this.

\begin{align}

y_{p} &= $\ \frac{1}{D^2+D} (8cos2x-4sinx)\\$

&= $\ \frac{1}{D^2+D} 8cos2x$ -$\ \frac{1}{D^2+D} 4sinx\\ $

&= $\ 8\frac{1}{-4+D}cos2x$ - $\ 4\frac{1}{-1+D}sinx \\$

&= $\ 8\frac{D+4}{D^2-16}cos2x$ - $\ 4\frac{D+1}{D^2-1}sinx\\$

& = $\ 8\frac{D+4}{-20}cos2x$ - $\ 4\frac{D+1}{-2}sinx\\$

& = $\ -\frac{2}{5}(D+4)cos2x$ + $\ 2(D+1)sinx\\$

& = $\ -\frac{2}{5}(-2sin2x+4cos2x)$ + $\ 2(cosx+sinx) \\$

& = $\ \frac{4}{5}(sin2x-2cos2x)$+$\ 2(sinx+cosx)\\$ \end{align}
Starting with 'dollar' before begin command and ending with 'dollar' after end command and ending each line with 'double blackslash'.

| |
$\endgroup$
  • $\begingroup$ You are using it wrong, even on a normal $\rm\LaTeX$ standard, this code is simply wrong. $\endgroup$ – Asaf Karagila Apr 15 at 19:40
  • $\begingroup$ math.meta.stackexchange.com/questions/5020/… $\endgroup$ – Asaf Karagila Apr 15 at 19:42
  • $\begingroup$ i watched it. but what were my mistakes? @AsafKaragila $\endgroup$ – Manjoy Das Apr 15 at 19:43
  • $\begingroup$ You don't need dollars on each line. The minus should be inside your equation, it is a math symbol after all. While we're at it, \cos and \sin are their own commands too. $\endgroup$ – Asaf Karagila Apr 15 at 19:45
  • $\begingroup$ if i don't write dollars sign in each line then how the fractions or sin, cos etc will work? @AsafKaragila $\endgroup$ – Manjoy Das Apr 15 at 19:48
  • 1
    $\begingroup$ I have edited your post on the main to get to this. I am not sure whether it is close to what you wanted to get. If you still have some questions, feel free to use the MathJax chatroom. $\endgroup$ – Martin Sleziak Apr 15 at 20:03
  • $\begingroup$ @MartinSleziak yes I wanted exactly this. but how did you find my post? :D $\endgroup$ – Manjoy Das Apr 15 at 20:04
  • 1
    $\begingroup$ From your profile on the main. It is among your recent answers. $\endgroup$ – Martin Sleziak Apr 15 at 20:05
  • $\begingroup$ can you please tell me what were my mistakes? @MartinSleziak Sometimes it becomes too complicated. $\endgroup$ – Manjoy Das Apr 15 at 20:07
  • 1
    $\begingroup$ I left some comments on that in chat. $\endgroup$ – Martin Sleziak Apr 15 at 20:12

You must log in to answer this question.

Browse other questions tagged .