generate testIndexMatrix