Processing math: 100%

05 May 2012

Conventions


The first post will probably be a bit boring but this is a step we need to go through in order to understand each other later.
Here, we just want to list all (or at least most) of the conventions we are going to use in our blog.

Greek letters

Greek letters are used as constants or angles. For example π is the constant 3.14159....

Functions 

Functions are identified by Latin letters like f or g and the variable is always seen in the definition. For example f(x) is a function depending on x.
If we want to describe a recursive function we put an index below the function name.
gi(x)=gi1(x)+2x2

Vectors and Matrix

Vectors are identified by bold Latin letters with a bar above them and Matrix are just bold capital letters
Aˉx=ˉy
To indicate a component of a vector we put an index below the vector name and we do not put the bar above
ˉv=(v1,v2)

Sets

Sets are identified by big Latin letters A or B. A definition of a set is done using { and } for example:
A={a,e,o,i,u},B={a,b,c,d,e},C={a,c,e},D={a,e},E={a,b,c,d,e,o,i,u}
Element membership is expressed as  aA and not membership bA
The usual operation are defined between sets
  • Equal and not equal

  •           AA,AB
  • Inclusion or and its negation or .
          CB,BC,CA,AB

  • Intersection and union
          ABD,ABE

    Binary Operators (Bit-wise operators)

    • LEFT SHIFT
    • RIGHT SHIFT
    • AND &
    • OR  |
    • XOR
    • MOD %

    Other Symbols

    is used to indicate a repeated sum over indexes. For example
    ni=0gi
    is the sum of all g with index between 0 and n.
    The same is for the symbol where  the product is used instead of the sum,
    a is to indicate the upper value of a and a the lower value.
    log is always the log2 of a number.
    means almost equals to.
    is a derivative and is an integral

    Order of growth

    We indicate the order of growth with a big O and the parameter in the brackets. For example
    O(n)
    is the sign of a linear growth.
    The order of growth is an indication of the efficiency of the algorithm. If an algorithm is O(n) is called linear and it completes in a number of operation proportional to the size of the problem n. If we have an algorithm that is O(n2) it will complete in a number of operation proportional to the squared of the size of the problem.

    "Pseudo" code

    There won't be any "Pseudo code" we will use C/C++ code. We think that C/C++ can be clear enough for our purpose.








    No comments:

    Post a Comment