Define the objects and their functions

Assignment Help Computer Engineering
Reference no: EM132109296

Project Intercept

You need c++ code for this please!!!!!

The client wants a simulation of a target and a weapon launcher and intercept projectile.

1. The Launcher will fire a projectile at a target the Launcher is static, the projectile follows a linear path. The projectile has a known velocity (speed and direction).

2. The Target will be traveling in a circular path, with a given center and radius. The Target has a known speed.

3. Launcher and Target will be given known initial positions.

4. The Launcher will fire the projectile in an appropriate direction so to intercept the Target at some time t.

Objects:

Target, Launcher and Projectile.

The Target has:

initial position, current position, trajectory (center, radius and speed)

The Target has functions:

Constructor, destructor, display, associated gets/sets, move().

The Launcher has:

initial position, projectile, targeting information (ref angle)

Constructor, destructor, display, gets/sets, fire()

The Projectile has

initial position = Launcher position, velocity and a linear trajectory

Constructor, destructor, display, associated gets/sets, move().

Final Comments. After initialization, the launcher will compute the ideal ref angle and fire the projectile.

The projectile will travel a set distance each time step = speed of the projectile.

The Target will move along the circular path at each time step a distance = speed of the target

At time T, the project will intercept the Target and destroy it.

1. design the tests for each of the objects

correctly passing when it should, and fail when it should not pass

2. define the objects and their functions

3. design the algorithm to solve the problem:

---------------------------------------------------Al Gores' Rhythm-------------------------------------

1. compute the new position of the target on the circle, Tx, Ty (spd = arc length on circle)

a) given Target's current position Tx,Ty, compute initial reference angle theta

b) compute the circumference of the path of the target, C = 2PI*R

c) the reference angle for the target per time step, how far is it moving in one time unit then is 360*Spd/C = alpha

theta = theta - alpha

d) dx = r sin(theta), dy = r cos(theta)

2. compute the equation of the line from Launcher (Lx, Ly) to Target (Tx, Ty)

a) find slope m = (Ty-Ly)/(Tx-Lx)

b) use slope m and either Tx,Ty or Lx,Ly to find b --> yielding y = mx + b

3. using y = mx+b and speed of projectile and the number of time steps to find the Px,Py

4. find the distance from Px,Py to Tx, Ty....yielding impact or go again.

Reference no: EM132109296

Questions Cloud

Implement the id3 algorithm to classify adults : Each line of the file looks like this: workclass, education, marital-status, occupation, relationship, race, sex, native-country, class-label.
What exactly is a configuration change management policy : What exactly is a configuration change management policy, and how should you address this for my project?
Develop for the operational manager of the indicated firm : ITECH1103- Big Data and Analytics - ANALYTIC REPORT - Write a description of the selected dataset and project, and its importance for the firm.
Build a gui that facilitates playing one round : Build a GUI (graphical user interface) that facilitates playing one round (13 hands).
Define the objects and their functions : The Launcher will fire a projectile at a target the Launcher is static, the projectile follows a linear path. The projectile has a known velocity.
Create a predator-prey simulation in a 2-d ecosystem : Create a Predator-Prey Simulation in a two-dimensional ecosystem based on agent-based modeling. The Predator and Prey will act as agents in an ecosystem in this
Design and implement a class for double link list : All member function and operator prototypes are declared in xArray.h, with necessary comments before each function.
Create a java application that grades a multiple choice quiz : Prompt the user to enter the number of questions for the quiz, then prompt the user to enter the answer key for each question. Use an array.
Create an inventory database for a manufacturing facility : This project asks to create an inventory database for a manufacturing facility in Access. You are free to create whatever type of facility you would like.

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