To insert a new equation in a Google Docs file, like e.g. the one in Attachment 4 click Insert -> Equation
You will now be able to see the tool bar with a button "New equation", as shown in the first attachment.
Click this button and you are able to type your equation. Once you need something like subscripted letter it gets a little more tricky. Now you have to choose the type of variable you need from the drop down "Math operations" as shown in attachment 2, but it won't just insert this variable you actually have to type the letter you want in normal size first, then use the right arrow key to let the cursor know that you would now like to type a subscripted letter and then use the arrow key again to be able to type normally again. Attachment 3 shows a rightly placed cursor.
The same applies, e.g. for divisions