Lucid Dreaming

I have started to experiment with Lucid dreaming which is pretty cool. I keep a dream diary to write everything down, has anyone tried it ? As homo as it may sound I found a solution to a specific algorithm In a dreamy state.