Evaluate the integral for values of x from 0 to 3 in steps of 0.1 AND plot the integral.
The program needs to be written in Python 3. Can only import numpy and matplotlib. CAN NOT use lambda functions or classes of any kind.
from __future__ import division import numpy as np import matplotlib.pyplot as plt def trapizoidal(x): #function that will do integration using trapizoidal rule a=0 b=x #upper limit that will take from the array of x h=0.001 n=int((b-a)/h) c=np.linspace(a,b,n+1) #print(c) d=np.exp(-c*c) f=0 for i in range(1,n): f=f+d[i] p=2*f+d[0]+d[n] u=p*(h/2) print(u) #result of the integration return u m=np.linspace(0,3,(int(3/.1+1))) #taking x values for plottiing graph n=np.zeros(len(m)) #initial array where integral values will be stored for i in range(len(m)): n[i]=trapizoidal(m[i]) #storing integration values plt.plot(m,n,label='integration') #plotting graph plt.title('plot of the integration and function from 0 to 3') c=np.exp(-m**2) plt.plot(m,c,label='function') plt.legend() plt.show()
Evaluate the integral for values of x from 0 to 3 in steps of 0.1 AND plot the integral. The prog...
intelligent control systems fuzzy logic based contril 0.8 0.7 04 0.3 0.2 0.3 b) Plot the ou a) Plot the output: -BUB 1.0 0.9 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.5 0.4A 0.3 0.2 0.2 0.17 0.1 c) Determine the defuzzified output y, by using I. Center of Gravity Method (COG) Height Method (H) II. + 1 (0.5)+3 05)+ 5(0.1) 6() 0.8 0.7 04 0.3 0.2 0.3 b) Plot the ou a) Plot the output: -BUB 1.0 0.9 0.9...
Use the graph to estimate K. 1.0 0.75 Yo₂ 0.5 0.25 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 [L] (M)
Using the NMR specturm included, fill in the correct chemical shift (ppm) for each letter of the molecule above. D. E. 300 MHz 'H NMR In CDC13 1.2 1.1 1.0 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0.0 -0.1 4.0 3.5 3.0 2.5 2.0 1.5 1.0 0.5
3. Below is a Lineweaver-Burke plot of an enzyme reaction in the presence and absence of an inhibitor. 2.4 2.3 2.2 2.1 2 1.9 1.8 1.7 1.6 1.5 1.4 1.3 1.2 1.1 1 0.9 0.8 < 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 -0.1 -0.2 -0.3 -0.4 -0.5 -0.6 -0.7 -0.8 . . . . . -1 -0.9 -0.8 -0.7 -0.6 -0.5 -0.4 -0.3 -0.2 -0.1 O 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1/[S]...
Use contour integration to evaluate the integral 2T 1 I (5 4 cos (0))2 S 0 diagram showing the contour and the singularities Draw and label a For your information, the graph of the integrand is given below. L0- 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1. 7T 2n 4. - Use contour integration to evaluate the integral 2T 1 I (5 4 cos (0))2 S 0 diagram showing the contour and the singularities Draw and label a For...
I'm trying to solve this differential equations by using matlab and I've got a plot from the code attached. But I wanna get a plot of completely sinusoidal form. If I can magnify the plot and expand x-axis, maybe we can get the sinusoidal form. So help me with this problem by using matlab. Example is attached in below. One is the plot from this code and another is example. function second_order_ode2 t=[0:0.001:1]; initial_x=0; initial_dxdt=0; [t,x]=ode45(@rhs,t,[initial_x initial_dxdt]); plot(t,x(:,1)) xlabel('t') ylabel('x')...
of column E-5 (do not consider modification factor, Th). Assume the beams framing in to the top of your first story column are W24x131 (bending about the strong axis) and the second story column E-5 is a W14x48. [5 points] b. Calculate the effective length factor, K, based on the end conditions in the elevation view From Table 1-1: W14x74: 1 795, ly 138 W14x48: 484, ly 51.4 W24x131: Ix 4020, ly 340 GA 10.0 3.0 500 10.0 18 788...
I'm trying to solve this differential equations by using matlab and I've got a plot from the code attached. But I wanna get a plot of completely sinusoidal form. If I can magnify the plot and expand x-axis, maybe we can get the sinusoidal form. So help me with this problem by using matlab. Example is attached in below. One is the plot from this code and another is example. function second_order_ode2 t=[0:0.001:1]; initial_x=0; initial_dxdt=0; [t,x]=ode45(@rhs,t,[initial_x initial_dxdt]); plot(t,x(:,1)) xlabel('t') ylabel('x')...
5. What is the slope of the best fit line for the plot of a vs. sin. What is the value of a at sine-1? How are these two values related? #1 Incline Angle 0-2° (m/s) 0.22 Time Interval (s) Displaceent (m) Average Velocity Average Acceleration 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 m/s/s 0.021 0.022 0.023 0.024 0.025 0.027 0.029 0.030 0.032 0.033 0.1 0.24 0.25 0.27 0.29 0.30 0.32 0.33 0.2 0.2 0.1 0.2 Average...
3. Make a plot of a vs. sin6 fon linear graph and draw a best fit line through the data. Extend the best fit line so that it intersects the point at sin@ = 1 . #1 Incline Angle 0-2° (m/s) 0.22 Time Interval (s) Displaceent (m) Average Velocity Average Acceleration 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 m/s/s 0.021 0.022 0.023 0.024 0.025 0.027 0.029 0.030 0.032 0.033 0.1 0.24 0.25 0.27 0.29 0.30 0.32 0.33...