Tuesday, November 3, 2009

Begin by Modeling the Data

Modeling the data.
Earlier this year I saw a very impressive fleet management model. It was not all that large or even very complex. It was, however very flexible. By changing only the data in the model, it could represent any kind of fleet from cruise ships to delivery trucks. The key to the success of this model was that the model builder began by structuring the model data.

Often our first impulse is to approach a simulation problem by dropping blocks onto the model worksheet. This is partially our fault as a software developer. We have made it so easy to create a model that it is hard to resist dropping some blocks onto the screen and getting the instant gratification of a running model. Once the blocks have been connected together then you can begin the task of fitting the data to the model. While this may work fine for smaller, well defined systems, the build first, data later approach makes it difficult to create scalable reusable models.

Starting by designing a database for the model has a number of advantages:

  1. You will know early in the modeling process what data to collect.
  2. Data problems can be identified at the start of the simulation project.
  3. Opportunities to create smaller, more elegant models may be discovered. Patterns in the data often point to reusable model segments that are identical in structure.
  4. The data will fit more naturally into the model.
  5. Fewer structural model revisions will be required to fit the data into an already completed model.
  6. People who do not know anything about simulation can be part of the design process.
  7. Your models will be more scalable.

So, before beginning your next project, rather than flowcharting the process, try flowcharting the data structures. You will probably become a better modeler.

davek

2 comments:

  1. This is excellent advice! Understanding the data is crucial to the success of the model. A bit of forethought about how all the data fits together and what data you need out of the model to make your decisions will pay dividends.

    Building a model with scalablity and resuability is definitely a mindset and learned through practice, and usually comes as an "a-ha" momment (for example, when the first email to change your really big complex model arrives in your inbox.)

    ReplyDelete
  2. In general I agree that knowing the data structure is paramount to designing an elegant (and therefore testable) model. But when you are wrapping your head around a new problem, you may not even know what data you would like to use (it may be more or less than the data you already have.)

    So sometimes cobbling a model together by dropping blocks down is a good way to create a PRELIMINARY model. This helps you understand what the design issues are, and therefore what data is important to use.

    THEN you throw away that model, start a NEW model using the essential data structures, and proceed as Dave outlines above. I've written all different kinds of software, and planning for my first attempt to be a disposable prototype gives me a tool to understand the design issues, which then gives me the expertise to do it right the SECOND time.

    ReplyDelete

Popular Posts