Announcements
- TBA
Getting in touch with your instructor...
- Email: I actually read and respond to emails. I check email frequently during the workday but limit my email time after work hours and on weekends. Please be patient, but if I don't reply by the end of the next working day then feel free to email me again – there's always a chance your first email got buried under urgent emails (or spam ...) and I appreciate the nudge!
- Office Hours: TBA
Just stop by! You don't need an appointment to drop by my office. If you want to meet over Zoom, you will need to make and keep an appointment, because I am uncomfortable sitting on Zoom with no one there. I am also available over Discord (username in the syllabus, behind the SUNY Oswego login...). Join the Math Club Discord server (link in syllabus) and send me a message! We can use the voice channels and the text channels to stay in contact. Just be aware that if you message me in Discord, I won't respond until I'm free to check my phone ... in person obligations come first. - Other times: If my office door is open then you are welcome to stop in and ask if I'm available. I may be! If I'm busy, we can make an appointment to meet up later on.
Useful Resources
- University of Toronto - Mississauga Primes Pages
- Handbook of Applied Cryptography by Menezes, van Oorschot, and Vanstone
- RFC 8017 - PKCS#1: RSA Cryptography Specifications Version 2.2
- a table of symbols and their commands in latex
LaTeX Fun
You can exchange the commands in the box below for your own and render it on demand. It's kind of fun! Press the Render! button when you're ready.
\({}\)
SageMath and Tiny SageMath Programs
SageMath is free open source mathematics software that can do some pretty amazing calculations, and the software has a ton of useful libraries and built-in functions. You can download and install Sage for use on your computer through a terminal window or Juypter notebook, or you can use Sage online through CoCalc or SageMathCell. The SageMath language is built on Python, so if you know a bit of Python then you can often logic your way around SageMath. I will often use SageMathCell in class for quick examples and calculations but I prefer to use SageMath in a Juypter notebook on my computer so you might see both during the class meetings.
For really quick things, here's a SageCell box that you can try out! Change the input area to be whatever code you need, press Evaluate, and ta da!
You may prefer a different language or different software and that's great! Go ahead and use whatever you wish that will complete the same operations. SageMath has a lot of built-in programs and functions that make the programming easier, but there's something to be said for figuring out how to get the same results yourself and for learning how to do the same computations in your preferred programming language.
A few good SageMath commands to know:
- mod(x,n) returns the remainder of \(x\) modulo \(n\)
- factor(n) factors \(n\) ... but this can time out if \(n\) is big and hard enough to factor
- inverse_mod(x,n) calculates the inverse of \(x\) modulo \(n\)
- power_mod(x,i,n) gives \(x^i\) modulo \(n\)
- euler_phi(n) produces \(\varphi(n)\), the Euler totient of \(n\)
- g=mod(primitive_root(p),p) instructs Sage to select a primitive root modulo \(p\) and call it \(g\)
- p= random_prime(a, True) will return a random prime between 2 and \(a\)
- CRT_list([a1,a2,...,ak],[m1,m2,...,mk]) will solve a system of linear congruences, \(\{x \equiv a_1 \textrm{ mod } m_i \mid 1 \leq i \leq k\}\), provided that the moduli are pairwise relatively prime
- Mod(x,p).nth_root(n,all=True) asks Sage to produce a list of all remainders modulo \(p\) that, when squared, produce \(x\)
- Mod(x,p).sqrt(all=True) asks for all square roots of \(x\) modulo \(p\)