Question

1. Untuk suatu nilai x > fungsi In(x) dapat diaproksimasi dengan menggunakan deret sbb.: X-1 1 In(x) = 1 + 3 Buatlah algoritm

For an x > 1/2, function ln(x) can be approximately using the series

questions:

Create an algorithm or program using the "call function" to approximate the function ln(x) for an x to the N first term.

Hint: as an input is an x and N

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Here is the solution to your question. I tried my best to solve your doubt, however, if you find it is not as good as expected by you. Please do write your further doubts regarding this question in the comment section, I will try to resolve your doubts regarding the submitted solution as soon as possible.


If you think, the solution provided by me is helpful to you please do an upvote.

Solution is in C programming.

main.c saving... 1 #include <stdio.h> 2 #include<math.h> int main(void) 3 4 { 5 6 7 8 long double x; int N; printf(Enter val

#include <stdio.h>

#include<math.h>

int main(void)

{

long double x;

int N;

printf("Enter value of x: ");

scanf("%Lf",&x);

printf("Enter value of N: ");

scanf("%d",&N);

if(x<=1/2)

{

printf("x must be greater than 1/2\n");

}

else

{

long double lnx=0;

for(int i=1;i<=N;i+=1)

{

lnx+=((long double)(1/(float)(i)))*pow((x-1)/x,i);

}

printf("ln(%Lf)=%Lf\n",x,lnx);

}

return 0;

}



?./main Enter value of x: 3 Enter value of N: 100 ln(3.000000)=1.098612
Solution using calculator
In(3) = 1.09861228867 Rad Deg x! ) % AC Inv sin In 7 8 9 1. TT cos log 4 5 6 X e tan ✓ 1 3 - N Ans EXP x 0 IL +
Add a comment
Know the answer?
Add Answer to:
For an x > 1/2, function ln(x) can be approximately using the series questions: Create an...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • principle of computer architecture Section A Bahagian A Answer ALL questions from this section awab SEMUA...

    principle of computer architecture Section A Bahagian A Answer ALL questions from this section awab SEMUA soalan dari bahagian ini] Question 1 Soalan I (CI, CO1, POI) (a) Describe FOUR (4) basic functions of a computer system. ITerangkan EMPAT (4) fungsi asas sebuah sisiem komputer.) (4 Marks/Markah) (b) Describe the relationship between: [Terangkan hubungan di antara:] ) The width of address bus and the memory capacity. lebar bas alamat dan kapasiti memori. n The width of data bus and the...

  • A motor is given in Figure 1 with the terminal voltage of the motor is 320 V, armature resistance of 2 2, series field resistance of 3 2, and KC value of 0.248. Sebuah motor diberi dalam Rajah 1 deng...

    A motor is given in Figure 1 with the terminal voltage of the motor is 320 V, armature resistance of 2 2, series field resistance of 3 2, and KC value of 0.248. Sebuah motor diberi dalam Rajah 1 dengun voltan pangkalan pada motor sebanyak 320 V, rintangan angker adalah 2 S rintangan madan sesiri adalah 3 Q, dan nilai KC sebanyak 0.248. Figure 1 Rajah I a) Calculate the speed of the motor in Figure 1 when the armature...

  • You are given a small pipe with a diameter of 1 mm flowing cooling fluid (water)...

    You are given a small pipe with a diameter of 1 mm flowing cooling fluid (water) at a temperature of 20C. Fluid flow velocity is regulated at a constant speed of 0.2 m / s and assumed to be uniform. If the pipe surface is given a constant heat flux of 6000 W / m2 and you assume the analysis is done in a fully develop area, then based on your design calculations, at what length of the pipe (measured...

  • Consider the function f(e) (T2) that is to be represented by a Fourier series expansion over the interval-π t π and...

    Consider the function f(e) (T2) that is to be represented by a Fourier series expansion over the interval-π t π and f(t) = f(t + 2n). (b) Pertimbangkan fungsi f(c)(r t2) yang diwakili oleh kembangan siri π dan f(t) f(t + 2π). Founer dalam selang-π t Determine the Fourier series expansion. (i) Tentukan kembangan siri Fourer (7 marks/markah) (i) By using your answer in (), show that Dengan menggunakan jawapan anda dalam (), tunjukkan bahawa. -)n+1 (5 marks/markah) Consider the...

  • UwJTOWIU (5 Marks / Markah) (b) Obtain the v(t) in Figure 3(a) using Fourier Transform if...

    UwJTOWIU (5 Marks / Markah) (b) Obtain the v(t) in Figure 3(a) using Fourier Transform if vy(t) = " u(t) V and is(t) = 28(t) A. "ul V dan (Dapatkan vt) di dalam Rajah 3(a) menggunakan jelmaan Fourier jika v.() - 1:(t) = 28(1) A.) (6 Marks / Markah) vo(t) 100 § 17+ vt) is(t) 28 1t) A Figure 2(a) fRajak 2(a)] yurtz The transfer function of a circuit is [Rangkap pindah untuk satu litar adalah m2 +12 H@=oja+2) If...

  • Pada 31 Disember 2017, Mahligai Berhad mempunyai baki aset loji dan susut nilai terkumpul adalah seperti...

    Pada 31 Disember 2017, Mahligai Berhad mempunyai baki aset loji dan susut nilai terkumpul adalah seperti berikut: At 31 December 2017, Mahligai Berhad's plant asset and accumulated depreciation accounts had the following balances: Aset bukan semasal Non- current Assets Nilai/Value Susut nilai terkumpull Accumulated depreciation RM RM Kaedah susut Hayat nilail bergunal Depreciation Useful life method Tahun/Years Tanah/Land 175,000 Bangunan/Buildings 1,500,000 240,000 Jentera/Machinery 1,125,000 225,000 Garis Lurus Straight line Garis Lurus Straight line Garis Lurus Straight line 10 Paten/Patent 500,000...

  • [EUM 114 1. Let f(x) be a function of period 2 (a) over the interval 0<x<2 such that f(x) = - f(x)pada selan...

    [EUM 114 1. Let f(x) be a function of period 2 (a) over the interval 0<x<2 such that f(x) = - f(x)pada selang Diberikan f(x) sebagai fungsi dengan tempoh 2t yang mana 0<x<2m Sketch a graph of f (x) in the interval of 0 <x< 4 (1 marks/markah) Demonstrate that the Fourier Series for f(x) in the interval 0<x< 2n is (ii) 1 2x+-sin 3x + 1 sin x + (6 marks/markah) Determine the half range cosine Fourier series expansion...

  • Problem #5 Equation 1 is the infinite Taylor series expansion of ln(1 + x), where In is the natur...

    Problem #5 Equation 1 is the infinite Taylor series expansion of ln(1 + x), where In is the natural logarithm: 5 (-1)k+1 Eqn. 1 Σ(-1)k+1 k In(1 + x) Eqn. 2 Equation 2 is the finite version that calculates an approximation for ln(1 + x). Instead of letting k go to infinity, it stops summing once k reaches some fixed value N. Task Develop a program that can compute ln(1 +x). Have it first ask the user to enter x...

  • Problem #5 Equation 1 is the infinite Taylor series expansion of ln(1 + x), where In...

    Problem #5 Equation 1 is the infinite Taylor series expansion of ln(1 + x), where In is the natural logarithm: 5 (-1)k+1 Eqn. 1 Σ(-1)k+1 k In(1 + x) Eqn. 2 Equation 2 is the finite version that calculates an approximation for ln(1 + x). Instead of letting k go to infinity, it stops summing once k reaches some fixed value N. Task Develop a program that can compute ln(1 +x). Have it first ask the user to enter x...

  • (1 point) Find Taylor series of function f(x) = ln(x) at a = 7. (f(1) =...

    (1 point) Find Taylor series of function f(x) = ln(x) at a = 7. (f(1) = (x – 7)") ܫ)ܐܶ Co C1 C2 = C3 = C4 Find the interval of convergence. The series is convergent: from 2 = left end included (Y,N): to = right end included (YN):

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT