I have some problems with understanding what is the difference between these two grammatical forms. The explanation that 初級日本語 gives me, is that 間 refers to certain time frame, while 間に refers to certain time frame within that time frame. Is it correct or am I missing something?
It is very simple:
A 間 B
All the time that A took place B was also happening. (I read my book while it was raining)
A 間に B
While A took place B happend. The nuance to appreciate is that B is an event that occurred (started & finished) at some point during the period A took place. It did not go on all the time. (While it was raining the post was delivered.)
The nuance is very similar to the difference between まで and までに
A まで B
Until A happens, B will continue, constantly (I was watching television until father came home)
A までに B
By the time A happens B will have occurred (started and finished, during the period defined by A まで; it could happend at any point but did not happen constantly. (I will finish my work by 5 o'clock. ie at some unspecified point during the period to 5'oclock)
I've summarise the following from a Dictionary of Basic Grammar which seems a little different to what you state. Note that I'm not a native speaker.
The time span of the 間 clause and the main clause is the same, while the time span of a 間に clause is wider than the time span of the main clause. For example: 山田さんがぺりに留学している間にお母さんが病気になった。 The period in which she become ill is a portion of the time when Yamda was studying in Paris. If 間に is replace by 間 then the sentence is ungrammatical according to the Dictionary of Basic Grammar.