#OK to post homework #Ariana Yousafzai, 10/10/2020, Assignment 9 1. (i) 34072670435163151604473016926977985246587536905011755466422969276055487861263 (ii) DiagWalks3D({[30,30,30},181714188) NOTE: trying to evaluate this in Maple repeatedly caused my computer to crash. I also attempted this in the Rutgers Virtual Computer Lab. 2. 3. 4. (i) S={[0,1],[1,0]} OEIS: A000984 {(-n - 2)*u(n + 2) + (6 + 4*n)*u(n + 1), u(0) = 1, u(1) = 2} (ii) S={[0,1],[1,0],[1,1]} OEIS: A001850 [{(-n - 3)*u(n + 3) + (15 + 6*n)*u(n + 2) + (-n - 2)*u(n + 1), u(0) = 1, u(1) = 3, u(2) = 13}, ogf] (iii) S={[0,1],[1,0],[0,2],[2,0]} OEIS: A036692 [{(352*n^3 + 2768*n^2 + 7088*n + 5920)*u(n + 1) + (-484*n^3 - 4048*n^2 - 11184*n - 10204)*u(n + 2) + (-352*n^3 - 3120*n^2 - 9114*n - 8766)*u(n + 3) + (55*n^3 + 515*n^2 + 1570*n + 1560)*u(n + 4), u(0) = 1, u(1) = 2, u(2) = 14, u(3) = 84}, ogf] (iv) S={[0,1],[0,2],[1,0],[2,0],[1,1],[2,2]} OEIS: A192365 5. (i) S={[1,0,0],[0,1,0],[0,0,1]} OEIS: A006480 [{(-27*n^2 - 81*n - 60)*u(n + 1) + (n^2 + 4*n + 4)*u(n + 2), u(0) = 1, u(1) = 6}, ogf] (ii) S={[0,0,1],[0,1,0],[0,0,1],[1,1,0],[1,0,1],[0,1,1]} OEIS: A268542 [{(-567*n^3 - 4104*n^2 - 9549*n - 7140)*u(n + 1) + (-1281*n^3 - 10553*n^2 - 28546*n - 25400)*u(n + 2) + (-672*n^3 - 6208*n^2 - 18752*n - 18400)*u(n + 3) + (42*n^3 + 430*n^2 + 1424*n + 1504)*u(n + 4), u(0) = 1, u(1) = 4, u(2) = 42, u(3) = 520}, ogf] (iii) S={[0,0,1],[0,1,0],[0,0,1],[1,1,0],[1,0,1],[0,1,1],[1,1,1]} OEIS: A112019 [{(-59*n^3 - 448*n^2 - 1084*n - 848)*u(n + 1) + (-295*n^3 - 2535*n^2 - 7185*n - 6740)*u(n + 2) + (-2301*n^3 - 22074*n^2 - 69941*n - 73044)*u(n + 3) + (118*n^3 + 1250*n^2 + 4336*n + 4896)*u(n + 4), u(0) = 1, u(1) = 5, u(2) = 55, u(3) = 749}, ogf] 6. #`DiagSeq4(f,x1,x2,x3,x4,N): Given a rational function f of the variables x1, x2, x3, and x4, such that the denominator does not vanish at (0,0,0,0)` DiagSeq4:=proc(f,x1,x2,x3,x4,N) local i: if subs({x1=0,x2=0,x3=0,x4=0},denom(f))=0 then print(`The denominator of`, f, `should have a non-zero constant term `): RETURN(FAIL): fi: [seq(coeff(taylor(coeff(taylor(coeff(taylor(f,x1=0,N+1),x1,i),x2=0,N+1),x2,i),x3=0,N+1),x3,i),x4=0,N+1)x4,i) i=0..N)]: end: DiagWalks4D := proc(S, N) local s, x, y, z, k; if not (type(S, set) and type(N, integer) and 0 <= N) then print(`Bad input`); RETURN(FAIL); end if; DiagSeq4(1/(1 - add(x^s[1]*y^s[2]*z^s[3]*k^s*[4], s in S)), x, y, z, k, N); end proc