• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 2 out of 21 pages
Summary

JADS Premaster - Data-structures and Algorithms Summary

Document preview thumbnail
Preview 2 out of 21 pages

Summary for the Data-structures and Algorithms course of the Premaster Data Science and Entrepreneurship.

Content preview

1. Mathematical Rules
Square Root Rules logc (ab ) = b · logc (a)
√a = a1÷b
b
logb (a) = logc (a) ÷ logc (b)
logc (1 ÷ a) = − logc (a)
Fraction Rules logc (c) = c
a b a+b
c + c = c logc (1) = 0
a
c − bc = a−bc
a b a·d c·b Summation Rules
c + d = c·d + c·d = a·d+c·b
c·d k
a b a·d c·b a·d−c·b ∑ f (i)
c − d = c·d − c·d = c·d is the sum of f (i) between j and k
i=j
a
c · bd = a·b
c·d 10 10
a
c ÷ d = ac · db = a·d
b
c·b
∑ 5i = 5 ∑ i2
2
common factor sum
i=1 i=1
n n
Exponent Rules ∑ 10 = 10 ∑ 1 = 10n constant sum
ca · cb = ca+b i=1 i=1
ac · bc = (a · b)c k l k

ca / cb = ca−b
∑ f (i) = ∑ f (i) + ∑ f (i) splitting sum
i=j i=j i=l+1
ac ÷ bc = (a ÷ b)c n n
(ca )b = ca·b ∑ (n − i) = ∑ i reverses sum
c−a = 1 ÷ ca i=0 i=0
n
c0 = 1 ∑i= n(n+1)
is arithmetic series O(n2 )
2
c1 = c i=1
0c = 0 n
q n+1 −1
∑ qi = q−1 is geometric series O(q n )
i=0
Logarithm Rules n n
logc (a · b) = logc (a) + logc (b) ∑ 1
i =∫ 1
x · dx is harmonic series O(log n)
logc (a ÷ b) = logc (a) − logc (b) i=1 1



2. Mathematical Proofs
Writing Proofs
● State the proof techniques used (i.e. loop invariant, induction, etc.)
● Keep a linear flow
● Describe every step clearly in words
● Don’t use complicated notation
● Make sure your assumptions are actually obvious
● Finish your proof



1

, Direct Proof
Proving a statement by using a sequence of manipulations (i.e. p ⇒ q )

Example:
If n is an odd integer then n2 is odd.

We assume that n is odd.
n = 2k + 1
n2 = (2k + 1)2 = (2k)2 + 2 · (2k) + 12 = 2 · (2k 2 + 2k) + 1

2
Thus n2 is odd, since it has the form 2k ′ + 1 with k ′ = (2k + 2k) .


Contraposition Proof
Proving a statement by using its inverse (i.e. p ⇒ q by not q ⇒ not p )

Example:
For integer n , if 3n + 2 is odd then n is odd.

We assume that if n is even, then 3n + 2 is even.
Solve with regular direct proof...

Contradiction Proof
Proving a statement by assuming it’s false (i.e. to prove q assume not q)

Example:
This statement is false by definition of the big-O notation. We will prove that this statement is false by
contradiction. There exists positive constants c and n0 such that 0 ≤ n2 log2 (n) ≤ cn2 for all n ≥ n0

0 ≤ log2 (n) ≤ c , we know that logarithmic functions grow faster than constants. Thus for any positive
value of c and n0 , there will exist such that n ≥ no with log2 (n) > c

We have reached a contradiction and the only conclusion can be that our assumption must be false.
Hence, the statement must be false.

Example Proof
Proving a statement by fulfilling a condition and giving a example (i.e. there is an integer x such
that x < 100 )

Example:
This statement is true by definition of the big-Θ notation. By definition n2 − 5n + 10 = Θ(n2 ) , if there exists
positive constants c1 , c2 and n0 such that 0 ≤ c1 n2 ≤ n2 − 5n + 10 ≤ c2 n2 for all n ≥ n0




2

Document information

Study
Uploaded on
October 10, 2021
Number of pages
21
Written in
2021/2022
Type
Summary
$6.69

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
tomdewildt
5.0
(1)
Sold
30
Followers
13
Items
22
Last sold
5 months ago



Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions