Netlogo: adding a plant to the wolf sheep stride inheritance - netlogo

Me and my friends are working on a project for school.
In which we're basically trying to make a realistic model out of the model of the following link: https://netlogoweb.org/launch#https://netlogoweb.org/assets/modelslib/Sample%20Models/Biology/Unverified/Wolf%20Sheep%20Stride%20Inheritance.nlogo
Our biology teacher had the idea to add a poisonous plant to the model.
But our programming skills aren't good so we do not exactly know what we could do to add this plant. we know that we should probably add the plant to the code as a patch, but apart from that we do not know what we should do.
If there's anyone who could help us, we would be very thankful.

Related

Duplicate a model #Anylogic

I'm working on a family practitioner model, my goal is to model the population of a city and all of the family practitioners in that given city by taking into account the distribution of the treatment time and the arrival schedule of patients etc... I've started with a basic model with two practitioners and a small population.
Basic Model
Now if im going to model all of the 10k practitioners by duplicating the same blocks its gonna be like undoable, the other solution is to add more units in the resourcepool which does not model the real situation because basicly every family practitioner have his own queue and increasing the resourcepool is like modelling 'n' family practitioner in the same clinic with the same shared queue of patients. Is there any other solution? (first time using anylogic so im basicly a newbie)
thanks
You need to change your model architecture fundamentally. Practitioners become a custom agent type, you create a population of them and provide a flow chart in that agent type. Then, you can have 10k of them each with their own flow chart.
Strongly recommend you do all the tutorials in the help first to get a better understanding of the capabilities of AnyLogic. Having some blocks on Main is really just 0.1% of what the tool is capable of :)

Finding the shortest path in NetLogo

How to build a NetLogo agent who must try to find the shortest route between all of the given locations whilst also avoiding the given patches as those represent solid impassable objects.
If you google "shortest route algorithm" you'll find many, for example: https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm
But you have massively under-specified the problem you are trying to solve. You want a single agent to solve this? Why not a swarm or class of agents? If just one agent why are you using NetLogo as a tool? Are the agents smart? Do they get smarter over time? Can 3 agents work together on exploring the terrain? Does this have to get solved just once or many times?
How much information is available to the agent? The whole world? Just the nearest radius R? Does the agent know in advance what the "given locations" are and what the obstacles are? Does the order in which the given-locations are visited matter?
This could be the classic "travelling salesman" problem, having to visit each of N cities with costs of travel between each pair being given. See https://en.wikipedia.org/wiki/Travelling_salesman_problem
Can the agent find ANY route, and then keep trying to improve it? Or must it work on the first pass? What's the stopping condition? How do you know when the best route you've found is the best possible route?
You should also look at the A* algorithm. https://en.wikipedia.org/wiki/A*_search_algorithm
There's a huge amount of prior work done on solving this class of problem but they're mostly computational -- ie, your agent could simply sit and plug numbers into software and compute an answer and never move. I don't think that's what you had in mind. But what DID you have in mind?

Multiple object tracking using radar data and extended kalman filter

thanks in advance.
I am new to the multiple object tracking field. So, I have been working on this for a couple of days. I have developed my first version of a single object tracker using an extended Kalman filter. I am estimating position, velocity by assuming a constant acceleration model. Now my question is how can I convert the existing model for multiple objects tracking. The main problem is I am using radar data. So, I am not able to get the references for developing the tracker. So, One good example or steps to achieve can help me in understanding the concept.
The answer to this question depends on a lot of things. For example, how much control and knowledge do you have over the whole system? If you know how many targets you need to track you can add all of them to the Kalman Filter state and for every measurement you perform data association to find out to which object a given measurement belongs. An easy association metric would be nearest neighbor.
If you don't know how many targets there will be you will want to implement a track management where each target you are tracking represents a track and you can model birth and death probabilities of targets.
Multi Target Tracking is a vast field and if you want to have an in-depth mathematical introduction I would recommend the 2015 survey paper "Multitarget Tracking" by Ba-Ngu Vo et al. You should be able to find a preprint pdf online.
If you are looking more for a lightweight tutorial I would assume it should be possible to find some tutorial or example code online where to start. As mentioned in the first paragraph, nearest neighbor association for a fixed amount of objects might be a good first step.

Turtles changing more then one patch netlogo

I am new to programming and using netlogo so this question is probably too simple.
I am creating a model in which households decide their farming area each year (changing the location every year). I need to make them change the type of vegetation of n patches, according to the size they decided previously.
I know primitives like in-radius, neighbor and neighbor4 but all of them don't give me the freedom to change the exact number I want. For example, if the farming area is 3 hectares, how can i make one household change 3 patches vegetation type? How can I do that?
Thanks
How about:
n-of 3 neighbors
That would give you three random patches among the patche's neighbors, which may or may not be what you want, but your question isn't precise enough to say...
Let us know if that works for you. If not, give us a bit more detail.

What is a suitable data mining model to find the best Hospital?

I have a Hospital ratings data-set and need to find best hospital when I just broke my leg. So what is the best data mining model that I can use and how to
find which model is better?
https://www.kaggle.com/center-for-medicare-and-medicaid/hospital-ratings#=
This is really up to you to design. You need to attach a weight to each of the variables you have, which is how you attach importance to that variable.
Is the hospital location a limiting factor? Maybe you can only hobble 5 miles on your broken leg, or maybe you're a baller and can book your private jet to Hollywood.
If you don't have a way to connect with an API to determine distance based on your location and the hospital address, then you'll just have to throw out location altogether.
If you just broke your leg, timeliness of care is probably pretty important. But if you want to get a boob job, then you probably don't mind waiting a month or two as long as it's done really well.
In this case, effectiveness of care is probably the most valuable variable. I would start with just that, then work on adding in more variables and refining your answer. What happens if two hospitals have equally good effectiveness? Then patient satisfaction might be the next most important, etc.