Question
Its easy discreet math. Translate from norwegian. Exercise 5 Let be the number of strings of length n from the alphabet A, B, C, 0,
Its easy discreet math. Translate from norwegian.
Exercise 5
Let be the number of strings of length n from the alphabet A, B, C, 0, 1 with the restriction that the strings must start with A, B or C, and the combination B0, B1, C0, or C1 must not occur . a) What is a1 and a2? b) Explain that an = 5an 1 - 4an 2 c) Solve the difference equation with the initial values you found in a). If you did not find a1 and a2, solve the difference equation with a0 = 1 and a1 = 3.
Exercise 4
a) In the figure below there is an incorrect graph G. a) Use Dijkstra's algorithm to find the shortest path from a to z. Preferably use a table such as the one below to solve this problem.
b) Does the graph have an Euler cycle? Does it have an Euler trail? Remember to base the answer.
Oppgave 5 La an vre antall strenger av lengde n fra alfabetet{A, B, C, 0, }} med den restriksjonen at strengene m starte med A, B elle C, og kombinasjonen BO, B1, Co, eller Ci m ikke forekomme. a) Hva er ajog az? b) Forklar at 5an-1-4an-2 c) Ls differensligningen med de startverdiene du fantia). Hvis du ikke fant ajog az, ls differensligninga med ao = 1 og a1 = 3. an = Oppgave 4 I figuren under fins en uretta graf G. a) Bruk Dijkstra sin algoritme til finne korteste veg fra a til z. Bruk helst tabell slik som den nedenfor til lse denne oppgaven. b 2 d 3 . 3 a 6 7 8 3 ks a b d e f 8 Z 0 0 oo oo 18 oo b) Har grafen en Euler sykel? Har den en Euler sti? Husk grunngi svaret. Oppgave 4 I figuren under fins en uretta graf G. a) Bruk Dijkstra sin algoritme til finne korteste veg fra a til z. Bruk helst tabell slik som den nedenfor til lse denne oppgaven. b 2 d 3 . 3 a 6 7 8 3 ks a b d e f 8 Z 0 0 oo oo 18 oo b) Har grafen en Euler sykel? Har den en Euler sti? Husk grunngi svaret. Oppgave 5 La an vre antall strenger av lengde n fra alfabetet{A, B, C, 0, }} med den restriksjonen at strengene m starte med A, B elle C, og kombinasjonen BO, B1, Co, eller Ci m ikke forekomme. a) Hva er ajog az? b) Forklar at 5an-1-4an-2 c) Ls differensligningen med de startverdiene du fantia). Hvis du ikke fant ajog az, ls differensligninga med ao = 1 og a1 = 3. an = Oppgave 4 I figuren under fins en uretta graf G. a) Bruk Dijkstra sin algoritme til finne korteste veg fra a til z. Bruk helst tabell slik som den nedenfor til lse denne oppgaven. b 2 d 3 . 3 a 6 7 8 3 ks a b d e f 8 Z 0 0 oo oo 18 oo b) Har grafen en Euler sykel? Har den en Euler sti? Husk grunngi svaret. Oppgave 4 I figuren under fins en uretta graf G. a) Bruk Dijkstra sin algoritme til finne korteste veg fra a til z. Bruk helst tabell slik som den nedenfor til lse denne oppgaven. b 2 d 3 . 3 a 6 7 8 3 ks a b d e f 8 Z 0 0 oo oo 18 oo b) Har grafen en Euler sykel? Har den en Euler sti? Husk grunngi svaretStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started