ubsuny / 23-Homework6G2

Apache License 2.0
0 stars 9 forks source link

Number of subintervals #15

Closed pratibha77118 closed 9 months ago

pratibha77118 commented 9 months ago

Hi all, For using Sympson's and Trapezoidal method we have to define the number of subinterval. For this we define the function as "def simpson(f, a, b, n)" , what is the value of n (number of subintervals ) to be used to calculate and plot the integration here?

AhmedCode99 commented 9 months ago

That is up to you, the more intervals you have the more accurate your answer will be. But your code will take longer to run

pratibha77118 commented 9 months ago

@AhmedCode99 thanks for the answer.

AhmedCode99 commented 9 months ago

You're welcome