Category Archives: Mathematics

Little bit of logics and derivations

Biorhytm worksheet

We all feel high and low with time.Sometimes we are fastest, strongest and healthy. And at other time we are in opposite mood. This is biorhythm. I am not follower of Bio-rhythm league. But due to obvious intrest in new things I gave a try for it. The equations used to calculate is given in Wikipedia.

Physical: sin(2πt / 23),
Emotional: sin(2πt / 28),
Intellectual: sin(2πt / 33),
Intuitive: sin(2πt / 38),

where t indicates the number of days since birth.

These set of equations were not useful to me because it didn’t predicted my rhythm. Probably anyone interested in these study will find my Excel sheet useful. The sheet can calculate your rhythm on particular day or compare the rhythm of two persons. Hope it will work for someone 😉

Monte Carlos Simulation to find value of PI

I was going through a book named “Fooled by Randomness” by Nassim Nicholas Taleb. On one of the chapter, the writer claimed that according to Monte Carlo theory, if some bullets are fired inside the square, and a circle is drawn inside this square, the ratio of bullets inside the circle to the total number of bullets is equal to some ratio of PI. Now the question arouse in my mind what is the value of this ratio. Hence i prepared an excel sheet to know this value.

I tried with about 17150 bullets (the points), the point are generated randomly within the boundary of the square. A circle was drawn inside this square. Then to check if the points lie inside the circle distance formula was used. Finally the total number of bullets inside the circle and total number of bullets were counted and the ratio was calculated.

Try changing the size of square and radius of circle and check how the ratio changes. I found that when the circle is inscribed inside the ratio comes out to be about PI/4.

monte carlo pi sumulation.xlsx

Centroid of trapezoidal

The centroid of the trapezoidal with its one face perpendicular is given be

X=-1/3 (-2b^2-2ab+a^2)/(a+b)

Y=1/3 h (b+2a)/(a+b)

Where a, b, h and origin is as shown in the figure below.

Similarly, the centroid of any trapezoidal is given by

x= 1/3(3ab+3bc+b^2+6ac+3a^2+2c^2)/(b+2a+c)

y=1/3 h (b+3a+c)/(b+2a+c)

Where a, b ,c, h and origin is as shown in the figure below.

The result was obtained using MathLab 7.0

Derivation of Combined Angle

Abstract: Derivation of combined angle may become useful when you want to know the magnitude and direction of force due to bend in both XY and XZ plane. For eg in design of bend in pipeline.

Let us consider a straight line which deflects at O along OA as shown in the figure. The deflection angles are also shown in the figure.

Let R be the position vector of A. OB is projection of OA on XY plane and AB is projection of OA on a plane parallel to YZ plane. Similarly, OC is projection of line OB in X axis and BC is projection of OB on axis parallel to Y axis.

From figure it can inferred that

OB=R cosα

AB=R sinα

OC=OB cosβ = R cosα cosβ

BC= OB sinβ =R cosα sinβ

Therefore, the position vector of A is OA which is given by

R=|R| (cosα cosβ i + cosα sinβ j + sinα k )

And the unit vector along R is given by

r= (cosα cosβ i + cosα sinβ j + sinα k )

Now the combined deflection angle is given by

r . i =|r| |i| cosδ

Or, r . i =1*1 cosδ

Or, cosδ = cosα cosβ+0+0

Or, δ =cos-1(cosα cosβ)

The angle δ lies in the plane OAC. This plane is shown in the figure in hatch line.


If F be the magnitude of force due to the deflection δ (e.g. deflection in pipeline) then the vertical and horizontal component of this force is given by,

Fx1 =F r . i =F cosα cosβ

Fx2 =F r . j =F cosα sinβ

Fx =F

=F cosα

Fy =F r . j

=F sinα