Difference between た／ている／plain form + とき


I don't really understand the difference between た／ている／plain form + とき.




The only differences between these three are the tense of the verb. Attaching
〜時{とき} holds the same function in all three cases.

  1. 〜た：past tense 
    * 行ったとき。。。When (I) went...
    * 勉強したとき。。。When (I) studied...
  2. 〜ている： present progressive (continuous) tense 
    * 行っているとき、。。。When (I) am going...
    * 勉強しているとき。。。When (I) am studying...
  3. plain form： 
    * 行くとき、。。。When (I) go...
    * 勉強するとき。。。When (I) study...




TL;DR: In AときB, the tense of A determines the relative order to B. The tense
of B determines the tense of the entire sentence.

The full nuances of とき are actually pretty complicated. To native English
speakers, when A and B agree in tense, it's pretty simple, so I'll give
examples where the tenses are different.

If A is in the past tense, then B happens after A has already happened.

1) 日本に行ったとき、姫路城を見に行く。

You can't use 「行くとき」because you go to see Himeji castle AFTER going to Japan.

If A is in the present progressive tense, then B's happening is entirely
contained within the timeframe of A. In the previous example, you could have
used 行っているとき because that describes the state of having gone and _staying_ in
Japan rather than the action of going. A less counter-intuitive example:

2) ゲームをしているとき、友達が電話した。 My friend called me _while_ I was playing videogames.

Now here's the tricky part. When A is in the plain form (present tense), there
are two possibilities.

Possibility #1: If A is in the plain form (present tense), then B happens when
A is yet to happen. That is, B happens first.

3) 出かけるとき、ペットのケージにかぎをかけた。

In this example, you locked your pet's cage prior to going out. If you said
「出かけたとき」as you might be tempted to say, then this sentence would mean that you
locked your pet's cage AFTER leaving, which isn't humanly possible.

Possibility #2: B could also be concurrent with A. When the sentence in
question falls under this possibility, it's usually because A is an adjective
or noun. However, this can happen when A is a verbal phrase in the present as
well.

4) レポートを書くとき、鉛筆を使った。

This means you used a pencil as you wrote your report. In this example, you
are referring to a _specific_ time. Maybe you usually use pens instead of
pencils.

More intuitive examples of the concurrent case using nouns/adjectives:

5) 寂しいとき、泣きます。

6) 病気の時、父が病院に連れて行ってくれた。

