Write a program that opens a plotting grid window

Assignment Help Computer Engineering
Reference no: EM132210432

Question :

Write a program that opens a plotting grid window (labeled Lake Matlab) with its axis set to [-11 11 11 11 and the plots a circle of radius 10 with a black point style line.

This will represent the lake in which the boats can move about. Generate randomly (and save the coordinates of eight boats within this lake Repeatedly do the following 40 times:

1. Plot the boats (as diamond points with the following color requirements:

a) A boat whose distance is more than the square root of two from all other boats and whose distance is more than one from all lake boundary (shore) is Green

b) A boat whose distance is more than the square root of two from all other boats but whose distance is one or less from the lake boundary (shore is Magenta

c) A boat whose distance is exactly the square root of two or one from any other boat is Yellow

d) A boat whose distance is exactly zero from any other boat is Red (collision)

2. Delay for 0.5 second.

3. Move each boat on the lake by repeatedly modifying both the x-coord and y-coord by adding a randomly generated Integer in the range [-1, ij, until you have new values for x-coord and y- coord that does not put the boat on the shore.

Reference no: EM132210432

Questions Cloud

What amenities and facilities are important to include : What amenities and facilities are important to include? What considerations need to be attended to as the suburbs grow? (should suburbs even be encouraged)
Write a critical evaluation of the article : Using the University Digital Library or the Google scholar website, locate a peer reviewed article about privacy. Write a critical evaluation of the article.
Which aspects of the roman built environment were borrowed : What is the relationship between ancient Roman architecture and ancient Greek architecture? Using at least three buildings explain which aspects.
Write a program in the language of your choice : Write a program in the language of your choice (prefer C or Java) that will simulate process scheduling
Write a program that opens a plotting grid window : Write a program that opens a plotting grid window (labeled Lake Matlab) with its axis set to [-11 11 11 11 and the plots a circle of radius.
What step can leadership team take to ensure full compliance : You all work in or know of people who work in enterprise IT environments Maintaining the enterprise security posture, legal risk, and security is constantly.
Collect a message from the user and writes it out again : Write a main function (Method,Procedure) that collects a message from the user and writes it out again.
Describe the printmaking method used : Both Albrecht Durer and Rembrandt made numerous prints. See if you can find 3 different PRINT made by one of these artists on the web and upload the jpg image.
Write a program to model a simple calculator : Write a program to model a simple calculator. Each data line should consist of the next operation to be preformed from the list below and the right operand.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

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