Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [stem-dev] Food Production

I think the only question issue arrises if you need the FoodConsumer to be integrable.
The transformation decorator was designed to handle transformations that are by definition not integrable
but food consumption might be.

Here is one other thought (but one with big downsides).
Stefan suggested you use multipopulation model to handle consumption.
A food consumption decorator could store a MAP which knows at what rate different populations consume different foods.
We probably want to handle consumption of feed by farm animals as well as consumption of food by humans.
If the foodconsumption decorator does not do the but simply stores the rates, then the population models could handle the decay
in an integrable way (because population models are integration decorators). The thing I do not like about this idea is it then makes all
population models more complex and I wanted to hide the complexity of food transformation in a separate transformation decorator.

A second thought (also with downsides) is to give the transformation decorator a flag to indicate whether or not the transformation is
an integrable transformation. We would then have to group any transformation decorators by integrability and so we call transform at the
right point in the iteration cycle. This also has bid disadvantages (performance hit as a well as a lot of complexity for the users - they need to
understand if the transformer can be integrable).

The best approach may be Stefans suggestion. What if we extend multi population model to a new class called "Food" or "Food Population".
This could have different states, death=expiration, and it could store  a map<Population>=Consumers with their consumption rate. This might also be a
better representation of reality since consumption is not really transformation. Consumption is integrable. Food production is not.



Best Regards,
Jamie

IBM Almaden Research Center, 650 Harry Rd.
San Jose, CA 95120-6099
email: kaufman@xxxxxxxxxxxxxxx
phone: (408) 927-2477  (tie 457-2477)




From: "Thoens Christian" <Christian.Thoens@xxxxxxxxxxx>
To: <stem-dev@xxxxxxxxxxx>,
Date: 01/13/2012 03:04 AM
Subject: [stem-dev] Hi all,
Sent by: stem-dev-bounces@xxxxxxxxxxx





Hi all,

I would like to make some changes to the foodproduction plugin. A class
that allows consumption of food and disease transmission by consumption
should be created. My proposal for this is as follows.

abstract base class "FoodTransformer" (or maybe "FoodProcessor", since
consumption does not transform food?)

a child of "FoodTransformer" called "FoodProducer" (maybe abstract?):
same functionality as the old class "FoodProducer"

a child of "FoodProducer" called "DiseaseCarryingFoodProducer" (or
maybe "Slaughterhouse"?): same functionality as the old class
"Slaughterhouse"

a child of "FoodTransformer" called "FoodConsumer": provides
consumption of food and disease transmission by consumption

Does anyone have any suggestions for improvements?

Thanks,
Chris
_______________________________________________
stem-dev mailing list
stem-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/stem-dev




Back to the top