Difference between revisions of "Assignments WS 2017/2018"

From Simulace.info
Jump to: navigation, search
(Results)
(Conclusion)
Line 82: Line 82:
  
 
: Makes sense, however it is necessary to obtain real data. Implementation of some of them will not be easy. '''Approved'''. [[User:Tomáš|Tomáš]] ([[User talk:Tomáš|talk]]) 01:06, 19 December 2017 (CET)
 
: Makes sense, however it is necessary to obtain real data. Implementation of some of them will not be easy. '''Approved'''. [[User:Tomáš|Tomáš]] ([[User talk:Tomáš|talk]]) 01:06, 19 December 2017 (CET)
 
=Conclusion=
 
By setting different ratio of male and female hamsters and changing probability of spawning as well as changing amounts of food and efficiency of filter, we found certain relation between the hamsters population, food amount and quality and hamsters deaths reasons.
 
Applying different settings, we came to the conclusion that in order to have the lowest number no food death, eaten hamsters and poor food quality deaths and at the same time have the highest number of old age deaths and spawned hamsters, the zoo needs to set an appropriate rate of food and filtering of the food in the kennel. Moreover, the zoo has to make it sure that the kennel is big enough to have as many hamsters as possible. For our simulation we took the maximal number of hamsters living in the kennel at a time = 200. In our simulation the best relation was found when the food amount was set to 50 and filtering was 500, having the probability of hamsters spawning = 0.2. Moreover, it is recommended to clean the kennel as many as possible, since this leads to much better results.
 
  
 
=How It Works=
 
=How It Works=

Revision as of 20:13, 15 January 2018

Simulation Proposal (feld00)

I am going to simulate a public transport system. The idea came from travelling around Europe, being surprised how often public transport systems fail in large cities and still they are very expensive. Prague public transport is rare exception. Buses, trams and subway trains arrive with minimal deviation from planned arrival time usually in seconds. I believe that there is sophisticated simulation software behind this.

In order to simplify the task let’s presume that it is not about money. We are not going to optimize costs and incomes. The purpose of this simulation is to optimize:

• Numbers of transportation units (TU) needed

• Frequency of releasing TUs

• their arrival time

All stated above in order to prevent people queueing on public transportation stops and to prevent transportation units from crowding. Microsoft Excel and SimProcess if needed will be used to perform this simulation.

for Monte Carlo or Simprocess you need solid quality hard data - what particular solid resources would you bas the simulation on? In addition I think you simplify it so much into some artificial "Numbers of transportation units", that would make the simulation unusable. I would suggest something less ambitious - spacial simulation(agent based, simprocess) of one type of transportation based on real data, if you find some.Oleg.Svatos (talk) 15:49, 15 December 2017 (CET)
You are right, maybe I can do less ambitious project. What about evacuation from a building:
It will be a Agent-based simulation model. I will use NetLogo software to build an building enviroment, which will include walls and staff inside. Agents will randomly move around the building. If they colide with a wall they turn different direction. If they colide with a staff member, he will navigate them to the exit. Is that possible?
feld00 (talk) 22:35, 15 December 2017 (CET)
The program in NetLogo would be able to import bitmaps with a building blueprints (plan of the building) where escape doors and agents position will be specified by color blocks.
feld00 (talk) 18:00, 18 December 2017 (CET)
There were similar simulations in past. Please, find it, and explain how you will differentiate.
Random movement of agents does not make sense to me. You should model people, not zombies. Tomáš (talk) 01:04, 19 December 2017 (CET)
I found project "school on fire". Is that it? This would be simulation of any planned evacuation. You can upload any building plan. There would be also navigators guiding the agents to the nearest exits. Agents will move towards an exit (it will simulate an intuition), but wouldnt know the real path. Navigators and wall will guide them.
feld00 (talk) 18:00, 18 December 2017 (CET)
What is the goal of the simultation? Tomáš (talk) 01:59, 26 December 2017 (CET)
The goal is to find out how people will act in these kind of events.
If there are still concerns, maybe we can discuss it personaly to avoid this endless conversation and figure it out at once. I understand you may not be at office, we can do it on phone as well (606 439 385). Please call or comment if further discussion is necessary, Thank you.
feld00 (talk) 10:43, 27 December 2017 (CET)
Ok, if you can deal with real building layouts, it is ok (you will need to simplify it reasonably because in some cases, the simulations of real buildings of all possible cases could be tricky). Nevertheless, I don't think you are really able to analyze how real people behave, but you can discover what influences the safety of the building. Also consider that people can in some cases leave not just through regular exits, but through another way. E.g. windows. If you agree, you have it approved. Tomáš (talk) 16:32, 3 January 2018 (CET)

Simulation Proposal (xvatj00)

Software: Vensim

I am a contemporary gospel choir conductor (choir and full professional band). We organize more or less 3 concerts a year. It has been a long time since we released our last CD and now we would like to earn money to be able to start recording a new one. For this purpose, I would like to find out those factors (such as choir performance, band performance, tickets’ price, concert’s location, etc.) that influence potential audience when choosing a band to go see and how to improve them, and thus get more people to come to our concerts - and earn more money for the tickets and in general. I will use a survey to get data about people’s preferences. Xvatj00 (talk) 17:45, 27 November 2017 (CET)

For this kind of simulation you would need ritch historical data so that you would be able to find premises you would then build the equations on (and to be able to verify the model when you compare its results with the historical data). Unfortunately the survey will not help you to quantify the parameters and the number of concerts is really low to be usable for such simulation. I probabbly would suggest a different topic. Oleg.Svatos (talk) 18:43, 30 November 2017 (CET)
I can get data up to 10 years back. The number of concerts included only those concert that are organized by us only, but we perform in many other concerts as well. Do you have any suggestions how to make the simulation possible? Thank you. Xvatj00 (talk) 18:59, 30 November 2017 (CET)
You would have to be able to define parameters that determine the demand for the individual concerts, and based on the data quantify them and quantify their impact on the demand for a concert. Based on that one could then discuss how the concert and its content should be se up so that you get maximum profit out of it. That is not a really easy ...Oleg.Svatos (talk) 15:07, 6 December 2017 (CET)

Intersection Optimalization (NEW ASSIGNMENT)

Software: NetLogo

Almost every day, I walk by the intersection of Anglická and Bělehradská / Škrétova. During peak hours, there are traffic jams on only one street leading to the intersection, which I find interesting. Because of this fact, I would like to simulate the intersection in order to find out if the lights are really optimally set there, and potentially, find out the optimal setting of the intersection’s lights.

As I’ve already mentioned, there are lights directing the intersection. Also, there is a tram track on the Bělehradská / Škrétova street which goes straight, while most of the cars coming from Bělehradská street turn left. I will use real intervals of all of the lights from a chosen time during peak hours, and the number of cars and trams coming to the intersection (including their speed, direction, etc.). At first, I will set the lights to constant ticks according to the reality to simulate the real situation. After that, I will try to find out an optimal setting of the lights and evaluate, what the optimal setting is or if it meets with the reality. Xvatj00 (talk) 18:48, 8 December 2017 (CET)

Please, try to obtain real data. Approved. Tomáš (talk) 04:05, 12 December 2017 (CET)

Social media post (Amelievh)

Software: Netlogo

Nowadays social media is a hot topic, and a lot of recruiters and other business people use linked in to attract new employees or just to share their thoughts.

For my simulation, I was thinking about researching the reach of a social media post. Someone posts something on LinkedIn, and depending on the amount of connection and amount of sharing I want to check how many people you can reach with one post. I will try to find real-world numbers and make it a useful tool for the business world.

Simulations on social media are typically problematic, mostly due to the lack of real data. I would recommend to try finding, something else. Tomáš (talk) 04:11, 12 December 2017 (CET)

New proposal: gender pay gap

Software: Vensim

The gender pay gap is a difficult problem to solve because it is caused by different reasons (education, age, part-time working ...). These are main reasons, but all these reasons are influenced by other aspects and factors.I want to simulate these different reasons + influences in Vensim and work out the most effective solutions to reduce the pay gap. I would specify on 1 country because data is different per country. Easiest and most interesting for me is Belgium.

What particular literature and data will you base it on? Oleg.Svatos (talk) 12:07, 15 December 2017 (CET)
I wrote a paper on this topic for another course wherefore I found a lot of statistical data. The EU publishes statistical data about this topic and reasons for it. I came up with the idea after seeing the Vensim example of SchoolLife which also showed a lot of influence on your future career. Only googling 'Gender Pay Gap Belgium' give you already a lot of publications and statistical information on this topic. --Amelievh (talk) 12:20, 15 December 2017 (CET)
OK, approved, but you have to well argument the parameters and equations of the simulation (including the citations to accesable resources) in the report which has to accompany the simulation so that we can verify that it is based on real data and makes sense.

Simulation Proposal (A_V)

Software: NetLogo

We own a zoo. We have a huge kennel for hamsters. We have observed a strange behavior of the hamsters. When a female hamster gives birth to babies (usually up to 12), the mother may come under the pressure of nurturing each and everyone of them. After giving the birth a female hamster becomes weak and may die if does not have enough food and vitamins. Also when the mother is weak, she can not lactate milk for all of her babies. Since the quality of food provided by the zoo does not always satisfy the hamster, the mother eats her weakest babies to get extra protein to feed other babies, which increases the probability of survival of her and the rest babies. Another reason of the deaths of hamsters, as mentioned above, is the adequate quality of food. If the food does not satisfy the hamsters, they do not eat it and the food rots by polluting the kernel which leads to an increased number of hamster deaths. In the simulation I will focus on how much the food quality, the amount of food and keeping the kernel clean influences the number of hamster deaths.

Makes sense, however it is necessary to obtain real data. Implementation of some of them will not be easy. Approved. Tomáš (talk) 01:06, 19 December 2017 (CET)

How It Works

1.We create the environment – the kennel - by pressing the button “ setup” 2.Using sliders, we choose the initial number of male and female hamsters and adjust the probability of spawning of our hamsters. We turn the food filter to an amount that is adequate for the number of hamsters in the kennel, and we adjust the amount of food that is provided to our hamsters. 3.The simulation is started by pressing the button “go”

Male and Female hamsters are placed in the kennel. Periodically, some amount of food is added to the kennel. As hamsters walk, they use energy from food, represented as green patches, and age. As hamsters eat, they gain energy, grow to adulthood and add waste to the kennel. Female hamsters eat smaller hamsters. Hamsters die if: energy runs out, they get too old, food quality is poor. Hamsters spawn according to a probability if male hamster and female hamster are near each other, are mature, have enough energy, and the food quality is good. If food (the green patches) is not eaten, it rots and pollutes the kennel. The filter cleans waste and pollution from kennel depending on the flow of the filter. By pressing clean-environment button we are changing the food in the kennel, which is a fast way to improve food quality. By changing the variable we can see the effects of variables on food quality and hamsters population. It’s interesting to monitor the relation between hamsters population and food quality. Also it’s noticeable the relation between amount of food and population range. By changing the variables from sliders we can watch how the hamsters spawn, the baby hamsters grow, are being eaten and grow! The monitors show us the reasons of deaths, and the number of deaths.


Results

In order to make the simulation more realistic, I took the probability of hamsters spawning not higher than 0.5. Also, the maximal number of the hamsters living in the kennel was taken 200, since the kennel is not big enough. Our goal is to have the following statistics: •No Food Death – as minimal as possible •Old Age Death – better to have hamsters dead naturally •Number of Spawned – the more new babies we have – the better •Number of Eaten – the least number of eaten hamsters we have in the kennel, the better •Poor Quality Food Death – as minimal as possible I ran the simulation multiple times applying different settings for the same time period (the same number of ticks). I found the following cases the most interesting to focus on:

In the given six cases two cases satisfy 3 out of 5 aspects of our interest. I decided to elaborate on one of the cases, particularly:

For this case I decided to clean environment and monitor how our monitored numbers are changing. These are the results:

8.jpg

It is obvious from the simulation result that applying the more times we zoo cleans the kennel the least number of no food deaths we have, the higher number of old age deaths, the bigger number of spawned hamsters, the least number of eaten hamsters as well as the least number of poor quality food death we have.

Conclusion

By setting different ratio of male and female hamsters and changing probability of spawning as well as changing amounts of food and efficiency of filter, we found certain relation between the hamsters population, food amount and quality and hamsters deaths reasons. Applying different settings, we came to the conclusion that in order to have the lowest number no food death, eaten hamsters and poor food quality deaths and at the same time have the highest number of old age deaths and spawned hamsters, the zoo needs to set an appropriate rate of food and filtering of the food in the kennel. Moreover, the zoo has to make it sure that the kennel is big enough to have as many hamsters as possible. For our simulation we took the maximal number of hamsters living in the kennel at a time = 200. In our simulation the best relation was found when the food amount was set to 50 and filtering was 500, having the probability of hamsters spawning = 0.2. Moreover, it is recommended to clean the kennel as many as possible, since this leads to much better results.

1. Introduction

This simulation shows the spread of the virus Chickenpox via person-to-person transmission in the isolated population. It analyzes effect of vaccination on the dynamics of an infection with a person-to-person transmission and development of the immunity to the disease.

- Simulation Name: Virus Chickenpox

- Author: Yauheniya Andreyuk

2. Problem definition

Chickenpox, also known as varicella, is a highly contagious disease caused by the initial infection with varicella zoster virus (VZV). Chickenpox is an airborne disease which spreads easily through the coughs and sneezes of an infected person. The condition usually resolves by itself within a couple of weeks. The rash may, however, last for up to one month. After a chickenpox infection, the virus remains dormant in the body's nerve tissues. The immune system keeps the virus at bay, but later in life, usually in an adult, it can be reactivated and cause a different form of the viral infection called shingles.

3. Method

NetLogo 6.2. was used for this simulation. It was chosen due to the ease of visualization and quick results on a learning curve.

4. Model

Model.jpg

4.1. People

The model contains only one turtle, which is humans. People in the simulation are divided into three groups – healthy, sick or immune (not at the beginning of the simulation, but later on). If a human is sick, he may infect other people he comes in contact with. When the person reaches a definite age he dies and is no longer relevant to the model. After the person was sick, but recovered, he also gains the immunity. People are set to move randomly.

4.2. Other sliders

Infectiousness - capability of causing infection;

Vaccination-rate – percentage of vaccinated people;

Immune-time – amount of time for which the person gains immunity;

Duration – how long the person will be sick before he recovers or dies;

Chance-recover - probability that the person will recover or gain the immunity.


Results

I want to follow how the results will vary with the vaccination-rate changing.

Case 1.

Vaccination-rate = 0.

In this case we can see that population gets sick and recovers in a natural way. Without the vaccination up to 98% of the population gets sick, but recovers afterwards, but then the circle happens once again. And not surprisingly this cycles influence a lot the amount of people dying.

Capture1.PNG

Case 2.

Vaccination-rate < 10.

In this case the amount of immune people reaches up to 82% and the amount of people leaving in the area is quite stable. The amount of infected people doesn't reach even more then 12%.

Capture2.PNG

Case 3.

Vaccination-rate = 50.

In this case we can see that the amount of immune people is way bigger then infected individuals (as monitors show - 0.57 infected and 98.86 immune).

Capture3.PNG

Conclusion

It is clear from the results that the vaccination rate influences a lot the amount of immune people and the amount of sick/dying people. So it is concluded that more people care about the vaccination - more immune people are there in society - less people spread the virus and therefore less people die. For me, the vaccination rate was the most important parameter in this simulation, but changing the other parameters at the same time may give different results. The simulation has already a lot of parameters defined, but of course there is a space for improvements, for example - not always the symptoms are obvious at the very beginning, the extension to this simulation could be spreading disease without people even knowing it and capturing the amount of people dying when it is already too late to do something.

Code

File:Semestralni priklad.nlogo