| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256 |
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>pypdevsbbl.domain.industry module — Python(P)DEVS-BBL documentation</title>
- <link rel="stylesheet" href="_static/nature.css" type="text/css" />
- <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
- <link rel="stylesheet" type="text/css" href="_static/custom.css" />
- <script type="text/javascript" id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></script>
- <script type="text/javascript" src="_static/jquery.js"></script>
- <script type="text/javascript" src="_static/underscore.js"></script>
- <script type="text/javascript" src="_static/doctools.js"></script>
- <script type="text/javascript" src="_static/language_data.js"></script>
- <script async="async" type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
- <link rel="index" title="Index" href="genindex.html" />
- <link rel="search" title="Search" href="search.html" />
- <link rel="next" title="pypdevsbbl.extra package" href="pypdevsbbl.extra.html" />
- <link rel="prev" title="pypdevsbbl.domain.gpss module" href="pypdevsbbl.domain.gpss.html" />
- </head><body>
- <div class="related" role="navigation" aria-label="related navigation">
- <h3>Navigation</h3>
- <ul>
- <li class="right" style="margin-right: 10px">
- <a href="genindex.html" title="General Index"
- accesskey="I">index</a></li>
- <li class="right" >
- <a href="py-modindex.html" title="Python Module Index"
- >modules</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.html" title="pypdevsbbl.extra package"
- accesskey="N">next</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.domain.gpss.html" title="pypdevsbbl.domain.gpss module"
- accesskey="P">previous</a> |</li>
- <li class="nav-item nav-item-0"><a href="index.html">Python(P)DEVS-BBL documentation</a> »</li>
- <li class="nav-item nav-item-1"><a href="pypdevsbbl.html" >pypdevsbbl package</a> »</li>
- <li class="nav-item nav-item-2"><a href="pypdevsbbl.domain.html" accesskey="U">pypdevsbbl.domain package</a> »</li>
- </ul>
- </div>
- <div class="document">
- <div class="documentwrapper">
- <div class="bodywrapper">
- <div class="body" role="main">
-
- <div class="section" id="module-pypdevsbbl.domain.industry">
- <span id="pypdevsbbl-domain-industry-module"></span><h1>pypdevsbbl.domain.industry module<a class="headerlink" href="#module-pypdevsbbl.domain.industry" title="Permalink to this headline">¶</a></h1>
- <p>Domain-specific building block for industrial purposes.</p>
- <dl class="class">
- <dt id="pypdevsbbl.domain.industry.ConveyorBelt">
- <em class="property">class </em><code class="descclassname">pypdevsbbl.domain.industry.</code><code class="descname">ConveyorBelt</code><span class="sig-paren">(</span><em>name</em>, <em>v</em>, <em>L</em>, <em>K=inf</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#ConveyorBelt"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.ConveyorBelt" title="Permalink to this definition">¶</a></dt>
- <dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevs.DEVS.CoupledDEVS</span></code></p>
- <p>A conveyor belt with items moving over it.</p>
- <p>Basically, a conveyor can be seen as a glorified queue that uses
- speed for timing purposes. Internally, there is a
- <a class="reference internal" href="pypdevsbbl.generic.queues.html#pypdevsbbl.generic.queues.SimpleQueue" title="pypdevsbbl.generic.queues.SimpleQueue"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.generic.queues.SimpleQueue</span></code></a> and a
- <a class="reference internal" href="pypdevsbbl.generic.transformers.html#pypdevsbbl.generic.transformers.Transformer" title="pypdevsbbl.generic.transformers.Transformer"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.generic.transformers.Transformer</span></code></a> that have been
- called <code class="docutils literal notranslate"><span class="pre"><name>-queue</span></code> and <code class="docutils literal notranslate"><span class="pre"><name>-transformer</span></code> respectively,
- where <code class="docutils literal notranslate"><span class="pre"><name></span></code> indicates the current block’s name.</p>
- <div align="center" class="align-center"><img alt="_images/conveyor-belt.svg" src="_images/conveyor-belt.svg" /></div>
- <table class="docutils field-list" frame="void" rules="none">
- <col class="field-name" />
- <col class="field-body" />
- <tbody valign="top">
- <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
- <li><strong>name</strong> (<em>str</em>) – The name of the block.</li>
- <li><strong>v</strong> (<em>numeric</em>) – The conveyor speed.</li>
- <li><strong>L</strong> (<em>numeric</em>) – The length of the conveyor.</li>
- <li><strong>K</strong> (<em>numeric</em>) – The capacity of the conveyor. Defaults to
- <code class="docutils literal notranslate"><span class="pre">INFINITY</span></code>.</li>
- </ul>
- </td>
- </tr>
- <tr class="field-even field"><th class="field-name">Input Ports:</th><td class="field-body"><ul class="first simple">
- <li><strong>enter</strong> (<em>any</em>) – The items that enter the conveyor belt.</li>
- <li><strong>velocity</strong> (<em>numeric</em>) – A new velocity at which the conveyor must run.</li>
- </ul>
- </td>
- </tr>
- <tr class="field-odd field"><th class="field-name">Output Ports:</th><td class="field-body"><ul class="first last simple">
- <li><strong>leave</strong> (<em>any</em>) – The items that leave the conveyor belt.</li>
- <li><strong>overflow</strong> (<em>any</em>) – The items that leave the conveyor because of
- overflow.</li>
- </ul>
- </td>
- </tr>
- </tbody>
- </table>
- </dd></dl>
- <dl class="class">
- <dt id="pypdevsbbl.domain.industry.Transporter">
- <em class="property">class </em><code class="descclassname">pypdevsbbl.domain.industry.</code><code class="descname">Transporter</code><span class="sig-paren">(</span><em>name</em>, <em>path</em>, <em>vmax</em>, <em>a=1</em>, <em>d=1</em>, <em>dist=<function distance.euclidean></em>, <em>chained=False</em>, <em>start=None</em>, <em>passthrough=False</em>, <em>eps=1e-06</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter" title="Permalink to this definition">¶</a></dt>
- <dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevs.DEVS.AtomicDEVS</span></code></p>
- <p>Transports an item linearly over a path.</p>
- <p>When not <code class="xref py py-attr docutils literal notranslate"><span class="pre">chained</span></code>, the item is picked up at the start of
- the path before being transported to the end of the path, where
- it is dropped off. Next, we return over a straight line to the
- beginning and start over again.</p>
- <p>When <code class="xref py py-attr docutils literal notranslate"><span class="pre">chained</span></code>, instead of returning to the beginning, we
- move to the next position where items can be picked up and start
- over again.</p>
- <div align="center" class="align-center"><img alt="_images/transporter.svg" src="_images/transporter.svg" /></div>
- <table class="docutils field-list" frame="void" rules="none">
- <col class="field-name" />
- <col class="field-body" />
- <tbody valign="top">
- <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
- <li><strong>name</strong> (<em>str</em>) – The name of the block.</li>
- <li><strong>path</strong> (<em>iter</em>) – An ordered set of <a class="reference internal" href="pypdevsbbl.extra.spatial.html#pypdevsbbl.extra.spatial.Coordinate" title="pypdevsbbl.extra.spatial.Coordinate"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.extra.spatial.Coordinate</span></code></a>
- objects, indicative of each point in the path. It is
- assumed there is a full stop between all points in the
- path. There must be at least one point.</li>
- <li><strong>vmax</strong> (<em>numeric</em>) – The maximal velocity of the transporter.</li>
- <li><strong>a</strong> (<em>numeric</em>) – Strictly positive value that indicates the acceletarion
- of the transporter. Must not be <code class="docutils literal notranslate"><span class="pre">INFINITY</span></code>. Defaults
- to 1.</li>
- <li><strong>d</strong> (<em>numeric</em>) – Strictly positive value that indicates the deceleration
- of the transporter. Must not be <code class="docutils literal notranslate"><span class="pre">INFINITY</span></code>. Defaults
- to 1.</li>
- <li><strong>dist</strong> (<em>def</em>) – Distance function to use. As arguments, it takes two
- <a class="reference internal" href="pypdevsbbl.extra.spatial.html#pypdevsbbl.extra.spatial.Coordinate" title="pypdevsbbl.extra.spatial.Coordinate"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.extra.spatial.Coordinate</span></code></a> objects and it
- returns a numeric value, indicative of the distance.
- See also <a class="reference internal" href="pypdevsbbl.extra.spatial.html#pypdevsbbl.extra.spatial.distance" title="pypdevsbbl.extra.spatial.distance"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.extra.spatial.distance</span></code></a>. Defaults
- to <a class="reference internal" href="pypdevsbbl.extra.spatial.html#pypdevsbbl.extra.spatial.distance.euclidean" title="pypdevsbbl.extra.spatial.distance.euclidean"><code class="xref py py-meth docutils literal notranslate"><span class="pre">pypdevsbbl.extra.spatial.distance.euclidean()</span></code></a>.</li>
- <li><strong>chained</strong> (<em>bool</em>) – Indicator that the block is chained. Defaults to <code class="docutils literal notranslate"><span class="pre">False</span></code>.</li>
- <li><strong>start</strong> (<a class="reference internal" href="pypdevsbbl.extra.spatial.html#pypdevsbbl.extra.spatial.Coordinate" title="pypdevsbbl.extra.spatial.Coordinate"><em>Coordinate</em></a>) – The starting point of the transporter. It can be used to
- indicate a depository where the transporter starts. When
- <code class="docutils literal notranslate"><span class="pre">None</span></code>, the beginning of the path is assumed. If
- <code class="xref py py-attr docutils literal notranslate"><span class="pre">chained</span></code> is <code class="docutils literal notranslate"><span class="pre">True</span></code>, this must be set to indicate
- the first block and/or its offset. All other blocks in the
- chain <strong>must</strong> have this value set to <code class="docutils literal notranslate"><span class="pre">None</span></code>. Defaults
- to <code class="docutils literal notranslate"><span class="pre">None</span></code>.</li>
- <li><strong>passthrough</strong> (<em>bool</em>) – Can be used to indicate that this transporter will only
- follow a path and not pick up any items. In a chain, this
- allows for more complex motion to the next pickup point.
- Only useful within that context and is therefore only set
- if <code class="xref py py-attr docutils literal notranslate"><span class="pre">chained</span></code> is <code class="docutils literal notranslate"><span class="pre">True</span></code>.</li>
- <li><strong>eps</strong> (<em>numeric</em>) – The maximal distance from a point the transformer may be to
- be assumed at that location. Defaults to <code class="docutils literal notranslate"><span class="pre">1e-6</span></code>.</li>
- </ul>
- </td>
- </tr>
- <tr class="field-even field"><th class="field-name">State:</th><td class="field-body"><ul class="first simple">
- <li><strong>item</strong> (<em>any</em>) – The item that’s being carried.</li>
- <li><strong>input</strong> (<em>any</em>) – The new item that arrives.</li>
- <li><strong>elapsed</strong> (<em>numeric</em>) – The elapsed time since last event.</li>
- <li><strong>duration</strong> (<em>numeric</em>) – The duration until a next event is scheduled.</li>
- </ul>
- </td>
- </tr>
- <tr class="field-odd field"><th class="field-name">Input Ports:</th><td class="field-body"><ul class="first simple">
- <li><strong>input</strong> (<em>any</em>) – A new item that wants to be transported.</li>
- <li><strong>previous</strong> (<em>Coordinate</em>) – The end location in a chained transformer.</li>
- </ul>
- </td>
- </tr>
- <tr class="field-even field"><th class="field-name">Output Ports:</th><td class="field-body"><ul class="first last simple">
- <li><strong>restock</strong> (<em>bool</em>) – A simple message that indicates the block can accept a new
- item for transportation.</li>
- <li><strong>blocked</strong> (<em>any</em>) – The items that don’t have permission to enter.</li>
- <li><strong>output</strong> (<em>any</em>) – The items that are dropped off.</li>
- <li><strong>next</strong> (<em>Coordinate</em>) – The end location in a chained transformer.</li>
- </ul>
- </td>
- </tr>
- </tbody>
- </table>
- <dl class="method">
- <dt id="pypdevsbbl.domain.industry.Transporter.duration">
- <code class="descname">duration</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter.duration"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter.duration" title="Permalink to this definition">¶</a></dt>
- <dd><p>Actual computation of the duration of the full path.</p>
- </dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.domain.industry.Transporter.timeAdvance">
- <code class="descname">timeAdvance</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter.timeAdvance"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter.timeAdvance" title="Permalink to this definition">¶</a></dt>
- <dd></dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.domain.industry.Transporter.outputFnc">
- <code class="descname">outputFnc</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter.outputFnc"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter.outputFnc" title="Permalink to this definition">¶</a></dt>
- <dd></dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.domain.industry.Transporter.intTransition">
- <code class="descname">intTransition</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter.intTransition"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter.intTransition" title="Permalink to this definition">¶</a></dt>
- <dd></dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.domain.industry.Transporter.extTransition">
- <code class="descname">extTransition</code><span class="sig-paren">(</span><em>inputs</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/domain/industry.html#Transporter.extTransition"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.domain.industry.Transporter.extTransition" title="Permalink to this definition">¶</a></dt>
- <dd></dd></dl>
- </dd></dl>
- </div>
- </div>
- </div>
- </div>
- <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
- <div class="sphinxsidebarwrapper">
- <h4>Previous topic</h4>
- <p class="topless"><a href="pypdevsbbl.domain.gpss.html"
- title="previous chapter">pypdevsbbl.domain.gpss module</a></p>
- <h4>Next topic</h4>
- <p class="topless"><a href="pypdevsbbl.extra.html"
- title="next chapter">pypdevsbbl.extra package</a></p>
- <div id="searchbox" style="display: none" role="search">
- <h3>Quick search</h3>
- <div class="searchformwrapper">
- <form class="search" action="search.html" method="get">
- <input type="text" name="q" />
- <input type="submit" value="Go" />
- <input type="hidden" name="check_keywords" value="yes" />
- <input type="hidden" name="area" value="default" />
- </form>
- </div>
- </div>
- <script type="text/javascript">$('#searchbox').show(0);</script>
- </div>
- </div>
- <div class="clearer"></div>
- </div>
- <div class="related" role="navigation" aria-label="related navigation">
- <h3>Navigation</h3>
- <ul>
- <li class="right" style="margin-right: 10px">
- <a href="genindex.html" title="General Index"
- >index</a></li>
- <li class="right" >
- <a href="py-modindex.html" title="Python Module Index"
- >modules</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.html" title="pypdevsbbl.extra package"
- >next</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.domain.gpss.html" title="pypdevsbbl.domain.gpss module"
- >previous</a> |</li>
- <li class="nav-item nav-item-0"><a href="index.html">Python(P)DEVS-BBL documentation</a> »</li>
- <li class="nav-item nav-item-1"><a href="pypdevsbbl.html" >pypdevsbbl package</a> »</li>
- <li class="nav-item nav-item-2"><a href="pypdevsbbl.domain.html" >pypdevsbbl.domain package</a> »</li>
- </ul>
- </div>
- <div class="footer" role="contentinfo">
- © Copyright 2020, Randy Paredis.
- Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.8.5.
- </div>
- </body>
- </html>
|