Wednesday, June 14, 2017

Unizor - Ordinary Differential Equations - Major Types





Notes to a video lecture on http://www.unizor.com

Ordinary Differential Equations
Major Types of Equations


In this lecture we will only consider first order ordinary differential equations for a function of one argument y(x) (no higher order derivatives). The general form of these equations is
F(x, y, dy/dx) = 0

We will consider three major types of these differential equations with known approaches to integration:
separable equations,
homogeneous equations,
linear non-homogeneous equations.

Separable Ordinary Differential Equations

A few examples we were working with in the introductory lecture to ordinary differential equations are separable in a sense that the original differential equation, that can be generally expressed as F(x, y, dy/dx) = 0, can be transformed into
f(y)·dy = g(x)·dx
that can be separately integrated, using the techniques of calculating indefinite integrals, and, hopefully, resolved for y.
Even if it will not be possible to resolve it for y, the result of integration will be a simpler formula G(x,y)=0 (it will also include a constant as a result of integration, which can be found if some initial condition on a function y(x) is imposed).
In any case, whether the result of integration can or cannot be resolved for y, it's still a significantly better than original equation that includes a derivative.

Example

y' + x·y = 0
Let's use the Leibniz notation for derivatives to facilitate the separation of function from its argument and resolve the equation for a derivative.
dy/dx = −x·y
Separate x and y:
dy/y = −x·dx
Now we can apply an indefinite integral to both sides to solve the equation.

Homogeneous Ordinary Differential Equations

Homogeneous equations can be defined using the following criterion.
Replace all occurrences of x with λ·x and all occurrences of y with λ·y. Do not change anything with derivative dy/dx. If, as a result, all λ's cancel each other out, the equation is homogeneous.
For example, consider the following equation:
y' + x/y + x²/y² = 0
Substitute x with λ·x and y with λ·y:
y' + (λ·x)/(λ·y) + (λ·x)²/(λ·y)² = 0
Obviously, we can reduce both ratios, getting exactly the same equation as before.
Now we will use the above example to explain the method of solving homogeneous equations.
Let's introduce a new function z(x)=y(x)/x, which results in y(x)=z(x)·x and express the initial equation in terms of xz and z'.
The expression for a derivative y' is:
y' = (z·x)' = z'·x+z
So, our equation looks like
z'·x + z + x/(z·x) + x²/(z·x)² = 0
Simplifying by reducing the ratios by x and , we get
z'·x + z + 1/z + 1/z²= 0
This equation can be solved using the method of separation.
z'·x = −(z + 1/z + 1/z²)
dz/(z+1/z+1/z²) = −dx/x
Now we can apply an indefinite integral to both sides to solve the equation for z(x) and then multiply it by x to get y(x).

Linear Non-Homogeneous Ordinary Differential Equations

Standard form of this type of differential equations is
f(x)·y' + g(x)·y + h(x) = 0
As the first step, we can divide all members of this equation by f(x) (assuming it's not identically equal to 0), getting a simpler equation
y'+u(x)·y+v(x) = 0
The suggested solution lies in the substitution y(x)=p(x)·q(x), where p(x) and q(x) are unknown (for now) functions.
Express y'(x) in terms of p(x) and q(x):
y' = p·q'+q·p'
Substitute this into our equation:
p·q'+q·p'+u·p·q+v = 0
Let's simplify this
p(q'+u·q)+q·p'+v = 0
If there are such functions p(x) and q(x) that satisfy conditions
(1) q'+u·q = 0 and
(2) q·p'+v = 0
our job would be finished.
Let's try to find such functions.
From the equation (1) in our pair of equations we derive
q'/q = −u,
which can be converted into
dq(x)/q(x) = −u(x)·dx
that can be solved by integrating:
ln(q(x)) = −u(x)·dx
q(x) = e−∫u(x)·dx
Once q(x) is found, we solve the equation (2) for p(x):
p'(x) = −v(x)/q(x),
which can be integrated to find
p(x) = −v(x)/g(x) dx
and, consequently, y(x)=p(x)·q(x) can be fully determined.
Let's consider an example.
y' + x·y + x² = 0
If y(x)=p(x)·q(x), our equation looks like this:
p'·q+p·q'+x·p·q+x² = 0
(q'+x·q)·p+(q·p'+x²) = 0
Now we have to solve the following equation to nullify the first term:
q'+x·q = 0
(which is solvable through separation)
and substitute the resulting function q(x) into
q·p'+x² = 0
to solve it for p(x)
(which is a simple integration).

Tuesday, June 13, 2017

Unizor - Ordinary Differential Equations - Introduction





Notes to a video lecture on http://www.unizor.com

Ordinary Differential Equations
Introduction


Ordinary differential equations are equations, where derivatives of some function participate in the equation.
Assuming that y(x) is some unknown function, a differential equation, in its general form, looks like this:
F(x, y, y', y'',...) = 0
where F(...) is some function of many arguments.
The goal is to find the function y(x) that satisfies this equation.

Let's start with a simple example of an ordinary differential equation.
y'(x) = 2x
We can easily guess that, if a derivative of a function equals to 2x, the function must be y(x)=x²+C, where C - any constant.

On the other hand, we can represent this equation in the form
dy/dx = 2x
and transform it into
dy = 2x·dx
This is a relationship between two infinitesimals that signifies that these infinitesimals are equal in a sense that the difference between them is an infinitesimal of a higher order than themselves.
Now we can apply an operation of integration to both getting the following
 1·dy =  2x·dx

Integration results in the following equality
y + C1 = x² + C2,
where C1 and C2 are any constants, and therefore, can be combined into one, getting
y = x² + C
This method of integration is a little more "scientific" than straight guessing that we employed above, though, by itself, might be difficult since it involves the operation of integration.

Notice the presence of any constant in the result. This is typical for differential equations and is similar to indefinite integrals.

Arguably, the method of separation of argument x and function y into different sides of an equation with subsequent integration is the most effective way to solve differential equations. Those equations that allow solution of this type are called separable differential equations

Let's consider a few more examples.

Example 1

x²·y'(x) = y(x)
Let's represent y'(x) as a ratio of differentials dy/dx, our equation will look like
x²·dy/dx = y(x)
Now we can separate argument x and function y into different sides of an equation
dy/y = dx/x²
Integrate both sides
dy/y = dx/x²
which results in
ln(y) = −1/x + C
(where C is any constant) or, since we have to find an expression for y in terms of x, we can use this equality as exponents and raise e into it, getting
y = C·e−1/x

Let's check this result.
y'(x) = C·e−1/x·(1/x²)
x²·y'(x) = C·e−1/x = y(x)
All is correct.

Example 2

tan(x)·y'(x) = y²(x)
Let's represent y'(x) as a ratio of differentials dy/dx, our equation will look like
tan(x)·dy/dx = y²(x)
Now we can separate argument x and function y into different sides of an equation
dy/y² = dx/tan(x)
Integrate both sides
dy/y² = dx/tan(x)
which results in
−1/y + C = cos(x)dx/sin(x)
or, equivalently, since
cos(x)·dx = dsin(x),
it can be transformed into
−1/y + C = dsin(x)/sin(x)
The integral on the right can be calculated and the result is
−1/y + C = ln(sin(x))
(where C is any constant) or, since we have to find an expression for y in terms of x, we can transform it into
y = −1/[ln(sin(x))+C]
It would look better if we bring the constant under a logarithm, getting
y = −1/ln(C·sin(x))

Let's check this result.
y'(x) = [1/ln²(C·sin(x))] · [1/(C·sin(x))] · C·cos(x) = cot(x)/ln²(C·sin(x))
tan(x)·y'(x) = 1/ln²(C·sin(x)) = y²(x)
All is correct.

As you see, in all examples above there is a constant that can take any value, as in the case of indefinite integrals. That's because we explicitly use integration as a tool to solve our differential equation. That's why the term "solving" as related to differential equations sometimes is replaced with term "integrate". So, to integrate a differential equation means to solve it.

Without any additional information, as we see, a differential equation can have infinite number of solutions. But we need only one, that corresponds to some practical problem, from which this equation was obtained. Therefore, we need some condition imposed on our solution to determine this constant that is present in the general solution.

Consider Example 1 above
x²·y'(x) = y(x)
and its solution
y = C·e−1/x
This solution represents a whole family of functions, each satisfying our differential equation.
To determine a particular solution we are interested in, we have to define what we are interested in using some additional information about function y(x). For example, we know that our function y(x) equals to 1 if x=1.
Let's substitute this into a general solution to our differential equation to find the value of constant C needed to satisfy our condition.
y(1) = C·e−1/1 = 1
from which we can find constant C:
C·e-1 = 1
C/e = 1
C=e
Therefore, particular solution we are looking for is
y = e·e−1/x = e1-(1/x)

In the Example 2 let's determine constant C by a condition y(π/2)=1
That results in the following
y(π/2) = −1/ln(C·sin(π/2)) = 1
ln(C) = −1
C = 1/e
So, our particular solution is
y = −1/ln(sin(x)/e)

Friday, June 9, 2017

Unizor - Partial Derivatives - Stationary Points





Notes to a video lecture on http://www.unizor.com

Partial Derivatives Properties - Stationary Points

We will mostly be concerned with partial derivatives of functions with two arguments.
The theory can be extended to functions of any number of arguments, but it's outside of the scope of this course.
Besides, functions of two arguments can be visualized as surfaces in three-dimensional space to better understand their properties.

Stationary points are those, where both partial derivatives of function f(x,y) of two arguments are equal to zero.

Let
g(x,y)=∂f(x,y)/∂x
h(x,y)=∂f(x,y)/∂y

Definition:
Point (a,b) is a stationary point for function f(x,y) if g(a,b)=0 and h(a,b)=0.

Theorem
A smooth function f(x,y) of two variables that has a local maximum at point (a,b) has both of its partial derivatives at this point equal to zero.

Proof

Let's prove that f(x,y)/∂x=0 for x=a and y=b. The proof for other partial derivative f(x,y)/∂y is analogous.
So, we fix variable y=b and calculate the partial derivative of f(x,y) by x at point x=a as follows:
f(x,y)/∂x = {at x=a,y=b} = lim[f(a+Δx,b)−f(a,b)]/Δx
(the limit is taken as Δx→0)
Since point (a,b) is a local maximum, the numerator [f(a+Δx,b)−f(a,b)] is negative, while the denominator Δx=(x+Δx)−x is non-positive for x+Δx ≤ x and non-negative for x+Δx ≥ x.
For a sufficiently smooth function (at least, we need the continuity of partial derivatives) this implies that the limit above must be equal to zero.

So, we have proven that for a smooth function of two variables the necessary condition for having a local maximum at point (a,b) is the equality of its partial derivatives to zero at this point.

The situation with local minimum is analogous and the equality of partial derivatives to zero at some point is a necessary condition for having a local minimum at this point.


IMPORTANT NOTE
The equality of partial derivatives to zero at some point is only a necessary condition for a function to have a local maximum or minimum at that point. It's not a sufficient condition.
This is similar to a situation with functions of one variable, when a derivative can be zero at some point, but a function can have an inflection point like function y=x³ at point x=0.
For a function of two variables a situation like this might occur when it has a saddle point.
Here is an example:

At the point in the middle of this "saddle" both partial derivatives are equal to zero, but this point is not a local minimum or maximum of a function.

Obviously, we would like to differentiate cases of a stationary point being a local maximum, a local minimum or a saddle point similarly to a situation with functions of one argument, where the second derivative sign (positive or negative) indicated whether a stationary point is minimum, maximum or inflection point.

Here is the rule, which we provide without rigorous proof.
Let's assume that function f(x,y) can be partially differentiated twice (that is, f(x,y)/∂xf(x,y)/∂y∂²f(x,y)/∂x²∂²f(x,y)/∂y²∂²f(x,y)/∂xy exist) and all second partial derivatives are continuous.
Let's further assume that at point (a,b) both first partial derivatives equal to zero:
f(x,y)/∂x = 0 at x=a, y=b
f(x,y)/∂y = 0 at x=a, y=b
Consider the expression
Δ = ∂²f(x,y)/∂x² · ∂²f(x,y)/∂y² − [∂²f(x,y)/∂xy
at point x=a, y=b.
The rule is:
if Δ < 0(a,b) is a saddle point;
if Δ > 0(a,b) is a local minimum or local maximum point and the sign of ∂²f(x,y)/∂x² or ∂²f(x,y)/∂y² can be used to distinguish minimum from maximum (positive for minimum, negative for maximum and these two second derivatives must have the same sign since otherwise Δ would be negative).
All other cases are not sufficient to determine the behavior of the function at this point.

Example 1

f(x,y)=1/(1+x²+y²)

f(x,y)/∂x = −2x/(1+x²+y²)²
f(x,y)/∂y = −2y/(1+x²+y²)²
At point (0,0) both partial derivatives are equal to zero, therefore (0,0) is a stationary point.
Examine the second derivatives.
∂²f(x,y)/∂x² = (6x²−2y²−2)/(1+x²+y²)³
∂²f(x,y)/∂y² = (6y²−2x²−2)/(1+x²+y²)³
∂²f(x,y)/∂xy = 8x·y/(1+x²+y²)³
At point x=0, y=0 the three expressions above can be used to calculate
Δ = (−2)·(−2)−0² = 4
Since Δ is positive, we have a local minimum or maximum at point (0,0). To distinguish between them, look at the sign of the second partial derivative by x. It is negative. Therefore, we have a local maximum as is obvious from the graph above.

Example 2

f(x,y)=x·y

f(x,y)/∂x = y
f(x,y)/∂y = x
At point (0,0) both partial derivatives are equal to zero, therefore (0,0) is a stationary point.
Examine the second derivatives.
∂²f(x,y)/∂x² = 0
∂²f(x,y)/∂y² = 0
∂²f(x,y)/∂xy = 1
At point x=0, y=0 the three expressions above can be used to calculate
Δ = 0·0−1² = −1
Since Δ is negative, we have a local saddle point (0,0), as is obvious from the graph above.

Thursday, June 8, 2017

Unizor - Partial Derivatives - Basic Properties





Notes to a video lecture on http://www.unizor.com

Partial Derivatives -
Basic Properties


We will mostly be concerned with partial derivatives of functions of two variable arguments.
The theory can be extended to functions of any number of arguments, but it's outside of the scope of this course.
Besides, functions of two arguments can be visualized as surfaces in three-dimensional space to better understand their properties.

Certain simple properties of partial derivatives of multivariable functions coincide with corresponding properties of derivatives of functions of one variable because the process of partial differentiation is, actually, a differentiation by one variable, keeping the others as constants.

So, we will not bother with proofs since they are based on corresponding properties of derivatives of functions of a single variable.
Also, whatever property is listed below for one argument of partial differentiation of multivariable function is valid for any other argument.

1. [f(x,y)+g(x,y)]/∂x = f(x,y)/∂x + f(x,y)/∂x

Example 1
[ln(x²+y²)+x·y]/x = 2x/(x²+y²)+y

2. [K·f(x,y)]/∂x = K·f(x,y)/∂x

Example 2
[2·ln(x²+y²)]/x = 2·2x/(x²+y²) = 4x/(x²+y²)

3. [f(x,y)·g(x,y)]/∂x = g(x,y)·∂f(x,y)/∂x + f(x,y)·∂g(x,y)/∂x

Example 3
[(x−y)·(x²+xy+y²)]/x = (x−y)·(2x+y)+1·(x²+xy+y²) = 3x²
At the same time,
(x−y)·(x²+xy+y²) = x³−y³ and a partial derivative by x of this expression equals to 3x², which corresponds to a previous result.

4. f(x(t),y)/∂t = f(x,y)/∂x · dx(t)/dt

Example 4
[ln²(t)+y²]/t = 2ln(t)/t

Let's consider properties specific for multivariable functions.
Recall that for a function of a single variable f(x) the following approximation can be established:
Δf(x) = f(x+Δx) − f(x) ≅ (df(x)/dx)·Δx
As Δx→0, this approximation is transformed into a relationship between infinitesimals:
df(x) = (df(x)/dx)·dx

Similarly, we can establish a relationship in case of multivariable functions for each of its arguments:
f(x+Δx,y) − f(x,y) ≅ (∂f(x,y)/x)·Δx
and
f(x,y+Δy) − f(x,y) ≅ (∂f(x,y)/y)·Δy

Using the above properties, let's consider a general case when both arguments of function f(x,y) are incremented.
f(x+Δx,y+Δy) − f(x,y) =
f(x+Δx,y+Δy) − f(x,y+Δy) + f(x,y+Δy) − f(x,y) ≅
≅ (f(x,y+Δy)/x)·Δx + (f(x,y)/y)·Δy

As Δx→0 and Δy→0, we can replace these increments with infinitesimal differentials and, using the smoothness of our functions (in particular, continuity of partial derivatives), we can write the following equivalence between infinitesimals:
df(x,y)=f(x+dx,y+dy)−f(x,y) =
(f(x,y)/x)·dx + (f(x,y)/y)·dy
This expression is called total differential of a function of two variables.

Consider now that both arguments of our function f(x,y) are, in turn, functions of some argument:
x = x(t)
y = y(t)
We can use the same expression for a total differential
df(x,y) = (f(x,y)/x)·dx + (f(x,y)/y)·dy
but, considering that x and y are functions of t and, therefore,
dx = x'(t)·dt and
dy = y'(t)·dt,
we get the following:
df(x,y) = (f(x,y)/x)·x'(t)dt + (f(x,y)/y)·y'(t)dt

From the last equivalence we derive the formula for total derivative
df(x,y)/dt = (f(x,y)/x)·x'(t) + (f(x,y)/y)·y'(t)
This formula represents the chain rule for a function of two arguments when these arguments are, in turn, functions of some other same argument.

Example 5

Consider certain quantity of ideal gas in a reservoir with a piston, so we can change its volume, and a heater, so we can change its temperature.
The law of physics tells that the pressure P, volume V and absolute temperature T are connected by a formula
P·V/T = const
where the constant on the right depends on quantity of gas and in our case can be fixed and equal to C.

Let's apply some pressure to a piston to squeeze the gas.
The function that describes the change of volume with time is V(t).
Let's heat the gas.
The function that describes the change of temperature with time is T(t).
How fast the pressure would rise?

Since P(t)·V(t)/T(t)=C,
P(t) = C·T(t)/V(t)
The speed, with which the pressure is rising is a derivative dP(t)/dt
To calculate this derivative, we can use the formula of total derivative of a function of two arguments:
dP(t)/dt = (P(V,T)/V)·V'(t) + (P(V,T)/T)·T'(t) =
= −C·T(t)·V'(t)/V²(t) + C·T'(t)/V(t)

Monday, June 5, 2017

Unizor - Partial Derivatives - ∂²/∂x ∂y = ∂²/∂y ∂x





Notes to a video lecture on http://www.unizor.com

Partial Derivatives -
∂²/∂x ∂y = ∂²/∂y ∂x


In the following examples compare ∂²z/∂x ∂y and ∂²z/∂y ∂x.
They should be identical.

Example 1

Let z=√x·y
Then
z/∂x = y/(2√x·y)
∂²z/∂y ∂x = 1/(4√x·y)
z/∂y = x/(2√x·y)
∂²z/∂x ∂y = 1/(4√x·y)

Example 2

Let z=ex·y
Then
z/∂x = y·ex·y
∂²z/∂y ∂x = (x·y+1)·ex·y
z/∂y = x·ex·y
∂²z/∂x ∂y = (x·y+1)·ex·y

Example 3

Let z=1/(x²+y²)
Then
z/∂x = −2x/(x²+y²)²
∂²z/∂y ∂x = 8x·y/(x²+y²)³
z/∂y = −2y/(x²+y²)²
∂²z/∂x ∂y = 8x·y/(x²+y²)³

Example 4

Let z=sin(x)/y²
Then
z/∂x = cos(x)/y²
∂²z/∂y ∂x = −2cos(x)/y³
z/∂y = −2sin(x)/y³
∂²z/∂x ∂y = −2cos(x)/y³

Example 5

Let z=arctan(x√y)
Then
z/∂x = y/(1+x²·y)
∂²z/∂y ∂x = (1−x²·y)/2√y(1+x²·y)²
z/∂y = x/[2√y(1+x²·y)]
∂²z/∂x ∂y = (1−x²·y)/2√y(1+x²·y)²

Example 6

Let z=yx
Then
z/∂x = yx·ln(y)
∂²z/∂y ∂x = yx−1·(x·ln(y)+1)
z/∂y = x·yx−1
∂²z/∂x ∂y = yx−1·(x·ln(y)+1)

Unizor - Partial Derivatives - Examples





Notes to a video lecture on http://www.unizor.com

Partial Derivatives - Examples

Example 1

Let z=√x·y
Then
z/∂x = assuming y constant = y/(2√x·y)
z/∂y = assuming x constant = x/(2√x·y)

Example 2

Let z=ex·y
Then
z/∂x = assuming y constant = y·ex·y
z/∂y = assuming x constant = x·ex·y

Example 3

Let z=1/(x²+y²)
Then
z/∂x = assuming y constant = −2x/(x²+y²)²
z/∂y = assuming x constant = −2y/(x²+y²)²

Example 4

Let z=sin(x)/y²
Then
z/∂x = assuming y constant = cos(x)/y²
z/∂y = assuming x constant = −2sin(x)/y³

Example 5

Let z=arctan(x√y)
Then
z/∂x = assuming y constant = y/(1+x²·y)
z/∂y = assuming x constant = x/[2√y(1+x²·y)]

Example 6

Let z=yx
Then
z/∂x = assuming y constant = yx·ln(y)
z/∂y = assuming x constant = x·yx−1

Friday, June 2, 2017

Unizor - Definite Integrals - Length of Curve





Notes to a video lecture on http://www.unizor.com

Definite Integrals -
Length of Curve


Our task is to calculate a length of a curve on a coordinate plane, defined parametrically as a set of points (x(t),y(t)), where x(t) and y(t) are smooth functions of parameter t∈[a,b].

This is one of the typical integration problem and can be approached similarly to our approach to calculate the area under a curve.

Let's break down a segment [a,b] into N intervals by points a=t0, t1,...tN=b, which results in corresponding breaking of our curve into smaller pieces by points
(x0,y0)=(x(t0),y(t0)),
(x1,y1)=(x(t1),y(t1)),...
...
(xN,yN)=(x(tN),y(tN)),

Each small piece of a curve can be approximated with a straight line from one of its ends to another, and this approximation will be better with the density of break points increasing.
So, the n-th piece of a curve is approximated with a segment from point (xn−1,yn−1) to point (xn,yn).

The length of this n-th piece of a curve Ln can be calculated using the regular formula of a length of a segment between two points on a plane:
Ln² = (xn−xn−1)²+(yn−yn−1

Taking into account that both coordinates are functions of parameter t, we can express it differently:
Ln² = (x(tn)−x(tn−1))² +
+ (y(tn)−y(tn−1))²


Notice that
x(tn)−x(tn−1) ≅ xI(tn)·(tn−tn−1)
where xI(t) is a derivative of function x(t) by t and approximation gets better and better as we increase the density of points tn.

So, we can express the length of the n-th piece of a curve as
Ln² ≅ [xI(tn)² + yI(tn] ·
· (tn−tn−1


From this we get
Ln ≅ SQRT[xI(tn)² + yI(tn] ·
· (tn−tn−1)


As before, we use Δtn=tn−tn−1.
Now the length of a curve can be approximated by this sum:
L ≅ Σn∈[1,N] Ln ≅
≅ Σn∈[1,N] f(xn)·Δtn
where
f(t)=SQRT[xI(t)² + yI(t)²]

Recall the definition of the definite integral:
abf(x) dx =
lim 
Σi∈[1,N] f(xiΔxi
where Δxi=xi−xi−1 represents partitioning of segment [a,b] into N parts, and it is assumed that the widest interval Δxi is shrinking to zero by length as N→∞.

Clearly, we are dealing with an integral in our case. The sum of pieces of our curve represents Riemann sum, and the limit of this sum, as the density of points tn increases, is the following integral:
abSQRT[xI(t)² + yI(t)²dt

So, the length of the curve on a coordinate plane, defined parametrically by coordinate functions x(t) and y(t), where t∈[a,b], equals to
abSQRT[xI(t)² + yI(t)²dt

Let's apply this to a couple of practical problems.

Problem 1
Calculate the length of a circle of radius R.

Solution
To define a circle parametrically, let's choose an angle between its radius and a positive direction of the X-axis as a parameter t∈[0,2π].
Then the X-coordinate of a point on a circle, whose radius forms an angle t with positive direction of the X-axis, equals to x(t)=R·cos(t) and Y-coordinate equals to y(t)=R·sin(t).

Now we can use the above formula to calculate the length of circle.
0SQRT[xI(t)² + yI(t)²dt =
0SQRT[R²sin²(t) +
+ R²cos²(t)
dt =
0dt =
R·2π − R·0 = 2πR
As we see, the length, as we counted, equals to the one in a classical formula for the length of the circle. No surprise here.
The end.

Problem 2
Calculate the length of an astroid given parametrically as
x=R·cos³(t)y=R·sin³(t)
where t∈[0,2π]

Solution
Astroid looks like this:

Its vertices are at distance R from the origin, and its four arcs correspond to parameter t changing in each quadrant from 0 to .
Using the symmetry, lets' calculate the length of only one arc for t∈[0,π/2] and then multiply it by four.
First, calculate the derivatives by t:
xI(t) = −3R·cos²(t)·sin(t)
yI(t) = 3R·sin²(t)·cos(t)
Now we use the formula for the length of a curve.
SQRT[xI(t)² + yI(t)²] =
3R·|sin(t)·cos(t)| =
(3/2)R·|sin(2t)|
This should be integrated within margins t∈[0,π/2].
Within these margins 2t changes from 0 to π and sin(t) is non-negative, so we can drop absolute value.
So, we need to find the following integral:
0π/2(3/2)R·sin(2t) dt
Indefinite integral of sin(2t) is −cos(2t)/2, which means that we have to calculate the following
(−cos(π)/2) − (−cos(0)/2) =
1/2 + 1/2 = 1.
Therefore, the length of one quarter of an astroid equals to (3/2)R·1 = (3/2)R and the length of an entire astroid is (3/2)R·4=6R.
The end.