xml matrix saver