+1-415-315-9853

info@mywordsolution.com

## Engineering

 Civil Engineering Chemical Engineering Electrical & Electronics Mechanical Engineering Computer Engineering Engineering Mathematics MATLAB Other Engineering Digital Electronics Biochemical & Biotechnology

problem1) Create a MATLAB function called problem3 that finds the root of an equation numerically using the following recursive formula:

xn+1= xn– f(xn)/g(xn) , for n =1,2,3,……

where g(xn) = (f(xn  +f(xn ))-f(xn  ))/f(xn ) . This iterative procedure should stop when the absolute difference between xn andxn+1is less than a given tolerance epsilon. The function must accept as inputs , a scalar function ‘f’, an initial number ‘x’ and a positive number ‘epsilon’ to terminate the procedure. Hence use this numerical technique to find the root of the equation ex –x2 =0

problem2) Let St be the price of one share of a particular company at time t. If the price St+1 at time t+1 can wither take the value of uStwith probability p1 (where u>1), remain the same with probability p2 or go down to dStwith probability 1-p1-p2 (where 0t}t=020for given u, d, p1,p2 and plot St against t. Hence, by counting the number of paths, find out the probability that S6 = S0u2d3 . Do this by using the command rand.

problem3) Suppose you are at a casino playing roulette and that you are betting on black to turn up. You start by betting 1 euro. If you win bet another 1 euro in the next game. If you lose you double your previous bet. You will stop playing when you have either won at least 10 euros or lost more than 100 euros. Create a script file called problem6 to simulate this system. Then play the game 5000 times and record your performance. Use the command rand.

problem4) A Legendre polynomial of degree n is given by the following expression:

Pn(x) = (1/2nn!)*(dn/dxn)*(x2-1)n

where(dn/dxn)f is the nth derivative of function f.

(a) Generate the first four polynomials and use the command subplot to plot the resulting graphs. Use the different colours and symbols for the plots

(b) create a Matlab function called legendrepolynomial which for given inputs n and m find outs the integral

∫Pn(x)Pm(x) dx

using the trapezoid rule with a suitability chosen number of gridpoints. Comment on the output obtained.

Note: Limits of integral from -1 to 1

problem5) A Eulerian number Pn,kis the number of permutations p1p2….pn of the numbers 1,2,….,n in which there are k places with pjj+1. For ex P3,1= 4 because there are four permutations having one ascent which hare 132,213,231,312. This number can be generated using the following recurrence relation

Pn,0 = 1 for all n>=0

Pn,k= 0 for all k>=n

Pn,k= (k+1)Pn-1,k+ (n-k)Pn-1,k-1  for all k=1,2,…..,n-1

(a) create a function called euleriannumber which generates a Eulerian number for a given n and k

(b) create a script file called euleriannidentity which calls the function euleriannumber and then verifies the identity

∑in = ∑Pn,k(m+k+1 , n+1)

for given m,n and k, where (m+k+1 , n+1) = (m+k+1)!/((n+1)!*(m+k-n)!)

note: limits of in= from i=1 to m

limits of Pn,k(m+k+1 , n+1) = from k=0 to n-1

MATLAB, Engineering

• Category:- MATLAB
• Reference No.:- M9874

Have any Question?

## Related Questions in MATLAB

### Car parking systema building of 10 floors is used for

CAR PARKING SYSTEM A building of 10 floors is used for parking cars. The area of each floor can be used for parking 100 cars. An automatic parking system is used to detect which parking slot is free at each moment. So, t ...

### Use matlab to solve the following equations please i plot

Use Matlab to solve the following equations. Please (i) plot the solution as a function of t for t  ∈ [0, 100]. (ii) draw the phase diagram of the ODE. 1. dy/dt = y 2 + y with y(0) = 1         dy 1 /dt = y 2 2.           ...

### Problem -tom cat is chasing jerry mouse the initial

Problem - Tom cat is chasing Jerry mouse the initial distance between them is S 0 = 100m. Tom runs V c = 4-at m/s (negative accident) Jerry's velocity depends on the distance between Tom& Jerry V = Vmax - Ks (3-0.025 m/s ...

### Question 1backgroundclimate change is a change in global or

QUESTION 1 Background Climate change is a change in global or regional climate patterns, in particular a change apparent from the mid to late 20th century onwards and attributed largely to the increased levels of atmosph ...

### Question 1 a what is the period of the forced oscillation

Question 1. (a) What is the period of the forced oscillation? What is the numerical value (modulo 2Π) of the angle α defined by? (b) In this question you are asked to modify the file LAB06ex1.m in order to plot the compl ...

Problem 1 [10pts.]: The CSU-CHILL radar made observations of the Ponnequin Wind Farm located on the boarder of Wyoming and Colorado near I-25. The wind farm is approximately 62 km away from the radar. Complex valued digi ...

### Question 1backgroundyou have been asked to manage a project

QUESTION 1 Background You have been asked to manage a project to install a pipeline from an offshore gas platform to an onshore gas processing plant, and to find the cheapest design that is possible. The platform is Q km ...

### Instructions for each of the following exercise create an

Instructions: For each of the following exercise, create an M-file to store the MATLAB commands. Copy and paste the M-file into a text document. Include in the text document the pictures produced by MATLAB. Resize and cr ...

### 1 calculate the following for the function f x e-3x -

1) Calculate the following for the function f (x) = e -3x - 2x a. Calculate the derivative of the function by hand. Write a MATLAB function that calculates the derivative of this function and calculate the derivative at ...

### Matlabproject descriptionwrite a mileage per gallons and

MATLAB Project description: Write a mileage per Gallons and miles per dollar calculator program using two functions, one to calculate MPG and one to calculate MPD. The application will prompt the user to type the odm rea ...

• 13,132 Experts

## Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

### WalMart Identification of theory and critical discussion

Drawing on the prescribed text and/or relevant academic literature, produce a paper which discusses the nature of group

### Section onea in an atwood machine suppose two objects of

SECTION ONE (a) In an Atwood Machine, suppose two objects of unequal mass are hung vertically over a frictionless

### Part 1you work in hr for a company that operates a factory

Part 1: You work in HR for a company that operates a factory manufacturing fiberglass. There are several hundred empl

### Details on advanced accounting paperthis paper is intended

DETAILS ON ADVANCED ACCOUNTING PAPER This paper is intended for students to apply the theoretical knowledge around ac

### Create a provider database and related reports and queries

Create a provider database and related reports and queries to capture contact information for potential PC component pro