Write program for computing of shortest trajectories in abg

Assignment Help Data Structure & Algorithms
Reference no: EM13880983

Write a program for computation of the shortest trajectories in ABG.

Input: set X (a 2D table with or without obstacles), an element p for which the trajectories should be calculated, relations of reachability for this element (if necessary*), location of the element (the start of trajectories), the end of trajectories, the length of trajectories.

Remark: If these are usual relations of reachability of a chess piece for a standard chess board they do not have to be defined explicitly. Instead you can refer to them by the respective number of the table 15x15, which can be stored in advance, e. g., the numbers 1-6.

Algorithm: You can use grammar Gt(1) but it generates only one trajectory. Your program should add something to it to generate ALL the shortest trajectories.

Output: Print shortest trajectories for sample locations for all the chess pieces (for 8x8 board with and without obstacles): Pawn (assume that Pawn can move straight ahead only), Knight, Bishop, Rook, Queen, King. Include at least one example of computation of trajectories for the element with unusual relations of reachability (different from chess pieces) and unusual board defined by you as part of the input of this program.

The output should be both: a graph "drawn on the board" and a list of coordinates of locations (stops) along those trajectories. A reasonable
explanation (or a proof) that all the required trajectories have been generated should be included.

In particular, as a simple test generate all the trajectories for the King from a5 to h5 of the length 7. You do not have to print them all (if your output is not a graph) but print their total number.

Reference no: EM13880983

Questions Cloud

What was the rate of return for owning serox : Serox stock was selling for $20 two years ago. The stock sold for $25 one year ago, and it is currently selling for $28. Serox pays a $1.10 dividend per year. What was the rate of return for owning Serox in the most recent year? (Round to the nearest..
Future value of an annuity : Jayadev Athreya has started on his first job. He plans to start saving for retirement early. He will invest $5,000 at the end of each year for the next 45 years in a fund that will earn a return of 10 percent. How much will Jayadev have at the end of..
Benefits and drawbacks of using broad notions of fairness : Evaluate the views of the Critical Legal Studies School of jurisprudence. What are the benefits and drawbacks of using broad notions of fairness in deciding cases
About the present value : Present value: Jack Robbins is saving for a new car. He needs to have $ 21,000 for the car in three years. How much will he have to invest today in an account paying 8 percent annually to achieve his target?
Write program for computing of shortest trajectories in abg : Write a program for computation of the shortest trajectories in ABG. Set X (a 2D table with or without obstacles), an element p for which the trajectories should be calculated.
Efficiency ratio and leverage ratio : Efficiency ratio: Gateway Corp. has an inventory turnover ratio of 5.6. What is the firm's days’ sales in inventory. Leverage ratio: Your firm has an equity multiplier of 2.47. What is its debt-to-equity ratio?
What is the present value of these payments : PV of multiple cash flows: Ferris, Inc., has borrowed from their bank at a rate of 8 percent and will repay the loan with interest over the next five years. Their scheduled payments, starting at the end of the year are as follows—$450,000, $560,000, ..
What would be the financial institutions net savings : An interest rate cap of 7% with a notational value of $18.9 million is available for a premium of 0.58%. The same notational value 3% floor is available for a premium of 0.64%. If current interest rates are at 8%, what would be the a financial instit..
Use a letter to mark each item in the following list : Learning which items belong in each cash flow statement category is an important first step in understanding their meaning. Use a letter to mark each item in the following list as a cash flow from Operating, Investing, or Financing activities. Put pa..

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  What is the cloud

What benefits does it bring and what potential problems will it bring

  Powerpoint presentation with the focus on stress management

Assume you have been asked to help new students identify ways in which they can manage their time so that they can be successful in an online learning environment.

  How to move from any spanning tree to other spanning tree

Illustrate that it is possible to move from any spanning tree T to any other spanning tree T0 by performing series of edge-swaps, that is, by moving from neighbor to neighbor.

  Creating application - two dimensional array

Make an application that either sums or averages rows or columns of a 2-dimensional array depending on user choices.

  Simplify rsa cryptosystem using prime number

Assume we tried to simplify RSA cryptosystem using just prime p instead of composite modulus N = pq. As in RSA, we would have encryption exponent.

  Explain types of information systems

Question 1. Explain five types of information systems, and give an example of each. Question 2. Describe three common reasons for a systems request. Try and find one not listed in the text.

  Question 1a for n 0 what is the time complexity of the

question 1a for n ? 0 what is the time complexity of the method q1 n. show the details of your calculation of oq1 n

  Write down a 2 page research paper excluding the title page

write a 2 page research paper excluding the title page on algorithm types summation product selection sort bubble sort

  Input a list of employee names and salaries and determine

input a list of employee names and salaries and determine the meanaverage salary as well as the number of salaries

  Consider that the size of the hash tab is m=16. apply linear

Consider that the size of the hastable is M=16. Apply linear probing with f(i)=i for the following keys. Convert each of the keys to a number associated with the sequence of English alphabet and then draw a table that indicates successful and unsucce..

  Develop an algorithm that will work with any combination

Given the above scenario, develop an algorithm (final design presented as a flow chart) that will work with any combination of items. Your algorithm shou4 generate some form of packing instructions for staff to follow, which should include at leas..

  Determine the average complexity of an enqueue

question suppose we implement a priority queue as a heap. assume the queue has thousands of elements. suppose further

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd