From the assignment we see that c0 and d1 and a as a


We have the differential equation

We simulate it with 64-bits floating point. For a large value of n the calculated solution will be:

We have the differential equation

We simulate it with 64-bits floating point. For a large value of n the calculated solution will be:

My attempt was to first solve it by hand:

The two roots: r_1=1/2 r_2=1/3

y_n=C(1/2)^n+D(1/3)^n

y_0=C+D=1 y_1=C 1/2+D 1/3=1/2 (1-D)1/2+D 1/3=1/2

1/2-1/2 D+D 1/3=1/2

-3/6 D+D 2/6=0 D=0 C=1

y_n=(1/2)^n

I don't see where the floating point inequarcy would lead to a wrong anwer for large n. Can you show where it does that?

Question 1:

A second order inhomoegeneous differential equation has the solution

If one are given two start values one would obtain that it is:

If the equation is simulated on a pc with 64-bits floating point one would get for large n that the computed result would be

From the assignment we see that C=0 and D=1 and A as a guessed solution is 1. How can you show that this would create overflow?

My attempt was to first solve it by hand:

The two roots: r_1=1/2 r_2=1/3

y_n=C(1/2)^n+D(1/3)^n

y_0=C+D=1 y_1=C 1/2+D 1/3=1/2 (1-D)1/2+D 1/3=1/2

1/2-1/2 D+D 1/3=1/2

-3/6 D+D 2/6=0 D=0 C=1

y_n=(1/2)^n

I don't see where the floating point inequarcy would lead to a wrong anwer for large n. Can you show where it does that?

Question 2:

A second order inhomoegeneous differential equation has the solution

If one are given two start values one would obtain that it is:

If the equation is simulated on a pc with 64-bits floating point one would get for large n that the computed result would be

From the assignment we see that C=0 and D=1 and A as a guessed solution is 1. How can you show that this would create overflow?

Solution Preview :

Prepared by a verified Expert
Mathematics: From the assignment we see that c0 and d1 and a as a
Reference No:- TGS01256806

Now Priced at $20 (50% Discount)

Recommended (94%)

Rated (4.6/5)