### Create a StudySoup account

#### Be part of our community, it's free to join!

Already have a StudySoup account? Login here

# Note for Math 364 with Professor Krishnamoorthy at WSU 04

### View Full Document

## 11

## 0

## Popular in Course

## Popular in Department

This 1 page Class Notes was uploaded by an elite notetaker on Friday February 6, 2015. The Class Notes belongs to a course at Washington State University taught by a professor in Fall. Since its upload, it has received 11 views.

## Similar to Course at WSU

## Popular in Subject

## Reviews for Note for Math 364 with Professor Krishnamoorthy at WSU 04

### What is Karma?

#### Karma is the currency of StudySoup.

#### You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 02/06/15

Math364 March 22 2005 l AMPL Further Tips 1 Notice that sum j in 1n Xj is the same as sum k in 1n XEk Similarly sum 1 in 1 2 j in 1 3 5 gives 30 ie we just add the number 5 for each value of i and j 7 thus adding the same number 2 X 3 6 times 2 The model should be as generic abstract as possible For example in the Leary Chemicals problem 3 in HW 6 you could declare a parameter for the number of products made AB and C apart from the number of processes 1 and 2 In this way the Yield can be declared as a matrix parameter as opposed to declaring one vector parameter for each product separately Thus you could say param nProd No of products 3 for ABC param nProc No of processes 2 for process1 and process2 param Yield 1 in 1nProd j in 1nProc param Demand 1 in 1 nProd The demand constraints for all three products can be written in a single line here Notice how we use two di erent index sets using indices j and i for obtaining the sum of the term Yield 1 jxj and to repeat the constraint for each element in the set 1 nProd subject to DemCon i in 1 nProd sum j in 1nProc Yieldijxj gt DemandEi Equivalently you could declare a set of products and a set of processes 3 You should avoid including actual parameter values when writing constraints in the model le For example some of you have written the worstcase return constraint from the Solodrex problem 4 in HW 6 as follows subject to MinWorstRet sum j in Bonds WCRet j x j gt sum j in Bonds XEj 8 The quantity 8 should be declared as a parameter say minWCret and initialized appropriately in the data le When writing the constraint in the model le you should use the name of the parameter rather than its actual value The same rule applies to the average return and other similar constraints subject to Min7Worst7Ret sum j in Bonds Wci et jxj gt sum j in Bonds XjminWCret 4 The idea of multiple indices or indexing sets can be used to write all in diversi cation constraints in one line subject to Diversify i in Bonds xi lt sum j in Bonds xjDiversifyPercent where DiversifyPercent is the parameter set at 04 5 Several of you seemed to have struggled with Problem 5 from HW 6 Here is a brief outline of the model le param nicakes No of cakes 2 1 W CC 2 W BF param nimonths No of months 3 param Demand i in 1 nicakes j in 1 nimonths demand for both cakes for all 3 months param Cost i in 1ncakes j in 1nmonths cost for both cakes for all 3 months param Hold7Cost i in 1 nicakes holding cost for each cake same for all months param MonthiBakeiLimit max No of cakes baked in a month var x i in 1ncakes j in 1nmonths gt 0 it No of cakes of each type baked in each month var s i in 1ncakes j in 0nmonths gt 0 it No of cakes of each type held in inventory M Notice that we declare the variable 5 for each cake for month 0 too i and it set these si0 values to 0 These dummy variables help us to write the constraints it in a nice way minimize TotaLCost sum i in 1ncakes j in 1nmonths Cost ijxij HoldCost isij W Note here that the same value of HoldCost i is used for each value of the index j subject to SetDummyToZero i in 1ncakes si0 0 subject to MaxiBake j in 1 nimonths sum i in 1 nicakes Xij lt MonthiBakeiLimit subject to InviBalance i in 1ncakes j in 1nmonths sij xij sij1 Demandij

### BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.

### You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

## Why people love StudySoup

#### "There's no way I would have passed my Organic Chemistry class this semester without the notes and study guides I got from StudySoup."

#### "I signed up to be an Elite Notetaker with 2 of my sorority sisters this semester. We just posted our notes weekly and were each making over $600 per month. I LOVE StudySoup!"

#### "Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

#### "Their 'Elite Notetakers' are making over $1,200/month in sales by creating high quality content that helps their classmates in a time of need."

### Refund Policy

#### STUDYSOUP CANCELLATION POLICY

All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email support@studysoup.com

#### STUDYSOUP REFUND POLICY

StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here: support@studysoup.com

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to support@studysoup.com

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.