I am in the midst of learning 'Modular Exponentiation' and I have to now write the code to bring the two together, within a calculator program within my VB 2013.
However, as I am very new indeed to this but my studies rely on this module, I'm hoping some kind souls can give me some pointers / guidance.
I've created the easy part of the form design;
http://s2.postimg.org/ppyvvx9q1/mod_vb_design.jpg
Now I need to write a function to evaluate Modular Exponentiation using the below, however the hypothetical user must be able to choose ANY 'Power' figure, even if they were to choose a power number above for below example of 1-4.
NextPow = 1 Solution = 13 * 1 mod 53 = 13
NextPow = 2 Solution = 13 * 13 mod 53 = 10
NextPow = 3 Solution = 13 * 10 mod 53 = 24
NextPow = 4 Solution = 13 * 24 mod 53 = 47
I'm a little lost and hoping somebody can offer me some guidance, I've watched so many videos and researched that many sites r.e. modulo but I think I've just confused myself.
If there's any other aspect of the above that isn't explained correctly by myself in your mind, then please don't hesitate to let me know and I will try to re-clarify.