Ordinary Differential Equations

Ordinary Differential Equations
A differential equation is an equation with $\frac{d^n}{dx^n}$ terms. Let's start with a simple equation with two variables $x$ and $y$.

$y = ae^x + be^{3x}$

If we differentiate this in $x$, a first order differential equation comes as

$\frac{dy}{dx} = ae^x + 3be^{3x}$

If we differentiate it once more in terms of $x$, a second order differential equation is produced as

$\frac{d^2y}{dx^2} = ae^x + 9be^{3x}$

By solving there three equations, we can get an equation without those constant terms $a$ and $b$ and that is called an ordinary differential equation.

Using Pololu - QTR-8RC Reflectance Sensor Array

Pololu - QTR-8RC Reflectance Sensor Array
In line following a sensor array is an essential part in the robot. I have used the QTR-8RC array and it works like a charm. With Arduino libraries it is easy to configure them but with PIC micro-controllers you have to handle the hardware configuration part manually.

Big O Notation

What is Big O???
Big O notation is a technique used to describe the complexity of an algorithm. It is very useful when evaluating performance wise of different algorithms doing the same task. In this post, I'm not going deep into the programming side but let's take a code snippet as an example.

In this code, we are trying to add up all the natural numbers up to 100. There are two algorithms doing the same job but they perform differently.
#***********************## Method 1n=100sum=0foriinrange(0,n+1):sum=sum+int(i)printsum#***********************## Method 2printstr(n*(n+1)/2)#***********************#

Taylor Series

What is Taylor Series???
Taylor Series in simple terms, is a way of finding the value of a function at any point. To calculate and formulate the answer, all we need is the function value at a single point and the values of all its derivatives at that point. The general expression for Taylor Series is expressed as follows.
$$f(x) = \sum_{k = 0}^{\infty}\frac{1}{k!}(x - a)^kf^k(a)$$ Note that we need to know what the function values are at $f(a)$, $f'(a)$, $f''(a)$, ...

Programming Assignment 2

Python Programming Assignments
This is the second set of python assignments I found.

Real Analysis Proofs

1 ♦ 0 = 0.a
0.a = 0.a

0.a = (0 + 0).a [Since 0 is the additive identity]
0.a = 0.a + 0.a [Distributive Axiom]

-0.a + 0.a = -0.a + 0.a + 0.a [Adding (-0.a) to both sides, the additive inverse of 0.a]
0 = (-0.a + 0.a) + 0.a [Associative Axiom]

0 = 0 + 0.a

0 = 0.a [Since 0 is the additive identity] ♠

2 ♦ -a = -1(a)
(-a) = (-a)

(-a) = (-a) + 0 [Additive Identity]

(-a) = (-a) + 0.a [Since 0 = 0.a (By above theorem (1))]
(-a) = (-a) + (1 + (-1))a [Additive Inverse of 1]

(-a) = (-a) + (1.a + (-1)a) [Distributive Axiom]
(-a) = (-a) + (a + (-1)a) [Multiplicative Identity]
(-a) = ((-a) + a) + (-1)a [Associative Axiom]
(-a) = 0 + (-1)a [Additive Identity]

(-a) = (-1)a [Additive Identity] ♠

3 ♦ -(a + b) = (-a) + (-b)
-(a + b) = -(a + b)

–(a + b) = (-1)(a + b) [By above theorem (2)]
(-1)(a + b) = (-1)(a) + (-1)(b) [Distributive Axiom]

-(a + b) = (-a) + (-b) [By above theorem (2)]

♦ Sup(A + B) = Sup(A) + Sup(B)
∀ a ∈ A and ∀ b ∈ B;
a ≤ Sup(A) and b ≤ Sup(B)

∴ a + b ≤ Sup(A) + S…

Python Laboratory Excersices

L1_2.2 Python Programs
Step 1: Type the Python program using a text editor such as gedit or vi or emacs or Kwrite and save as ($ gedit
Step 3: Modify the above program to display the source code.

# Step 1# ******** ## display Hello Worldprint"Hello world !\n"# Step 3# ******** #print"# display Hello World\n"print"print \"Hello world !\\n\"\n"