Check out example codes for "write file series of steps matlab". It will help you in understanding the concepts better.

Code Example 1

save(['solution_number',num2str(n),'.mat'],'myVariable');

Learn ReactJs, React Native from akashmittal.com