(* You should be able to copy and paste this text file directly into Mathematica. These notes will be interpreted as commented code. *) (* For problem 2 *) pc[x_]:= -x + x^2 + c x^3 (* This defines the function pc[x]. Note that you must include underscores after each variable in the function definition to tell Mathematica that x is one of the variables that p depends on. *) Simplify[ (p[p[x]] ] (* This will simplify the function p[p[x]], needed for the neutral classification *) (* For problem 3 *) p[x_] := x^3 - a x (* This defines the function p[x]. Note that you must include underscores after each variable in the function definition to tell Mathematica that x is one of the variables that p depends on. *) Simplify[ (p[p[x]] - x) / (p[x] - x)] (* This will simplify the quotient (p[p[x]] - x) / (p[x] - x), useful for finding 2-cycles *) (* For problem 4 *) p[x_]:= 1 + x - 3 x^2 - 15/4 x^3 + 3/2 x^4 + 9/4 x^5 (* This is the function in part b *) (* For problem 5 *) s1[x_]:= -x + x^2 - x^3 + 3/2 x^4 - 5/2 x^5 + 19/8 x^6 - 139/80 x^8 + 653/1000 x^10 s2[x_]:= -x + x^2 - x^3 + 3/2 x^4 - 5/2 x^5 + 19/8 x^6 - 139/80 x^8 + 652/1000 x^10 (* These are the two functions in the problem *) NestList[s1, 0.1`50, 10] (* This will compute the first 10 iterates of 0.1 under s1, where 0.1 starts with 50 decimal places of precision. *) Expand[s1[s1[x]] (* This will expand out the expression s1[s1[x]] *) Series[s1[s1[x]], {x,0,14}] (* This will compute the Taylor series expansion for s1[s1[x]] in the variable x, centered at x=0, to degree 14 in x *) (* For problem 6 *) f[x_] := x + x Sin[1/x] NestList[f, 0.1`50, 10] (* This will compute the first 10 iterates of 0.1 under the function f, where 0.1 starts with 50 decimal places of precision. *)