I am in the process of writing a fairly long monograph on a computer science topic. However, I usually find myself in a position of having to write some computer science concept in mathematical terms, and it is difficult to me. For instance, say I want to write a for-loop or a void function. I do most of the time go to my Knuth or Cormen or Sedgewick, but they are not enough now. Is there a "manual" or some text I can take as example to translate computer science into mathematics?
Let me be more specific (thanks, Uri). What I mean is: For example, I have a function that is void, and it returns a random string of length n. This caused my curiosity, I don't even know how to represent void function in in math... but again, this is just an example.
Math matters for computer science because it teaches students how to use abstract language, work with algorithms, self-analyze their computational thinking, and accurately modeling real-world solutions.
Discrete mathematics, linear algebra, number theory, and graph theory are the math courses most relevant to the computer science profession. Different corners of the profession, from machine learning to software engineering, use these types of mathematics.
It focuses on graphs and equations and the ability to solve equations for unknown variables. Algebra is used in computer programming to develop algorithms and software for working with math functions. It is also involved in design programs for numerical programs.
Summation or product notation can probably replace some for-loops. Others can probably be expressed as logical quantifiers ("There exists i such that a[i] has some property" or "a[i] has some property for all i"). (Sorry I don't know how to render these in Markdown...hope you get the idea.)
"Void functions"...hmmm, maybe some convenient logical notation to state preconditions and postconditions, since such functions are only useful for their side effects?
But I think most mathematicians will be familiar enough with descriptions of algorithms to understand any halfway reasonable pseudocode convention. Just try to stay away from anything that requires a "language-lawyer" skill level in some particular programming language.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With