Month: March 2017

Recursive

Problem 1: Displaying Recursive Swirls
Review the solution to Programming Exercise 18.38 (Recursive tree) on Blackboard.
Then write a
program that will create recursive “swirls”. The user enters the order of the swirls and the number of
branches (straight lines) in each swirl. Swirls are recursively created at the end of each branch. The color
of each swirl is randomly chosen by the program.

You can accomplish this by having the paint method in your Pane class call a recursive
paintSwirl method:
paintSwirl(depth, getWidth() / 2, getHeight() / 2,
getHeight() / 4, Math.PI / 12);
<标题>The paintSwirl method that you

CPUTime

For this assignment, you will be writing a program determine the paths to connect all of the cities on a map.
You are to handin all files upon which your program is dependent, except RouterRunner.cpp, RouterRunner.h,
and CPUTimer.h. The grading script will copy those three files into your directory. You will find those three files, map
files, CreateFile.out, ElevationDiffs.out, barebones router.*, minimal Makefile, and my router.out. in ~ssdavis/60/p5.
Here are the specifications:
1. CreateFile.cpp is available and worth perusing.
1.1. The name of a data file reflects parameters used to create it. For example, map-20-1000-5.txt has 20 cities, a map
<标题>width and height of 1000, and was created using a seed of 5 for the r

Shell script

This is a group project (minimum 2 students, maximum 4 students in each group). The
project carries 50% of the overall grade. It is based on a practical demo (40%) and group
participations (10%).
The Task:
Based on the lab activities as well as external readings, each group needs to write a Bash
script that will implement menus using ‘dialog’ or any other utility. Create function for each
action, e.g., to show Calendar on screen create function show_calender( ). Menu-items and
action according to select menu-item are shown as follows:
Menu-Item
Purpose
Action for Menu-Item

Data analysis using matlab

Write a Matlab program performing the following operations:
1. Use the following parametrs values:
window_length = 128;
window type – hamming
overleap = 0 samples (no overleap between windows)
2. Read the rainm1.wav file as an input signal
3. Plot the time-domain waveform of input signal
4. Divide the signal into frames of length = 128 samples each. Multiply each frame by the
Hamming window and write the windowed frames into a matrix thus, that each row of this
matrix contains a single frame.
5. Analyse the signal by calculating the fft and amplitude spectrum of each frame.

Simple Maze Game

Download all starter files on our course website.
For this problem set, 80% of your mark is for completing a basic set of requirements (as
stated in part 1 and in the starter code file). The remaining 20% is for adding further
enhancements of your choosing (described in part 2).
Part 1. Base Requirements
For this problem set, you will be creating a simple maze game (as you may have guessed
from the creative title above).
The maze will be stored as a list of lists (called “grid” in your starter code).
Each sublist represents one row of the maze.
In the maze, the string (x) represents the player.
The string (

Arrays and C-Strings

(90 pts) Problem Statement: Go Bowling
You have just been tasked with writing the software for your local bowling alley. You must
simulate bowling with random numbers and make sure your software can keep score for
different players in a game.
If you are not familiar with bowling, then you can read these instructions on how to play the
game and keep score:
Our game can have 1-5 players, and it allows users to play again with a dif