Isolated and companion young brown dwarfs in the taurus and chamaeleon molecular clouds