Questions
Read an unsorted keywords file once to determine how many words are in the file. Allocate...

  1. Read an unsorted keywords file once to determine how many words are in the file.
  2. Allocate memory dynamically to store the unsorted keywords in an array of strings or an array of c-strings. (Hint: be sure to clear your input file stream before re-reading the file)
  3. Reread the keywords file a second time and store the words in the dynamically allocated array of strings or c-strings
  4. Sort the array of key words. (Hint: be sure to check your sorted array of key words - there should be 84)
  5. Search a C++ program input file for occurrences of the keywords:
    • Read one line at a time from the C++ program file into a cstring. (Hint: use the istream::getline function - see example below)
    • Parse each line into separate words. Ignore any words that are inside a C++-style comment. (Hint: use strtok)
    • Search the keyword array to determine if each word is a keyword (Hint: use a binary search or a sequential search)
    • For keywords, print the line number, the keyword, and the position of the keyword in the line. (Hint: use the difference of two pointers)
    • Keep a count of the number of keywords found

Program Requirements

  • This zipped file(http://voyager.deanza.edu/~bentley/cis22b/ass4files.zip) contains the keywords file and the C++ program file for searching.
  • Use a char array to hold each line from the C++ program file. “Parse” each line into individual words for searching. Note, you may not use the stringstream classes for this assignment.
  • Make sure you check the input file for successful opens.
  • Your output should match the format show below with the correct line number and position of each word in the line. The line character positions start at zero. Note, there are more than 50 lines of output.

Program Output

Your output should look like this:

Line 8: using(0) namespace(6)   <== using occurs at position 0 on line 8, namespace occurs at position 6 on line 8
Line 10: const(0) int(6)
Line 12: void(0) const(19)
Line 13: void(0) char(20) int(32) const(48)
Line 14: bool(0) const(24) char(30) const(42)
Line 15: void(0) char(17)
Line 16: void(0)
Line 17: void(0)
Line 19: int(0)
Line 21: const(4)
...
Number of keywords found = ??   <== Add this line at the end of your output, replace ?? with the correct number

Program Hints

  • Follow the program steps. Write only one part of the program at a time. Test each part before you proceed to the next step. Do not continue if one part has a problem. Ask for help with a step, if you can't get it to work. Remember to allow plenty of time for this assignment.
  • Use a small keyword file and a small test C++ program file initially as you are developing your code.
  • Use strstr() to find the // of a C++-style comment.
  • Use strtok() for the parsing of each line. You should "parse out" much of the program "punctuation".
  • You might want to make a copy of each line (maybe as a string) to determine the position of the keyword in the line. This is because strtok() destroys the original line.
  • Xcode users: There is a \r at the end of each line in the test file. You can suppress it by adding "\r" as a delimiter for strtok().
  • Your program should produce more than 50 lines of output and you should find more than 70 keywords (many are repeats).

The keyword file looks like this:

for
if
nullptr
break
int
long
sizeof
return
short
else
friend
const
static_cast
...

The C++ program file looks like this:

#include <cstdlib>
#include <cstring>
#include <cctype>
#include <cmath>
#include <fstream>
#include <iostream>
#include <string>
using namespace std;

const int DictionarySize = 23907;

void getDictionary(const string& filename,string*);
void spellCheckLine(char* line, int lineNumber, const string* dictionary);
bool wordIsInDictionary(const char* word, const string* dictionary);
void toLowerCase(char* text);
...


istream::getline example

ifstream fin("oldass3.cpp");
...
char buffer[132];
...
fin.getline(buffer,sizeof(buffer)); // store a line from the input file into buffer

In: Computer Science

Read an unsorted keywords file once to determine how many words are in the file. Allocate...

  1. Read an unsorted keywords file once to determine how many words are in the file.
  2. Allocate memory dynamically to store the unsorted keywords in an array of strings or an array of c-strings. (Hint: be sure to clear your input file stream before re-reading the file)
  3. Reread the keywords file a second time and store the words in the dynamically allocated array of strings or c-strings
  4. Sort the array of key words. (Hint: be sure to check your sorted array of key words - there should be 84)
  5. Search a C++ program input file for occurrences of the keywords:
    • Read one line at a time from the C++ program file into a cstring. (Hint: use the istream::getline function - see example below)
    • Parse each line into separate words. Ignore any words that are inside a C++-style comment. (Hint: use strtok)
    • Search the keyword array to determine if each word is a keyword (Hint: use a binary search or a sequential search)
    • For keywords, print the line number, the keyword, and the position of the keyword in the line. (Hint: use the difference of two pointers)
    • Keep a count of the number of keywords found

Program Requirements

  • This zipped file(http://voyager.deanza.edu/~bentley/cis22b/ass4files.zip) contains the keywords file and the C++ program file for searching.
  • Use a char array to hold each line from the C++ program file. “Parse” each line into individual words for searching. Note, you may not use the stringstream classes for this assignment.
  • Make sure you check the input file for successful opens.
  • Your output should match the format show below with the correct line number and position of each word in the line. The line character positions start at zero. Note, there are more than 50 lines of output.

Program Output

Your output should look like this:

Line 8: using(0) namespace(6)   <== using occurs at position 0 on line 8, namespace occurs at position 6 on line 8
Line 10: const(0) int(6)
Line 12: void(0) const(19)
Line 13: void(0) char(20) int(32) const(48)
Line 14: bool(0) const(24) char(30) const(42)
Line 15: void(0) char(17)
Line 16: void(0)
Line 17: void(0)
Line 19: int(0)
Line 21: const(4)
...
Number of keywords found = ??   <== Add this line at the end of your output, replace ?? with the correct number

Program Hints

  • Follow the program steps. Write only one part of the program at a time. Test each part before you proceed to the next step. Do not continue if one part has a problem. Ask for help with a step, if you can't get it to work. Remember to allow plenty of time for this assignment.
  • Use a small keyword file and a small test C++ program file initially as you are developing your code.
  • Use strstr() to find the // of a C++-style comment.
  • Use strtok() for the parsing of each line. You should "parse out" much of the program "punctuation".
  • You might want to make a copy of each line (maybe as a string) to determine the position of the keyword in the line. This is because strtok() destroys the original line.
  • Xcode users: There is a \r at the end of each line in the test file. You can suppress it by adding "\r" as a delimiter for strtok().
  • Your program should produce more than 50 lines of output and you should find more than 70 keywords (many are repeats).

The keyword file looks like this:

for
if
nullptr
break
int
long
sizeof
return
short
else
friend
const
static_cast
...

The C++ program file looks like this:

#include <cstdlib>
#include <cstring>
#include <cctype>
#include <cmath>
#include <fstream>
#include <iostream>
#include <string>
using namespace std;

const int DictionarySize = 23907;

void getDictionary(const string& filename,string*);
void spellCheckLine(char* line, int lineNumber, const string* dictionary);
bool wordIsInDictionary(const char* word, const string* dictionary);
void toLowerCase(char* text);
...


istream::getline example

ifstream fin("oldass3.cpp");
...
char buffer[132];
...
fin.getline(buffer,sizeof(buffer)); // store a line from the input file into buffer

In: Computer Science

1. What is the definition of an eigenvalue and eigenvector of a matrix? 2. Consider the...

1. What is the definition of an eigenvalue and eigenvector of a matrix?

2. Consider the nonhomogeneous equationy′′(t) +y′(t)−6y(t) = 6e2t.

(a)Find the general solution yh(t)of the corresponding homogeneous problem.

(b)Find any particular solution yp(t)of the nonhomogeneous problem using the method of undetermined Coefficients.

c)Find any particular solution yp(t)of the nonhomogeneous problem using the method of variation of Parameters.

(d) What is the general solution of the differential equation?

3. Consider the nonhomogeneous equationy′′(t) + 9y(t) =9cos(3t).

(a)Findt he general solution yh(t)of the corresponding homogeneous problem.(b)Find any particular solution yp(t)of the nonhomogeneous problem.(c) What is the general solution of the differential equation?

4. Determine whether the following statements are TRUE or FALSE.Note: you must write the entire word TRUE or FALSE. You do not need to show your work for this problem.(

a)yp(t) =Acos(t)+Bsin(t)is a suitable guess for the particular solution ofy′′+y= cos(t).(

b)yp(t) =Atetis a suitable guess for the particular solution ofy′′−y=et.

(c)yp(t) =Ae−t2is a suitable guess for the particular solution ofy′′+y=e−t2.(d) The phase portrait of any solution ofy′′+y′+y= 0is a stable spiral.

5. Consider the matrixA=[−2 0 0,0 0 0,0 0−2].(

a) Find theeigenvaluesofA.

(b) Find theeigenvectorsofA.

(c) Does the set of all the eigenvectorsofAform a basis ofR3?

6. Consider the system of differential equationsx′(t) =−2x+y,y′(t) =−5x+ 4y.

a) Write the system in the form~x′=A~x.

b) Find the eigenvalues of.

c) Find theeigenvectorsofA.

d) Find the general solution of this system.

e) Sketch the phase portrait of the system. Label your graphs.

7. Determine whether the following statements are TRUE or FALSE. You must write the entire word “TRUE” or “FALSE’’. You do not need to show your work for this problem.

a) If|A|6= 0 then A does not have a zero eigenvalue.

(b) IfA=[4 2,0 4]then the solution ofx′=Axhas a generalized eigenvector of A.

(c) LetA=[−1 4 0,0 3 3,1 0−2].The sum of the eigenvalues of A is 18.

(d) Let x′=Ax be a 2x2 system. If one of the eigenvalues of A is negative, the stability structure of the equilibrium solution of this system cannot be a stable spiral.

8. Below (next page) are four matrices corresponding to the 2x2 system of equations x′=Ax,where x= (x1, x2). Match each of the four systems (1)–(4) with its corresponding vector field, one of the four plots (A)–(D), on the next page. You do not need to show your work for this problem.

A=[0 1,1−1]

A=[0−1,1 0]

A=[1 2,−2 1]

A=[−1 0,−1−1]

In: Advanced Math

AMP has suffered a first strike on its remuneration report after coming under fire from shareholders...

AMP has suffered a first strike on its remuneration report after coming under fire from shareholders and proxy advisers over the “disproportionately large” incentives paid to its executives. At the company’s virtual annual general meeting on Friday, 67 per cent of proxies voted against the remuneration report. It comes after influential proxy advisers Ownership Matters and ISS recommended shareholders vote against the generous pay packages. Both proxy advisers last month argued that executive pay was overly generous and performance hurdles not rigorous enough. If the company receives a second strike next year, it will trigger a board spill under the ‘two-strikes’ rule. Commenting on the executive remuneration plan, Mr Murray [Chair of the Board] said the generous package was required to attract and retain an executive team that could execute the company’s transformation strategy. “The 2019 remuneration structure was designed to reflect the scale, complexity and challenges involved in transforming the business … executing an ambitious strategy, separating the life insurance business, completing client remediation and addressing the company’s challenging regulatory and legal matters. “In our CEO and executives, we have a capable and driven team to deliver our plan. Their awards are substantial, but the hurdles are challenging. For the awards to be realised over the long term, these demanding hurdles must first be achieved, including a significant improvement in business performance and share price,” Mr Murray said. Taking aim at the two-strike rule, which sees a board spill if more than 25 per cent of shareholders vote against a company’s remuneration report two years in a row, Mr Murray warned it reduced the incentive for companies to “properly invest in specialist care, ultimately leaving the more difficult workouts to the unlisted markets”. AMP chief executive Francesco De Ferrari’s pay package came in at $13.43m last year, buoyed by share rights, options and restricted shares, even as the under-pressure wealth group posted losses of $2.5bn. Mr De Ferrari’s remuneration for the 12 months ended December 31 included a $2.18m base salary, $1.32m cash bonus, other short-term benefits of $1.71m and almost $8.2m in rights, options, and restricted shares. Extract from Grieve, C. Shareholders hit AMP with first strike against executive pay packets. The Australian. 8 May 2020. Required: From the information provided: a) Do you think that remuneration incentives are working in the way intended under agency theory for AMP Ltd? Why or why not? (Maximum word limit 500 words) b) How might earning management be relevant to remuneration incentives? Explain. (maximum word limit 250 words) (4 m

In: Accounting

Researchers claim that women speak significantly more words per day than men. One estimate is that...

Researchers claim that women speak significantly more words per day than men. One estimate is that a woman uses about 20,000 words per day while a man uses about 7,000 . To investigate such claims, one study used a special device to record the conversations of male and female university students over a four‑day period. From these recordings, the daily word count of the 2020 men in the study was determined. The table contains their daily word counts.

28,408 10,084 15,931 21,688 37,786
10,575 12,880 11,071 17,799 13,182
8,918 6,495 8,153 7,015 4,429
10,054 3,998 12,639 10,974 5,255

(a) Use the software of your choice to make a histogram of the data. What value should we remove from the data to make it reasonable to use the t procedures (assume these men are an SRS of all male students at this university)?

value to remove:

(b) With this value removed, carry out a test of significance to determine if the mean number of words per day of men at this university differs from 7000. (If you're using CrunchIt for your calculations, adjust the default precision under Preferences as necessary. See the instructional video on how to adjust precision settings.)

Choose the correct hypotheses to test.

H0:μ=7000 versus H0:μ>7000

H0:μ≠7000H0 versus H0:μ=7000H0

H0:μ<7000H0 versus H0:μ≠7000H0

H0:μ=7000H0 versus H0:μ≠7000H0

With the value removed, find ¯x . (Enter your answer rounded to two decimal places.)

x¯=

With the value removed, find s . (Enter your answer rounded to three decimal places.)

s=

With the value removed, find t . (Enter your answer rounded to three decimal places.)

t=

Using the software of your choice, find the P‑value. (Enter your answer rounded to four decimal places.)

P=

What conclusion can we make from this data? Choose the correct answer.

A.There is no evidence that the mean number of words per day of men at this university differs from 7000 The sample mean indicates they speak less than 7000 words per day.

B.There is overwhelming evidence that the mean number of words per day of men at this university differs from 7000The sample mean indicates they speak more than 7000 words per day.

C.There is overwhelming evidence that the mean number of words per day of men at this university differs from 7000The sample mean indicates they speak less than 7000 words per day.

D.There is no evidence that the mean number of words per day of men at this university differs from 7000The sample mean indicates they speak more than 7000 words per day.

In: Statistics and Probability

Research Designs Researchers were interested in learning the effects of trans fats on levels of cholesterol...

Research Designs

Researchers were interested in learning the effects of trans fats on levels of cholesterol in the blood. Two different research designs were constructed.

Part I: Between-Groups Design

In the between-groups design, researchers were interested in whether cholesterol levels would differ depending on diet. Twenty participants were randomly assigned to one of two different groups. Group A was assigned a diet rich in fruits and vegetables and with no trans fats. Group B participants were asked to follow their normal diets, which contained varying levels of trans fats depending on the individual. After one month, blood samples were drawn and the following levels of cholesterol were obtained:

Participant

Blood Cholesterol

Diet

1

129

Healthy

2

98

Healthy

3

150

Healthy

4

75

Healthy

5

135

Healthy

6

175

Healthy

7

115

Healthy

8

103

Healthy

9

156

Healthy

10

143

Healthy

11

239

Normal

12

500

Normal

13

350

Normal

14

468

Normal

15

198

Normal

16

213

Normal

17

225

Normal

18

175

Normal

19

560

Normal

20

289

Normal

In 2 to 3 sentences in a Microsoft Word document, answer the following questions:

What is the independent variable in this study?

What are the levels of that independent variable?

What is the dependent variable?

Submission Details:

Name this document SU_PSY2008_W5_A_LastName_FirstInitial

Create a data file that will enable you to conduct a between-groups analysis of this data.

Name your worksheet SU_PSY2008_W5_A_worksheet_LastName_FirstInitial

Part II: Within-Subjects Design

In the within-subjects design, researchers were interested in whether participants could lower their cholesterol levels by changing from a diet higher in trans fats to one with no trans fats. Ten research participants were selected. A baseline measure of cholesterol was taken from each. They were then put on a diet rich in fruits and vegetables and devoid of trans fats for one month. At the end of that month, blood cholesterol was again measured and the following results were obtained:

Participant

Blood Cholesterol

Diet

1

129

Baseline

1

98

Healthy

2

150

Baseline

2

75

Healthy

3

175

Baseline

3

135

Healthy

4

115

Baseline

4

103

Healthy

5

156

Baseline

5

143

Healthy

6

500

Baseline

6

450

Healthy

7

468

Baseline

7

350

Healthy

8

198

Baseline

8

213

Healthy

9

225

Baseline

9

175

Healthy

10

560

Baseline

10

481

Healthy


In 2 to 3 sentences in a Microsoft Word document, answer the following questions:

What is the independent variable in this study?

What are the levels of that independent variable?

What is the dependent variable?

In: Statistics and Probability

The management of Bar.Co have asked for your assistance in deciding whether to continue manufacturing a...

The management of Bar.Co have asked for your assistance in deciding whether to continue manufacturing a component or buy it from an outside supplier. The component in question is the Sicio that is used as a component on many of the finished products produced by Bar.Co. You have been provided with the following information: 

Bar.Co’s normal annual requirement is for 5,000 Sicios per year. 

Bar.Co’s purchasing department has asked external suppliers to quote for the supply of Sicios. The lowest quotation they have received is for a price of £10 per Sicio for a supply of between 4,000 and 6,000 Sicios per year. 

Sicios are currently manufactured by Bar.Co’s precision engineering department, using specialised machinery. If Sicios are purchased from outside this machinery, which is in the last year of its useful life and not in a condition to be sold, will be scraped at a cost of £200. The net book value of this machinery is £1,000. 

The costs of the precision engineering department, including those associated with the manufacturing of Sicios are estimated to be:

   £

Direct materials    67,500

Direct labour 50,000

Indirect labour 26,500

Light and heat 5,500

Power    3,000

Depreciation (specialised machinery) 1,000

Depreciation (other machinery) 9,000

Other fixed departmental overheads 5,000

The cost accountant of Bar.Co has estimated that the cost of manufacturing Sicios by the precision engineering department is £16.50 per Sicio made up as follows:

   £

Direct materials    3.50

Direct labour 5.60

Departmental overheads    4.60

Company overheads 2.80

The departmental overheads and the company overheads are not specific to Sicio and have been allocated to the component based on direct labour cost.


 The impact on the precision engineering department of ceasing to produce Sicios internally, other than the savings in direct costs specifically associated with manufacturing Sicios, is estimated to be:

Savings of £6,500 in indirect labour; savings of £1,000 in light and heat costs. No savings are expected for power costs and depreciation of other machinery;

An increase in other departmental fixed overheads of £4,000 because of increased activity in goods reception and inspection.

Based on this information the cost accountant is in favour of discontinuing the in-house manufacturing of Sicios.

Required:

a) Prepare a report that identifies, showing any necessary calculations, the total cost for the precision engineering department when Sicios are produced in-house and when they are purchased from an outside supplier, highlighting any difference in each cost item. You are also required to provide your advice regarding the proposed change in the sourcing of Sicios.

b) Discuss any non-financial issues you think should be taken into account in making this decision. Word limit: 400 words.

c) When a business seeks to understand what costs are relevant for a decision, it may have to identify sunk costs and opportunity costs. Explain what you understand by relevant costs, sunk costs and opportunity costs, providing examples. Word limit: 400 words.

In: Accounting

Variables typically included in a multivariate demand function (other than the price and quantity of the...

Variables typically included in a multivariate demand function (other than the price and quantity of the item the demand function represents) are consumer tastes and preferences, the number of buyers, spendable (disposable) income, prices of substitute goods, prices of complementary goods, advertising expenditures, weather, and expectations. Recalling that the price of the item being considered is placed on the vertical axis, and the quantity on the horizontal axis, the other variables are termed demand shifters. Please answer the following questions about the affect changes in other variables might have on the demand for the item. These changes will either cause demand to increase (shift right) or decrease (shift left). Use either word as applicable, for the short answer.

  1. If the demand for a specific brand of a good (for which many substitutes exist) decreases and there is no decrease in the demand for this type of good, then the demand for a substitute _____________ .



  1. If the number of potential consumers for the good being considered decreases, then the demand for the good being considered likely:



  1. If the demand for Lattes increases, then the demand for biscotti (a complementary good) should:


  1. Suppose new antioxidant properties for broccoli are discovered. Antioxidant properties supposedly help prevent cancer. As a result of this discovery, the demand for broccoli can be expected to:


5. The Organic Light Emitting Diode (OLED) is a new and promising display technology. It promises to permit display screens to be thin, flexible, and bright. It is currently available only in small size. This technology works somewhat like a firefly, utilizing electroluminescence. However its competitor, the Liquid Crystal Display (LCD), can now be produced as one piece panels up to six feet tall. The OLED is its own light source, requiring no backlighting as does a LCD. Assuming the LCD and OLED have the same sized screen, future demand for the older LCD display can probably be expected to __________ .

Variables typically included in a multivariate supply function (other than the price and quantity of the item the supply function represents) are prices of other goods that use similar input resources for production, the number of suppliers, techniques of production, taxes and subsidies, prices of input resources, weather, and expectations. Please answer the following questions about the affect changes in other variables might have on the supply of the item. These changes will either cause supply to increase (shift right) or decrease (shift left). Use either word as applicable, for the short answer.

  1. If the market price of gasoline returns to the near $4.00 per gallon level then demand for gas-gulping large autos is likely to decrease and manufacturers of these autos are likely to _____________ their supply:


  1. A relative increase in the productivity of the technology used to produce the item being considered is likely to _____________________ its supply.


  1. Hailstorms have pelted south central Texas grape vineyards, spoiling acres of grapes. This is likely to ______________ the supply of grapes for Texas wine.

  1. A manufacturer, operating with a fixed production budget, discovers that the cost of input resources is increasing. The manufacturer is likely to ___________________ the quantity of the product produced.


  1. The six-spotted evil weevil has attacked California’s broccoli crops. Their supply of broccoli is thus likely to:

In: Economics

Background You are the owner of AAA Landscaping, a small company in Orlando, Florida, that specializes...

Background

You are the owner of AAA Landscaping, a small company in Orlando, Florida, that specializes in resodding and maintenance of lawns. Much of your business is through word-of-mouth advertising. Once a contract is negotiated, portions of it are subcontracted out to other companies (e.g., sprinkler system repair and pesticide services). Recently, you went to the home of Stu Murphy to bid on resodding his lawn. He obtained several other bids, but yours was the lowest. You arranged for work to begin to remove old grass and replace it with the St. Augustine grass sod that he requested. As part of the contract, Stu also asked that some basic maintenance be done (e.g., hedge and tree trimming, hauling away of old decorative wooden logs from around flower beds, and general sprucing up of the front area of the house). In addition, fertilizer and pesticide were to be applied within two weeks. Stu signed the contract on Wednesday and the work was to be completed by Saturday, when he had planned a party.

Your Role

You were pleased to get the contract, worth over S 1,200. This is actually the third or fourth contract in the same subdivision because of word-of-mouth advertising. Your employees completed the initial sod removal and replacement, weeding, and pruning on Friday, and you received full payment on Monday. You received a call from Stu on Tuesday afternoon stating that several trees were not trimmed to his satisfaction, debris covering decorative

rocks along hedges was not removed as agreed, and bags of clippings had been left behind. Because of other commitments, it was only on Friday that you sent someone out to finish the job. On Saturday, Stu left another message on your answering machine stating that there was still an untrimmed tree, the debris remained, and the clippings were still in the side yard. You did not get around to returning his call. Stu called again Monday, repeating the message he had left before and reminding you that the contract called for pesticide and fertilizer to be

applied to the lawn. You called back and said that someone would be out the next day. Again, other commitments kept you from following through. Stu called on Wednesday and left a fourth message on your answering machine. He said that he was getting irritated at not getting callbacks and action on his needs. Without returning Stu's call, you responded by sending someone out on Thursday to take care of the outstanding work. It has been several days since the work was completed, and you assume that Stu is now satisfied since you have heard nothing else from him.

Critical Thinking Questions

1. Based on information in this chapter, how have you done on providing service to Stu? Explain.

2. What were Stu's needs in this case?

3. Could you have done anything differently?

4. Are you sure that Stu will give a good recommendation to neighbors or friends in the future? Why or why not?

In: Operations Management

Variables typically included in a multivariate demand function (other than the price and quantity of the...

Variables typically included in a multivariate demand function (other than the price and quantity of the item the demand function represents) are consumer tastes and preferences, the number of buyers, spendable (disposable) income, prices of substitute goods, prices of complementary goods, advertising expenditures, weather, and expectations. Recalling that the price of the item being considered is placed on the vertical axis, and the quantity on the horizontal axis, the other variables are termed demand shifters. Please answer the following questions about the affect changes in other variables might have on the demand for the item. These changes will either cause demand to increase (shift right) or decrease (shift left). Use either word as applicable, for the short answer.

1. In an effort to reduce congestion in central London, vehicle owners must now purchase expensive passes to drive there. As a result, the demand for public transportation (busses, the tube) _________ .

2.   When the price of gasoline broke the magic $4.00 per gal, makers of large vehicles suddenly faced a ___________ demand for them.

3.   Automobiles are an example of a normal good. This designation means that as per capita income increases, the demand for automobiles ______________.

4. Recently an outbreak of E.coli (which causes intestinal distress, liver damage, and sometimes death) was attributed to contaminated Romaine lettuce grown in Yuma, Arizona.   As a result, the demand for other varieties of lettuce (not infected by the virus) ________________.

5.   If research ever shows conclusively that increased cell phone use is linked to the increased incidence of brain tumors, then the demand for cell phone might ______________ .

Variables typically included in a multivariate supply function (other than the price and quantity of the item the supply function represents) are prices of other goods that use similar input resources for production, expectations, the number of suppliers, techniques of production, taxes and subsidies, and prices of input resources, weather. Please answer the following questions about the affect changes in other variables might have on the supply of the item. These changes will either cause supply to increase (shift right) or decrease (shift left). Use either word as applicable, for the short answer.

1. The production of Ethanol is being significantly subsidized by increasing the tax on “real gas” (which contains no Ethanol). Therefore, land devoted to growing corn is increasing and that devoted to growing wheat is decreasing. Thus it is likely that the supply of wheat will ______________.

2. Productivity is a key variable in the supply of items. An increase in productivity translates into a ____________ in the supply of the items.

3. Jet fuel prices are soaring. Therefore an economist would not be surprised to learn that airlines are _________________ the number of planes they are flying, hoping to more completely fill the remaining flights.

4. American automobile manufactures are responding to the increased demand for SUV and Crossover styles by ____________ the supply of them and ________________ the supply of unpopular Sedan styles..

5. Think of highways as a resource used in the production of highway transportation. Thus building more and better highways is likely to _______________ the supply of vehicles using them.

In: Economics