Jump to content

Need help from some smart math people

wasab
Go to solution Solved by Dash Lambda,

Wow. I saw 18 replies and figured it was answered, but it turns out it... Very, very much was not.

 

OP, that excerpt is essentially introducing the idea of maximizing productivity.

 

You have a set of tasks ("requests") that occur over a specified interval of time, and two intervals are compatible if the times don't overlap, meaning that only one thing can be happening at a time. So the interval 1:00-4:00 is compatible with the interval 5:00-6:00, but it's not compatible with the interval 2:00-5:00, because that overlaps.

 

You are given a set of tasks that each have their own time interval, and your goal is to do as many of those tasks as you can without doing more than one of them at once. Like scheduling in as many parties as you can in a weekend -You can't choose when they happen, you can only choose which ones to go to.

Continuing with that analogy, let's say there are 6 parties happening in one day back-to-back, and there's one that's happening for the entire day. That one party overlaps with all the others, so you can either choose to go to that one party or the 6 others -Of which you would choose the 6, because you're trying to get as many in as possible.

 

I don't usually do those sort of heavily abstracted "let's make this relatable!" examples... It just sort of happened...

 

Continuing on with the excerpt, it says to sort the set of tasks in order of increasing finish time (it says "nondescending" because multiple tasks can finish at the same time). So a set of intervals like {1-4, 2-3, 5-8, 3-7} would be sorted as {2-3, 1-4, 3-7, 5-8}. Then is says for the element j from that set, p(j) is the latest element before it that doesn't overlap. So p(5-8) would be 1-4, and p(3-7) would be 2-3. p(j) is 0 if there isn't an interval that doesn't overlap.

 

Then it says you have an optimal solution O, meaning the biggest set of compatible tasks you can make. If the last element in the set, which we'll call n (5-8 from the one above), is in O, then you know that nothing after p(n) (1-4 from above) is in O because the point of the p(n) function is that everything after it overlaps with n, and therefore can't be in the solution with n.

 

So then let's say you remove everything after p(n) from the problem (giving you {2-3, 1-4}, again from above). Since O was an optimal solution, and you removed both n and everything that could have replaced n, what's left of O is still an optimal solution.

 

@BetterThanLife
I take great issue with your sentiment. There are many paths in life that don't require higher education, many of them where going through college for it can even be a detriment, but there are still many more where it's desirable or even necessary. Just because you got where you are just fine without the need for education, or because you saw that you could've gotten where you are without it, doesn't mean that everyone else's goals are the same. And, chances are that if you ended up being particularly financially successful without higher education, you were unusually lucky.

 

The part that really grinds my gears, though: Economics without math... That's... That's one hell of an oxymoron, man.

Can someone please explain what the below text is talking about? This is a page out of my course textbook titled algorithm design. I am suppose to read and understand this before the upcoming class but everything sounds like a foreign language. Everything is mathematical jargon and arcane notation. Give me some help please. My head hurts so much. 

Capture.PNG

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Requests L = array[n];

Struct request{

Int start

int end

}

 

i tried... those ellipsis are not helping. Email department heads for meeting about career stuff to trick them into tutoring you. 

Link to comment
Share on other sites

Link to post
Share on other sites

1 hour ago, fpo said:

Requests L = array[n];

Struct request{

Int start

int end

}

 

i tried... those ellipsis are not helping. Email department heads for meeting about career stuff to trick them into tutoring you. 

my instructor speaks in the same jargon in lectures. :( I dont understand him at all. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

It says to relax because once school is over you are not guaranteed work in anything you wish to go for.

It also means that once you are done with school, drop out, save cash and work hard.

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

26 minutes ago, wasab said:

my instructor speaks in the same jargon in lectures. :( I dont understand him at all. 

This is painfully familiar.

Link to comment
Share on other sites

Link to post
Share on other sites

24 minutes ago, BetterThanLife said:

It says to relax because once school is over you are not guaranteed work in anything you wish to go for.

It also means that once you are done with school, drop out, save cash and work hard.

Well, I need to pass this class so that is not an option. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, wasab said:

Well, I need to pass this class so that is not an option. 

For?

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

14 hours ago, BetterThanLife said:

For?

For classes that actually matters. It is a prerequisite. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, wasab said:

For classes that casually matters. It is a prerequisite. 

Prerequisite for?

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, BetterThanLife said:

Prerequisite for?

Stock market analysis and predictions where I learn how to get rich quick figuring out the trends of the stock markets. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, wasab said:

Stock market analysis where I learn how to get rich quick figuring out the trends of the stock markets. 

Sorry to be a killer here but this math nonsense has literally no link to that.

So if you want to do that, school will not help you there fiend, it is not math that makes people good at the stock markets, it is wisdom, timing and experience.

 

You either have it or you don't.

 

Be around people who do that work not pretenders.

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, BetterThanLife said:

Sorry to be a killer here but this math nonsense has literally no link to that.

So if you want to do that, school will not help you there fiend, it is not math that makes people good at the stock markets, it is wisdom, timing and experience.

 

You either have it or you don't.

 

Be around people who do that work not pretenders.

Well, too bad. I need to pass this class to be licensed. Your wisdom and experience simply won't cut it in an industry which is regulated by law and requires higher education by law. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, wasab said:

Well, too bad. I need to pass this class to be licensed. Your wisdom and experience simply won't cut it in an industry which is regulated by law and requires higher education by law. 

Ahh American.

 

https://study.com/articles/Requirements_for_a_Licensed_Stock_Broker_Education_and_Career_Info.html

 

Many people get in places.

Rules do not apply to all, it's a part of life.

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, BetterThanLife said:

Ahh American.

 

https://study.com/articles/Requirements_for_a_Licensed_Stock_Broker_Education_and_Career_Info.html

 

Many people get in places.

Rules do not apply to all, it's a part of life.

I need to pass this class okay? I don't want to be like one of those rogue doctors who pratice medicine without a degree/license and then get thrown behind bars for life. 

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, wasab said:

I need to pass this class okay? I don't want to be like one of those rogue doctors who pratice medicine without a degree/license and then get thrown behind bars for life. 

No problem, just remember the millions of people who graduated with thousands of debt and no job to go to in recent times.

 

 

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

28 minutes ago, BetterThanLife said:

No problem, just remember the millions of people who graduated with thousands of debt and no job to go to in recent times.

 

 

Economy isn't that bad. And by statisics, those who do graduated has less than half the unemployment rate of those who didn't. 

 

I just wanna do well in school. Why you wanna discourage me ?

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, wasab said:

Economy isn't that bad. And by stastics, those who do graduated has less than half the employment rate of those who didn't. 

 

I just wanna do well in school. Why you wanna discourage me ?

Lived longer and i can see the world for how it is like many, it is not meant to discourage you it is to make sure that you REALLY will get somewhere, if you do not get somewhere all of this is in vein and you end up in a shit load of debt, depression, possibly some mental anguish trying to help yourself out of that hole, when you could make it far simpler and just work hard whilst gathering resources by saving.

 

also economics without maths but what i mentioned before.

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, BetterThanLife said:

Lived longer and i can see the world for how it is like many, it is not meant to discourage you it is to make sure that you REALLY will get somewhere, if you do not get somewhere all of this is in vein and you end up in a shit load of debt, depression, possibly some mental anguish trying to help yourself out of that hole, when you could make it far simpler and just work hard whilst gathering resources by saving.

 

also economics without maths but what i mentioned before.

But I am happier to know I tried and failed than never tried at all ?

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, wasab said:

But I am happier to know I tried and failed than never tried at all ?

I'm sorry.

 

I'm in a bit of an intense mood, you carry on being you friend you are a good person.

Stinkpci5 3550. DDR3 1600mhz 8GB. Gigabyte GA-H61N-USB3.0. Sapphire RX 570 Nitro 4GB oc. Noctua NH-L12. WD Black 600GB. Silverstone PSU 1KW. Advent 1440x900 75hz VGA monitor 1ms. Acer Veriton M464 chassis.

Self help guide.

 

Link to comment
Share on other sites

Link to post
Share on other sites

Wow. I saw 18 replies and figured it was answered, but it turns out it... Very, very much was not.

 

OP, that excerpt is essentially introducing the idea of maximizing productivity.

 

You have a set of tasks ("requests") that occur over a specified interval of time, and two intervals are compatible if the times don't overlap, meaning that only one thing can be happening at a time. So the interval 1:00-4:00 is compatible with the interval 5:00-6:00, but it's not compatible with the interval 2:00-5:00, because that overlaps.

 

You are given a set of tasks that each have their own time interval, and your goal is to do as many of those tasks as you can without doing more than one of them at once. Like scheduling in as many parties as you can in a weekend -You can't choose when they happen, you can only choose which ones to go to.

Continuing with that analogy, let's say there are 6 parties happening in one day back-to-back, and there's one that's happening for the entire day. That one party overlaps with all the others, so you can either choose to go to that one party or the 6 others -Of which you would choose the 6, because you're trying to get as many in as possible.

 

I don't usually do those sort of heavily abstracted "let's make this relatable!" examples... It just sort of happened...

 

Continuing on with the excerpt, it says to sort the set of tasks in order of increasing finish time (it says "nondescending" because multiple tasks can finish at the same time). So a set of intervals like {1-4, 2-3, 5-8, 3-7} would be sorted as {2-3, 1-4, 3-7, 5-8}. Then is says for the element j from that set, p(j) is the latest element before it that doesn't overlap. So p(5-8) would be 1-4, and p(3-7) would be 2-3. p(j) is 0 if there isn't an interval that doesn't overlap.

 

Then it says you have an optimal solution O, meaning the biggest set of compatible tasks you can make. If the last element in the set, which we'll call n (5-8 from the one above), is in O, then you know that nothing after p(n) (1-4 from above) is in O because the point of the p(n) function is that everything after it overlaps with n, and therefore can't be in the solution with n.

 

So then let's say you remove everything after p(n) from the problem (giving you {2-3, 1-4}, again from above). Since O was an optimal solution, and you removed both n and everything that could have replaced n, what's left of O is still an optimal solution.

 

@BetterThanLife
I take great issue with your sentiment. There are many paths in life that don't require higher education, many of them where going through college for it can even be a detriment, but there are still many more where it's desirable or even necessary. Just because you got where you are just fine without the need for education, or because you saw that you could've gotten where you are without it, doesn't mean that everyone else's goals are the same. And, chances are that if you ended up being particularly financially successful without higher education, you were unusually lucky.

 

The part that really grinds my gears, though: Economics without math... That's... That's one hell of an oxymoron, man.

"Do as I say, not as I do."

-Because you actually care if it makes sense.

Link to comment
Share on other sites

Link to post
Share on other sites

In my university this course was called "Discrete Structures". Sort of an introduction to discrete mathematics, data structures, and algorithms analysis. I figure this is about the same thing, just judging by the question.

 

The course is designed specifically to weed out candidates that won't make it to the 4000 level courses required to graduate with a CS degree, so stick with it: Barely anyone makes a high grade in that course.

Before we can post a good explanation of what this text says, we need to know what the function p is defined as. Please show us the definition of p from Figure 6.2.

 

 

ENCRYPTION IS NOT A CRIME

Link to comment
Share on other sites

Link to post
Share on other sites

12 hours ago, Dash Lambda said:

Snip

Awesome. I wish I had you as an instructor. So many of my proffesors are IVY league PhDs who, although are rock star researchers, simply can't teach.

Sudo make me a sandwich 

Link to comment
Share on other sites

Link to post
Share on other sites

6 hours ago, straight_stewie said:

Before we can post a good explanation of what this text says, we need to know what the function p() is defined as. Please show us the definition of p() from Figure 6.2.

Figure 6.2 is an example, it defines p() in the text provided.

 

And as for the specific class, in my uni I think the closest we have is Computer Architecture and Assembly, since that's where we start talking about task scheduling. The jargon starts getting strong there too.

 

EDIT: Wait, no, it's not introducing task scheduling. It's introducing recursion with a task scheduling problem. So it wouldn't equate to Arch and Assembly.

Edited by Dash Lambda

"Do as I say, not as I do."

-Because you actually care if it makes sense.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×