hom: added generate_ones(), small refactoring
hom: added generate_ones(), small refactoring

sfepy/sfepy,sfepy/sfepy,lokik/sfepy,BubuLK/sfepy,rc/sfepy,sfepy/sfepy,lokik/sfepy,RexFuzzle/sfepy,lokik/sfepy,rc/sfepy,lokik/sfepy,RexFuzzle/sfepy,RexFuzzle/sfepy,olivierverdier/sfepy,BubuLK/sfepy,RexFuzzle/sfepy,olivierverdier/sfepy,vlukes/sfepy,rc/sfepy,olivierverdier/sfepy,BubuLK/sfepy,vlukes/sfepy,vlukes/sfepy