72.8 KB
/srv/reproducible-results/rbuild-debian/tmp.hbWJqy6rnB/b1/yade_2019.01a-2_amd64.changes vs.
/srv/reproducible-results/rbuild-debian/tmp.hbWJqy6rnB/b2/yade_2019.01a-2_amd64.changes
644 B
Files
    
Offset 1, 6 lines modifiedOffset 1, 6 lines modified
  
1 ·c1a38f8eb2221f5fadd02ecf16bfd9b4·743453952·debug·optional·libyade-dbgsym_2019.01a-2_amd64.deb1 ·c1a38f8eb2221f5fadd02ecf16bfd9b4·743453952·debug·optional·libyade-dbgsym_2019.01a-2_amd64.deb
2 ·e8bfe4bfac175cd9f22e599b84ba5e9a·9125196·science·optional·libyade_2019.01a-2_amd64.deb2 ·e8bfe4bfac175cd9f22e599b84ba5e9a·9125196·science·optional·libyade_2019.01a-2_amd64.deb
3 ·465d6d5303fe8ff9e8938aa544573471·252084·python·optional·python-yade_2019.01a-2_amd64.deb3 ·465d6d5303fe8ff9e8938aa544573471·252084·python·optional·python-yade_2019.01a-2_amd64.deb
4 ·2495d9223c7094892993e80e1a614db3·4037320·doc·optional·yade-doc_2019.01a-2_all.deb 
5 ·f323f228174d29ca78198319e336bb25·1727732·science·optional·yade_2019.01a-2_amd64.deb4 ·b0cd12ae8a07007eedcde889349b4408·4037320·doc·optional·yade-doc_2019.01a-2_all.deb
 5 ·77fddef15f1c5abc7a97be7ee0c742fa·1727720·science·optional·yade_2019.01a-2_amd64.deb
70.9 KB
yade-doc_2019.01a-2_all.deb
452 B
file list
    
Offset 1, 3 lines modifiedOffset 1, 3 lines modified
1 -rw-r--r--···0········0········0········4·2019-01-30·18:41:45.000000·debian-binary1 -rw-r--r--···0········0········0········4·2019-01-30·18:41:45.000000·debian-binary
2 -rw-r--r--···0········0········0·····6532·2019-01-30·18:41:45.000000·control.tar.xz2 -rw-r--r--···0········0········0·····6536·2019-01-30·18:41:45.000000·control.tar.xz
3 -rw-r--r--···0········0········0··4030596·2019-01-30·18:41:45.000000·data.tar.xz3 -rw-r--r--···0········0········0··4030592·2019-01-30·18:41:45.000000·data.tar.xz
98.0 B
control.tar.xz
70.0 B
control.tar
48.0 B
./md5sums
30.0 B
./md5sums
Files differ
70.3 KB
data.tar.xz
70.3 KB
data.tar
4.21 KB
file list
    
Offset 183, 28 lines modifiedOffset 183, 28 lines modified
183 -rw-r--r--···0·root·········(0)·root·········(0)····21022·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index-toctree.html183 -rw-r--r--···0·root·········(0)·root·········(0)····21022·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index-toctree.html
184 -rw-r--r--···0·root·········(0)·root·········(0)·····9500·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index-toctree_manuals.html184 -rw-r--r--···0·root·········(0)·root·········(0)·····9500·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index-toctree_manuals.html
185 -rw-r--r--···0·root·········(0)·root·········(0)····12082·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index.html185 -rw-r--r--···0·root·········(0)·root·········(0)····12082·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/index.html
186 -rw-r--r--···0·root·········(0)·root·········(0)····43097·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/installation.html186 -rw-r--r--···0·root·········(0)·root·········(0)····43097·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/installation.html
187 -rw-r--r--···0·root·········(0)·root·········(0)····68029·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/introduction.html187 -rw-r--r--···0·root·········(0)·root·········(0)····68029·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/introduction.html
188 -rw-r--r--···0·root·········(0)·root·········(0)·····7300·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/modules.html188 -rw-r--r--···0·root·········(0)·root·········(0)·····7300·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/modules.html
189 -rw-r--r--···0·root·········(0)·root·········(0)····43663·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/objects.inv189 -rw-r--r--···0·root·········(0)·root·········(0)····43663·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/objects.inv
190 -rw-r--r--···0·root·········(0)·root·········(0)···260875·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/prog.html190 -rw-r--r--···0·root·········(0)·root·········(0)···260885·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/prog.html
191 -rw-r--r--···0·root·········(0)·root·········(0)···163339·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/publications.html191 -rw-r--r--···0·root·········(0)·root·········(0)···163339·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/publications.html
192 -rw-r--r--···0·root·········(0)·root·········(0)·····9045·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/py-modindex.html192 -rw-r--r--···0·root·········(0)·root·········(0)·····9045·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/py-modindex.html
193 -rw-r--r--···0·root·········(0)·root·········(0)····51111·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/references.html193 -rw-r--r--···0·root·········(0)·root·········(0)····51111·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/references.html
194 -rw-r--r--···0·root·········(0)·root·········(0)·····4573·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/search.html194 -rw-r--r--···0·root·········(0)·root·········(0)·····4573·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/search.html
195 -rw-r--r--···0·root·········(0)·root·········(0)···314193·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/searchindex.js195 -rw-r--r--···0·root·········(0)·root·········(0)···314190·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/searchindex.js
196 -rw-r--r--···0·root·········(0)·root·········(0)·····8017·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-advanced.html196 -rw-r--r--···0·root·········(0)·root·········(0)·····8017·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-advanced.html
197 -rw-r--r--···0·root·········(0)·root·········(0)····31484·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-data-mining.html197 -rw-r--r--···0·root·········(0)·root·········(0)····31484·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-data-mining.html
198 -rw-r--r--···0·root·········(0)·root·········(0)····77416·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-examples.html198 -rw-r--r--···0·root·········(0)·root·········(0)····77416·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-examples.html
199 -rw-r--r--···0·root·········(0)·root·········(0)····29152·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-geo.html199 -rw-r--r--···0·root·········(0)·root·········(0)····29203·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-geo.html
200 -rw-r--r--···0·root·········(0)·root·········(0)····67239·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-hands-on.html200 -rw-r--r--···0·root·········(0)·root·········(0)····67237·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-hands-on.html
201 -rw-r--r--···0·root·········(0)·root·········(0)·····5670·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-introduction.html201 -rw-r--r--···0·root·········(0)·root·········(0)·····5670·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial-introduction.html
202 -rw-r--r--···0·root·········(0)·root·········(0)·····9600·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial.html202 -rw-r--r--···0·root·········(0)·root·········(0)·····9600·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/tutorial.html
203 -rw-r--r--···0·root·········(0)·root·········(0)···254353·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/user.html203 -rw-r--r--···0·root·········(0)·root·········(0)···254363·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/user.html
204 -rw-r--r--···0·root·········(0)·root·········(0)····12799·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.bodiesHandling.html204 -rw-r--r--···0·root·········(0)·root·········(0)····12799·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.bodiesHandling.html
205 -rw-r--r--···0·root·········(0)·root·········(0)····29221·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.export.html205 -rw-r--r--···0·root·········(0)·root·········(0)····29221·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.export.html
206 -rw-r--r--···0·root·········(0)·root·········(0)····25833·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.geom.html206 -rw-r--r--···0·root·········(0)·root·········(0)····25833·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.geom.html
207 -rw-r--r--···0·root·········(0)·root·········(0)····38047·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.gridpfacet.html207 -rw-r--r--···0·root·········(0)·root·········(0)····38047·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.gridpfacet.html
208 -rw-r--r--···0·root·········(0)·root·········(0)····10135·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.linterpolation.html208 -rw-r--r--···0·root·········(0)·root·········(0)····10135·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.linterpolation.html
209 -rw-r--r--···0·root·········(0)·root·········(0)····93422·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.pack.html209 -rw-r--r--···0·root·········(0)·root·········(0)····93422·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.pack.html
210 -rw-r--r--···0·root·········(0)·root·········(0)····36495·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.plot.html210 -rw-r--r--···0·root·········(0)·root·········(0)····36495·2019-01-30·18:41:45.000000·./usr/share/doc/yade/html/yade.plot.html
15.3 KB
./usr/share/doc/yade/html/introduction.html
    
Offset 240, 27 lines modifiedOffset 240, 27 lines modified
240 </div>240 </div>
241 <p>Normal·simulations,·however,·are·run·continuously.·Starting/stopping·the·loop·is·done·by·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">O.pause()</span></code>;·note·that·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·returns·control·to·Python·and·the·simulation·runs·in·background;·if·you·want·to·wait·for·it·finish,·use·<code·class="docutils·literal·notranslate"><span·class="pre">O.wait()</span></code>.·Fixed·number·of·steps·can·be·run·with·<code·class="docutils·literal·notranslate"><span·class="pre">O.run(1000)</span></code>,·<code·class="docutils·literal·notranslate"><span·class="pre">O.run(1000,True)</span></code>·will·run·and·wait.·To·stop·at·absolute·step·number,·<code·class="docutils·literal·notranslate"><span·class="pre">O.stopAtIter</span></code>·can·be·set·and·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·called·normally.</p>241 <p>Normal·simulations,·however,·are·run·continuously.·Starting/stopping·the·loop·is·done·by·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">O.pause()</span></code>;·note·that·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·returns·control·to·Python·and·the·simulation·runs·in·background;·if·you·want·to·wait·for·it·finish,·use·<code·class="docutils·literal·notranslate"><span·class="pre">O.wait()</span></code>.·Fixed·number·of·steps·can·be·run·with·<code·class="docutils·literal·notranslate"><span·class="pre">O.run(1000)</span></code>,·<code·class="docutils·literal·notranslate"><span·class="pre">O.run(1000,True)</span></code>·will·run·and·wait.·To·stop·at·absolute·step·number,·<code·class="docutils·literal·notranslate"><span·class="pre">O.stopAtIter</span></code>·can·be·set·and·<code·class="docutils·literal·notranslate"><span·class="pre">O.run()</span></code>·called·normally.</p>
242 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[9]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">()</span>242 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[9]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">()</span>
  
243 <span·class="gp">Yade·[10]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">pause</span><span·class="p">()</span>243 <span·class="gp">Yade·[10]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">pause</span><span·class="p">()</span>
  
244 <span·class="gp">Yade·[11]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>244 <span·class="gp">Yade·[11]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>
245 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">11</span><span·class="p">]:</span>·<span·class="mi">1742</span>245 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">11</span><span·class="p">]:</span>·<span·class="mi">2385</span>
  
246 <span·class="gp">Yade·[12]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">(</span><span·class="mi">100000</span><span·class="p">,</span><span·class="bp">True</span><span·class="p">)</span>246 <span·class="gp">Yade·[12]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">(</span><span·class="mi">100000</span><span·class="p">,</span><span·class="bp">True</span><span·class="p">)</span>
  
247 <span·class="gp">Yade·[13]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>247 <span·class="gp">Yade·[13]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>
248 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">13</span><span·class="p">]:</span>·<span·class="mi">101742</span>248 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">13</span><span·class="p">]:</span>·<span·class="mi">102385</span>
  
249 <span·class="gp">Yade·[14]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">stopAtIter</span><span·class="o">=</span><span·class="mi">500000</span>249 <span·class="gp">Yade·[14]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">stopAtIter</span><span·class="o">=</span><span·class="mi">500000</span>
  
250 <span·class="gp">Yade·[15]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">wait</span><span·class="p">()</span>250 <span·class="gp">Yade·[15]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">wait</span><span·class="p">()</span>
  
251 <span·class="gp">Yade·[16]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>251 <span·class="gp">Yade·[16]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">iter</span>
252 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">16</span><span·class="p">]:</span>·<span·class="mi">101742</span>252 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">16</span><span·class="p">]:</span>·<span·class="mi">102385</span>
253 </pre></div>253 </pre></div>
254 </div>254 </div>
255 </div>255 </div>
256 <div·class="section"·id="saving-and-loading">256 <div·class="section"·id="saving-and-loading">
257 <h3>Saving·and·loading<a·class="headerlink"·href="#saving-and-loading"·title="Permalink·to·this·headline">¶</a></h3>257 <h3>Saving·and·loading<a·class="headerlink"·href="#saving-and-loading"·title="Permalink·to·this·headline">¶</a></h3>
258 <p>Simulation·can·be·saved·at·any·point·to·a·binary·file·(optionaly·compressed·if·the·filename·has·extensions·such·as·“.gz”·or·“.bz2”).258 <p>Simulation·can·be·saved·at·any·point·to·a·binary·file·(optionaly·compressed·if·the·filename·has·extensions·such·as·“.gz”·or·“.bz2”).
259 Saving·to·a·XML·file·is·also·possible·though·resulting·in·larger·files·and·slower·save/load,·it·is·used·when·the·filename·contains·“xml”.·With·some·limitations,259 Saving·to·a·XML·file·is·also·possible·though·resulting·in·larger·files·and·slower·save/load,·it·is·used·when·the·filename·contains·“xml”.·With·some·limitations,
Offset 310, 15 lines modifiedOffset 310, 15 lines modified
310 <h2>Architecture·overview<a·class="headerlink"·href="#architecture-overview"·title="Permalink·to·this·headline">¶</a></h2>310 <h2>Architecture·overview<a·class="headerlink"·href="#architecture-overview"·title="Permalink·to·this·headline">¶</a></h2>
311 <p>In·the·following,·a·high-level·overview·of·Yade·architecture·will·be·given.·As·many·of·the·features·are·directly·represented·in·simulation·scripts,·which·are·written·in·Python,·being·familiar·with·this·language·will·help·you·follow·the·examples.·For·the·rest,·this·knowledge·is·not·strictly·necessary·and·you·can·ignore·code·examples.</p>311 <p>In·the·following,·a·high-level·overview·of·Yade·architecture·will·be·given.·As·many·of·the·features·are·directly·represented·in·simulation·scripts,·which·are·written·in·Python,·being·familiar·with·this·language·will·help·you·follow·the·examples.·For·the·rest,·this·knowledge·is·not·strictly·necessary·and·you·can·ignore·code·examples.</p>
312 <div·class="section"·id="data-and-functions">312 <div·class="section"·id="data-and-functions">
313 <h3>Data·and·functions<a·class="headerlink"·href="#data-and-functions"·title="Permalink·to·this·headline">¶</a></h3>313 <h3>Data·and·functions<a·class="headerlink"·href="#data-and-functions"·title="Permalink·to·this·headline">¶</a></h3>
314 <p>To·assure·flexibility·of·software·design,·yade·makes·clear·distinction·of·2·families·of·classes:·<em>data</em>·components·and·<em>functional</em>·components.·The·former·only·store·data·without·providing·functionality,·while·the·latter·define·functions·operating·on·the·data.·In·programming,·this·is·known·as·<em>visitor</em>·pattern·(as·functional·components·“visit”·the·data,·without·being·bound·to·them·explicitly).</p>314 <p>To·assure·flexibility·of·software·design,·yade·makes·clear·distinction·of·2·families·of·classes:·<em>data</em>·components·and·<em>functional</em>·components.·The·former·only·store·data·without·providing·functionality,·while·the·latter·define·functions·operating·on·the·data.·In·programming,·this·is·known·as·<em>visitor</em>·pattern·(as·functional·components·“visit”·the·data,·without·being·bound·to·them·explicitly).</p>
315 <p>Entire·simulation,·i.e.·both·data·and·functions,·are·stored·in·a·single·<code·class="docutils·literal·notranslate"><span·class="pre">Scene</span></code>·object.·It·is·accessible·through·the·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega">Omega</a>·class·in·python·(a·singleton),·which·is·by·default·stored·in·the·<code·class="docutils·literal·notranslate"><span·class="pre">O</span></code>·global·variable:</p>315 <p>Entire·simulation,·i.e.·both·data·and·functions,·are·stored·in·a·single·<code·class="docutils·literal·notranslate"><span·class="pre">Scene</span></code>·object.·It·is·accessible·through·the·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega">Omega</a>·class·in·python·(a·singleton),·which·is·by·default·stored·in·the·<code·class="docutils·literal·notranslate"><span·class="pre">O</span></code>·global·variable:</p>
316 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[24]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span>·······<span·class="c1">#·some·data·components</span>316 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[24]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span>·······<span·class="c1">#·some·data·components</span>
317 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">24</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">wrapper</span><span·class="o">.</span><span·class="n">BodyContainer</span>·<span·class="n">at</span>·<span·class="mh">0x7ff04485a2a8</span><span·class="o">&gt;</span>317 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">24</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">wrapper</span><span·class="o">.</span><span·class="n">BodyContainer</span>·<span·class="n">at</span>·<span·class="mh">0x7f27983bb2a8</span><span·class="o">&gt;</span>
  
318 <span·class="gp">Yade·[25]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">)</span>··<span·class="c1">#·there·are·no·bodies·as·of·yet</span>318 <span·class="gp">Yade·[25]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">)</span>··<span·class="c1">#·there·are·no·bodies·as·of·yet</span>
319 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">25</span><span·class="p">]:</span>·<span·class="mi">0</span>319 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">25</span><span·class="p">]:</span>·<span·class="mi">0</span>
  
320 <span·class="gp">Yade·[26]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span>······<span·class="c1">#·functional·components,·empty·at·the·moment</span>320 <span·class="gp">Yade·[26]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span>······<span·class="c1">#·functional·components,·empty·at·the·moment</span>
321 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">26</span><span·class="p">]:</span>·<span·class="p">[]</span>321 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">26</span><span·class="p">]:</span>·<span·class="p">[]</span>
322 </pre></div>322 </pre></div>
Offset 344, 17 lines modifiedOffset 344, 17 lines modified
344 <p>(In·addition·to·these·4·components,·bodies·have·several·more·minor·data·associated,·such·as·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.id">Body::id</a>·or·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.mask">Body::mask</a>.)</p>344 <p>(In·addition·to·these·4·components,·bodies·have·several·more·minor·data·associated,·such·as·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.id">Body::id</a>·or·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.mask">Body::mask</a>.)</p>
345 <p>All·these·four·properties·can·be·of·different·types,·derived·from·their·respective·base·types.·Yade·frequently·makes·decisions·about·computation·based·on·those·types:·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·+·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·collision·has·to·be·treated·differently·than·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Facet">Facet</a>·+·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·collision.·Objects·making·those·decisions·are·called·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Dispatcher">Dispatcher</a>’s·and·are·essential·to·understand·Yade’s·functioning;·they·are·discussed·below.</p>345 <p>All·these·four·properties·can·be·of·different·types,·derived·from·their·respective·base·types.·Yade·frequently·makes·decisions·about·computation·based·on·those·types:·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·+·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·collision·has·to·be·treated·differently·than·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Facet">Facet</a>·+·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Sphere">Sphere</a>·collision.·Objects·making·those·decisions·are·called·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Dispatcher">Dispatcher</a>’s·and·are·essential·to·understand·Yade’s·functioning;·they·are·discussed·below.</p>
346 <p>Explicitly·assigning·all·4·properties·to·each·particle·by·hand·would·be·not·practical;·there·are·utility·functions·defined·to·create·them·with·all·necessary·ingredients.·For·example,·we·can·create·sphere·particle·using·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>:</p>346 <p>Explicitly·assigning·all·4·properties·to·each·particle·by·hand·would·be·not·practical;·there·are·utility·functions·defined·to·create·them·with·all·necessary·ingredients.·For·example,·we·can·create·sphere·particle·using·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>:</p>
347 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[27]:·</span><span·class="n">s</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">(</span><span·class="n">center</span><span·class="o">=</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">],</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">)</span>347 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[27]:·</span><span·class="n">s</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">(</span><span·class="n">center</span><span·class="o">=</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">],</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">)</span>
  
348 <span·class="gp">Yade·[28]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">mat</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">bound</span>348 <span·class="gp">Yade·[28]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">mat</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">bound</span>
349 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">28</span><span·class="p">]:</span>·349 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">28</span><span·class="p">]:</span>·
350 <span·class="go">(&lt;Sphere·instance·at·0x5587228eaa80&gt;,</span>350 <span·class="go">(&lt;Sphere·instance·at·0x565178b227a0&gt;,</span>
351 <span·class="go">·&lt;State·instance·at·0x5587245c81c0&gt;,</span>351 <span·class="go">·&lt;State·instance·at·0x56517a524720&gt;,</span>
352 <span·class="go">·&lt;FrictMat·instance·at·0x558723d415e0&gt;,</span>352 <span·class="go">·&lt;FrictMat·instance·at·0x56517a266eb0&gt;,</span>
353 <span·class="go">·None)</span>353 <span·class="go">·None)</span>
  
354 <span·class="gp">Yade·[29]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">pos</span>354 <span·class="gp">Yade·[29]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">pos</span>
355 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">29</span><span·class="p">]:</span>·<span·class="n">Vector3</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">)</span>355 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">29</span><span·class="p">]:</span>·<span·class="n">Vector3</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">)</span>
  
356 <span·class="gp">Yade·[30]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>356 <span·class="gp">Yade·[30]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>
357 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">30</span><span·class="p">]:</span>·<span·class="mf">1.0</span>357 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">30</span><span·class="p">]:</span>·<span·class="mf">1.0</span>
Offset 413, 29 lines modifiedOffset 413, 29 lines modified
413 <dd>representing·non-geometrical·features·of·the·interaction;·some·are·computed·from·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Materials</a>·of·the·particles·in·contact·using·some·averaging·algorithm·(such·as·contact·stiffness·from·Young’s·moduli·of·particles),·others·might·be·internal·variables·like·damage.</dd>413 <dd>representing·non-geometrical·features·of·the·interaction;·some·are·computed·from·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Materials</a>·of·the·particles·in·contact·using·some·averaging·algorithm·(such·as·contact·stiffness·from·Young’s·moduli·of·particles),·others·might·be·internal·variables·like·damage.</dd>
414 </dl>414 </dl>
415 <p>Suppose·now·interactions·have·been·already·created.·We·can·access·them·by·the·id·pair:</p>415 <p>Suppose·now·interactions·have·been·already·created.·We·can·access·them·by·the·id·pair:</p>
416 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span>416 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span>
417 </pre></div>417 </pre></div>
418 </div>418 </div>
419 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[37]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">]</span>419 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[37]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">]</span>
420 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">37</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Interaction</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558722aca390</span><span·class="o">&gt;</span>420 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">37</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Interaction</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x565178b1e110</span><span·class="o">&gt;</span>
  
421 <span·class="gp">Yade·[38]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">]</span>·····<span·class="c1">#·order·of·ids·is·not·important</span>421 <span·class="gp">Yade·[38]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">]</span>·····<span·class="c1">#·order·of·ids·is·not·important</span>
422 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">38</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Interaction</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558722aca390</span><span·class="o">&gt;</span>422 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">38</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Interaction</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x565178b1e110</span><span·class="o">&gt;</span>
  
423 <span·class="gp">Yade·[39]:·</span><span·class="n">i</span><span·class="o">=</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">]</span>423 <span·class="gp">Yade·[39]:·</span><span·class="n">i</span><span·class="o">=</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">]</span>
  
424 <span·class="gp">Yade·[40]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">id1</span><span·class="p">,</span><span·class="n">i</span><span·class="o">.</span><span·class="n">id2</span>424 <span·class="gp">Yade·[40]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">id1</span><span·class="p">,</span><span·class="n">i</span><span·class="o">.</span><span·class="n">id2</span>
425 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">40</span><span·class="p">]:</span>·<span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span>·<span·class="mi">1</span><span·class="p">)</span>425 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">40</span><span·class="p">]:</span>·<span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span>·<span·class="mi">1</span><span·class="p">)</span>
  
426 <span·class="gp">Yade·[41]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">geom</span>426 <span·class="gp">Yade·[41]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">geom</span>
427 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">41</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">ScGeom</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x5587245b64f0</span><span·class="o">&gt;</span>427 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">41</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">ScGeom</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517a51a1c0</span><span·class="o">&gt;</span>
  
428 <span·class="gp">Yade·[42]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">phys</span>428 <span·class="gp">Yade·[42]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">phys</span>
429 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">42</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">FrictPhys</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x5587244de790</span><span·class="o">&gt;</span>429 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">42</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">FrictPhys</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517a469fa0</span><span·class="o">&gt;</span>
  
430 <span·class="gp">Yade·[43]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">100</span><span·class="p">,</span><span·class="mi">10111</span><span·class="p">]</span>430 <span·class="gp">Yade·[43]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">interactions</span><span·class="p">[</span><span·class="mi">100</span><span·class="p">,</span><span·class="mi">10111</span><span·class="p">]</span>
  
431 <span·class="go">IndexErrorTraceback·(most·recent·call·last)</span>431 <span·class="go">IndexErrorTraceback·(most·recent·call·last)</span>
432 <span·class="go">/build/yade-2019.01a/debian/tmp/usr/lib/x86_64-linux-gnu/yade/py/yade/__init__.pyc·in·&lt;module&gt;()</span>432 <span·class="go">/build/yade-2019.01a/debian/tmp/usr/lib/x86_64-linux-gnu/yade/py/yade/__init__.pyc·in·&lt;module&gt;()</span>
433 <span·class="go">----&gt;·1·O.interactions[100,10111]</span>433 <span·class="go">----&gt;·1·O.interactions[100,10111]</span>
  
9.16 KB
./usr/share/doc/yade/html/prog.html
    
Offset 718, 19 lines modifiedOffset 718, 19 lines modified
718 »       »       <span·class="nt">&lt;trackEnergy&gt;</span>0<span·class="nt">&lt;/trackEnergy&gt;</span>718 »       »       <span·class="nt">&lt;trackEnergy&gt;</span>0<span·class="nt">&lt;/trackEnergy&gt;</span>
719 »       »       <span·class="nt">&lt;doSort&gt;</span>0<span·class="nt">&lt;/doSort&gt;</span>719 »       »       <span·class="nt">&lt;doSort&gt;</span>0<span·class="nt">&lt;/doSort&gt;</span>
720 »       »       <span·class="nt">&lt;runInternalConsistencyChecks&gt;</span>1<span·class="nt">&lt;/runInternalConsistencyChecks&gt;</span>720 »       »       <span·class="nt">&lt;runInternalConsistencyChecks&gt;</span>1<span·class="nt">&lt;/runInternalConsistencyChecks&gt;</span>
721 »       »       <span·class="nt">&lt;selectedBody&gt;</span>-1<span·class="nt">&lt;/selectedBody&gt;</span>721 »       »       <span·class="nt">&lt;selectedBody&gt;</span>-1<span·class="nt">&lt;/selectedBody&gt;</span>
722 »       »       <span·class="nt">&lt;tags</span>·<span·class="na">class_id=</span><span·class="s">&quot;3&quot;</span>·<span·class="na">tracking_level=</span><span·class="s">&quot;0&quot;</span>·<span·class="na">version=</span><span·class="s">&quot;0&quot;</span><span·class="nt">&gt;</span>722 »       »       <span·class="nt">&lt;tags</span>·<span·class="na">class_id=</span><span·class="s">&quot;3&quot;</span>·<span·class="na">tracking_level=</span><span·class="s">&quot;0&quot;</span>·<span·class="na">version=</span><span·class="s">&quot;0&quot;</span><span·class="nt">&gt;</span>
723 »       »       »       <span·class="nt">&lt;count&gt;</span>5<span·class="nt">&lt;/count&gt;</span>723 »       »       »       <span·class="nt">&lt;count&gt;</span>5<span·class="nt">&lt;/count&gt;</span>
724 »       »       »       <span·class="nt">&lt;item_version&gt;</span>0<span·class="nt">&lt;/item_version&gt;</span>724 »       »       »       <span·class="nt">&lt;item_version&gt;</span>0<span·class="nt">&lt;/item_version&gt;</span>
725 »       »       »       <span·class="nt">&lt;item&gt;</span>author=root~(root@ionos5-amd64)<span·class="nt">&lt;/item&gt;</span>725 »       »       »       <span·class="nt">&lt;item&gt;</span>author=root~(root@i-capture-the-hostname)<span·class="nt">&lt;/item&gt;</span>
726 »       »       »       <span·class="nt">&lt;item&gt;</span>isoTime=20230121T183041<span·class="nt">&lt;/item&gt;</span>726 »       »       »       <span·class="nt">&lt;item&gt;</span>isoTime=20211220T205938<span·class="nt">&lt;/item&gt;</span>
727 »       »       »       <span·class="nt">&lt;item&gt;</span>id=20230121T183041p2799986<span·class="nt">&lt;/item&gt;</span>727 »       »       »       <span·class="nt">&lt;item&gt;</span>id=20211220T205938p2605508<span·class="nt">&lt;/item&gt;</span>
728 »       »       »       <span·class="nt">&lt;item&gt;</span>d.id=20230121T183041p2799986<span·class="nt">&lt;/item&gt;</span>728 »       »       »       <span·class="nt">&lt;item&gt;</span>d.id=20211220T205938p2605508<span·class="nt">&lt;/item&gt;</span>
729 »       »       »       <span·class="nt">&lt;item&gt;</span>id.d=20230121T183041p2799986<span·class="nt">&lt;/item&gt;</span>729 »       »       »       <span·class="nt">&lt;item&gt;</span>id.d=20211220T205938p2605508<span·class="nt">&lt;/item&gt;</span>
730 »       »       <span·class="nt">&lt;/tags&gt;</span>730 »       »       <span·class="nt">&lt;/tags&gt;</span>
731 »       »       <span·class="nt">&lt;engines</span>·<span·class="na">class_id=</span><span·class="s">&quot;4&quot;</span>·<span·class="na">tracking_level=</span><span·class="s">&quot;0&quot;</span>·<span·class="na">version=</span><span·class="s">&quot;0&quot;</span><span·class="nt">&gt;</span>731 »       »       <span·class="nt">&lt;engines</span>·<span·class="na">class_id=</span><span·class="s">&quot;4&quot;</span>·<span·class="na">tracking_level=</span><span·class="s">&quot;0&quot;</span>·<span·class="na">version=</span><span·class="s">&quot;0&quot;</span><span·class="nt">&gt;</span>
732 »       »       »       <span·class="nt">&lt;count&gt;</span>0<span·class="nt">&lt;/count&gt;</span>732 »       »       »       <span·class="nt">&lt;count&gt;</span>0<span·class="nt">&lt;/count&gt;</span>
733 »       »       »       <span·class="nt">&lt;item_version&gt;</span>1<span·class="nt">&lt;/item_version&gt;</span>733 »       »       »       <span·class="nt">&lt;item_version&gt;</span>1<span·class="nt">&lt;/item_version&gt;</span>
734 »       »       <span·class="nt">&lt;/engines&gt;</span>734 »       »       <span·class="nt">&lt;/engines&gt;</span>
735 »       »       <span·class="nt">&lt;_nextEngines&gt;</span>735 »       »       <span·class="nt">&lt;_nextEngines&gt;</span>
736 »       »       »       <span·class="nt">&lt;count&gt;</span>0<span·class="nt">&lt;/count&gt;</span>736 »       »       »       <span·class="nt">&lt;count&gt;</span>0<span·class="nt">&lt;/count&gt;</span>
Offset 1322, 15 lines modifiedOffset 1322, 15 lines modified
1322 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[22]:·</span><span·class="n">ld</span><span·class="o">=</span><span·class="n">LawDispatcher</span><span·class="p">([</span><span·class="n">Law2_ScGeom_CpmPhys_Cpm</span><span·class="p">()])</span>1322 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[22]:·</span><span·class="n">ld</span><span·class="o">=</span><span·class="n">LawDispatcher</span><span·class="p">([</span><span·class="n">Law2_ScGeom_CpmPhys_Cpm</span><span·class="p">()])</span>
  
1323 <span·class="gp">Yade·[23]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispMatrix</span><span·class="p">()</span>1323 <span·class="gp">Yade·[23]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispMatrix</span><span·class="p">()</span>
1324 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">23</span><span·class="p">]:</span>·<span·class="p">{(</span><span·class="s1">&#39;GenericSpheresContact&#39;</span><span·class="p">,</span>·<span·class="s1">&#39;CpmPhys&#39;</span><span·class="p">):</span>·<span·class="s1">&#39;Law2_ScGeom_CpmPhys_Cpm&#39;</span><span·class="p">}</span>1324 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">23</span><span·class="p">]:</span>·<span·class="p">{(</span><span·class="s1">&#39;GenericSpheresContact&#39;</span><span·class="p">,</span>·<span·class="s1">&#39;CpmPhys&#39;</span><span·class="p">):</span>·<span·class="s1">&#39;Law2_ScGeom_CpmPhys_Cpm&#39;</span><span·class="p">}</span>
  
1325 <span·class="c">#·see·how·the·entry·for·ScGridCoGeom·will·be·filled·after·this·request</span>1325 <span·class="c">#·see·how·the·entry·for·ScGridCoGeom·will·be·filled·after·this·request</span>
1326 <span·class="gp">Yade·[24]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispFunctor</span><span·class="p">(</span><span·class="n">ScGridCoGeom</span><span·class="p">(),</span><span·class="n">CpmPhys</span><span·class="p">())</span>1326 <span·class="gp">Yade·[24]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispFunctor</span><span·class="p">(</span><span·class="n">ScGridCoGeom</span><span·class="p">(),</span><span·class="n">CpmPhys</span><span·class="p">())</span>
1327 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">24</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Law2_ScGeom_CpmPhys_Cpm</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x55872424db70</span><span·class="o">&gt;</span>1327 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">24</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Law2_ScGeom_CpmPhys_Cpm</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517a730b70</span><span·class="o">&gt;</span>
  
1328 <span·class="gp">Yade·[25]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispMatrix</span><span·class="p">()</span>1328 <span·class="gp">Yade·[25]:·</span><span·class="n">ld</span><span·class="o">.</span><span·class="n">dispMatrix</span><span·class="p">()</span>
1329 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">25</span><span·class="p">]:</span>·1329 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">25</span><span·class="p">]:</span>·
1330 <span·class="go">{(&#39;GenericSpheresContact&#39;,·&#39;CpmPhys&#39;):·&#39;Law2_ScGeom_CpmPhys_Cpm&#39;,</span>1330 <span·class="go">{(&#39;GenericSpheresContact&#39;,·&#39;CpmPhys&#39;):·&#39;Law2_ScGeom_CpmPhys_Cpm&#39;,</span>
1331 <span·class="go">·(&#39;ScGridCoGeom&#39;,·&#39;CpmPhys&#39;):·&#39;Law2_ScGeom_CpmPhys_Cpm&#39;}</span>1331 <span·class="go">·(&#39;ScGridCoGeom&#39;,·&#39;CpmPhys&#39;):·&#39;Law2_ScGeom_CpmPhys_Cpm&#39;}</span>
1332 </pre></div>1332 </pre></div>
1333 </div>1333 </div>
Offset 1448, 22 lines modifiedOffset 1448, 22 lines modified
1448 <span·class="gp">Yade·[31]:·</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">timing</span><span·class="o">.</span><span·class="n">reset</span><span·class="p">()</span>···················<span·class="c1">##·not·necessary·if·used·for·the·first·time</span>1448 <span·class="gp">Yade·[31]:·</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">timing</span><span·class="o">.</span><span·class="n">reset</span><span·class="p">()</span>···················<span·class="c1">##·not·necessary·if·used·for·the·first·time</span>
  
1449 <span·class="gp">Yade·[32]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">(</span><span·class="mi">50</span><span·class="p">);</span>·<span·class="n">O</span><span·class="o">.</span><span·class="n">wait</span><span·class="p">()</span>1449 <span·class="gp">Yade·[32]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">run</span><span·class="p">(</span><span·class="mi">50</span><span·class="p">);</span>·<span·class="n">O</span><span·class="o">.</span><span·class="n">wait</span><span·class="p">()</span>
  
1450 <span·class="gp">Yade·[33]:·</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">timing</span><span·class="o">.</span><span·class="n">stats</span><span·class="p">()</span>1450 <span·class="gp">Yade·[33]:·</span><span·class="n">yade</span><span·class="o">.</span><span·class="n">timing</span><span·class="o">.</span><span·class="n">stats</span><span·class="p">()</span>
1451 <span·class="go">Name····················································Count·················Time············Rel.·time</span>1451 <span·class="go">Name····················································Count·················Time············Rel.·time</span>
1452 <span·class="go">-------------------------------------------------------------------------------------------------------</span>1452 <span·class="go">-------------------------------------------------------------------------------------------------------</span>
1453 <span·class="go">&quot;firstEngine&quot;········································50················130us················1.31%······</span>1453 <span·class="go">&quot;firstEngine&quot;········································50················165us················1.32%······</span>
1454 <span·class="go">InsertionSortCollider································27···············2492us···············25.00%······</span>1454 <span·class="go">InsertionSortCollider································26···············2967us···············23.62%······</span>
1455 <span·class="go">InteractionLoop······································50···············5188us···············52.05%······</span>1455 <span·class="go">InteractionLoop······································50···············6650us···············52.93%······</span>
1456 <span·class="go">GlobalStiffnessTimeStepper····························2·················40us················0.40%······</span>1456 <span·class="go">GlobalStiffnessTimeStepper····························2·················47us················0.38%······</span>
1457 <span·class="go">TriaxialCompressionEngine····························50················665us················6.67%······</span>1457 <span·class="go">TriaxialCompressionEngine····························50················865us················6.89%······</span>
1458 <span·class="go">TriaxialStateRecorder·································3················229us················2.30%······</span>1458 <span·class="go">TriaxialStateRecorder·································3················399us················3.18%······</span>
1459 <span·class="go">NewtonIntegrator·····································50···············1222us···············12.27%······</span>1459 <span·class="go">NewtonIntegrator·····································50···············1468us···············11.69%······</span>
1460 <span·class="go">TOTAL·································································9968us··············100.00%······</span>1460 <span·class="go">TOTAL································································12564us··············100.00%······</span>
1461 </pre></div>1461 </pre></div>
1462 </div>1462 </div>
1463 <p>Exec·count·and·time·can·be·accessed·and·manipulated·through·<code·class="docutils·literal·notranslate"><span·class="pre">Engine::timingInfo</span></code>·from·c++·or·<code·class="docutils·literal·notranslate"><span·class="pre">Engine().execCount</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">Engine().execTime</span></code>·properties·in·Python.</p>1463 <p>Exec·count·and·time·can·be·accessed·and·manipulated·through·<code·class="docutils·literal·notranslate"><span·class="pre">Engine::timingInfo</span></code>·from·c++·or·<code·class="docutils·literal·notranslate"><span·class="pre">Engine().execCount</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">Engine().execTime</span></code>·properties·in·Python.</p>
1464 </div>1464 </div>
1465 <div·class="section"·id="in-engine-and-in-functor-timing">1465 <div·class="section"·id="in-engine-and-in-functor-timing">
1466 <h4>In-engine·and·in-functor·timing<a·class="headerlink"·href="#in-engine-and-in-functor-timing"·title="Permalink·to·this·headline">¶</a></h4>1466 <h4>In-engine·and·in-functor·timing<a·class="headerlink"·href="#in-engine-and-in-functor-timing"·title="Permalink·to·this·headline">¶</a></h4>
1467 <p>Timing·within·engines·(and·functors)·is·based·on·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.TimingDeltas">TimingDeltas</a>·class·which·is·by·default·instantiated·in·engines·and·functors·as·Engine::timingDeltas·and·Functor::timingDeltas·(<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Engine.timingDeltas">Engine.timingDeltas</a>·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Functor.timingDeltas">Functor.timingDeltas</a>·in·Python).·It·is·made·for·timing·loops·(functors’·loop·is·in·their·respective·dispatcher)·and·stores·cummulatively·time·differences·between·<em>checkpoints</em>.</p>1467 <p>Timing·within·engines·(and·functors)·is·based·on·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.TimingDeltas">TimingDeltas</a>·class·which·is·by·default·instantiated·in·engines·and·functors·as·Engine::timingDeltas·and·Functor::timingDeltas·(<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Engine.timingDeltas">Engine.timingDeltas</a>·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Functor.timingDeltas">Functor.timingDeltas</a>·in·Python).·It·is·made·for·timing·loops·(functors’·loop·is·in·their·respective·dispatcher)·and·stores·cummulatively·time·differences·between·<em>checkpoints</em>.</p>
6.47 KB
./usr/share/doc/yade/html/searchindex.js
6.4 KB
js-beautify {}
    
Offset 7481, 55 lines modifiedOffset 7481, 56 lines modified
7481 ········"0x00007f0fcd0b4b23":·28,7481 ········"0x00007f0fcd0b4b23":·28,
7482 ········"0x00007f0fcd87ed57":·28,7482 ········"0x00007f0fcd87ed57":·28,
7483 ········"0x00007f0fcd88c7e9":·28,7483 ········"0x00007f0fcd88c7e9":·28,
7484 ········"0x00007f0fcd88cb20":·28,7484 ········"0x00007f0fcd88cb20":·28,
7485 ········"0x00007f0fcd8f4f7d":·28,7485 ········"0x00007f0fcd8f4f7d":·28,
7486 ········"0x1c54620":·28,7486 ········"0x1c54620":·28,
7487 ········"0x2d06770":·18,7487 ········"0x2d06770":·18,
 7488 ········"0x565178b1e110":·16,
7488 ········"0x5587228eaa80":·16,7489 ········"0x565178b227a0":·16,
7489 ········"0x558722aca390":·16, 
7490 ········"0x558723d415e0":·16,7490 ········"0x56517a266eb0":·16,
7491 ········"0x55872424db70":·18, 
7492 ········"0x55872434a2c0":·26, 
7493 ········"0x5587244de790":·16, 
7494 ········"0x558724509050":·26, 
7495 ········"0x55872459e7c0":·26,7491 ········"0x56517a457360":·26,
7496 ········"0x5587245b64f0":·16,7492 ········"0x56517a469fa0":·16,
7497 ········"0x5587245c81c0":·16, 
7498 ········"0x558724cbffa0":·26, 
7499 ········"0x558724ce93d0":·28, 
7500 ········"0x558724d01f30":·26, 
7501 ········"0x558724d2bc90":·28,7493 ········"0x56517a4a5dc0":·28,
 7494 ········"0x56517a4f5cc0":·26,
 7495 ········"0x56517a51a1c0":·16,
 7496 ········"0x56517a524720":·16,
 7497 ········"0x56517a5b3db0":·26,
 7498 ········"0x56517a72b590":·26,
 7499 ········"0x56517a730b70":·18,
 7500 ········"0x56517a769420":·26,
7502 ········"0x558724dc8290":·28,7501 ········"0x56517aedc570":·28,
 7502 ········"0x56517af44a20":·28,
7503 ········"0x7f0fb1268710":·28,7503 ········"0x7f0fb1268710":·28,
7504 ········"0x7f0fb29f2710":·28,7504 ········"0x7f0fb29f2710":·28,
7505 ········"0x7f0fb31f3710":·28,7505 ········"0x7f0fb31f3710":·28,
7506 ········"0x7f0fcee53700":·28,7506 ········"0x7f0fcee53700":·28,
7507 ········"0x7ff04485a2a8":·16,7507 ········"0x7f27983bb2a8":·16,
7508 ········"100mpa":·41,7508 ········"100mpa":·41,
7509 ········"102077490\u03bc":·18,7509 ········"102077490\u03bc":·18,
7510 ········"10571887u":·39,7510 ········"10571887u":·39,
7511 ········"10700007\u03bc":·18,7511 ········"10700007\u03bc":·18,
7512 ········"10733564u":·39,7512 ········"10733564u":·39,
7513 ········"10e6":·41,7513 ········"10e6":·41,
7514 ········"10e9":·40,7514 ········"10e9":·40,
7515 ········"10gb":·15,7515 ········"10gb":·15,
7516 ········"10k":·1,7516 ········"10k":·1,
7517 ········"10kpa":·25,7517 ········"10kpa":·25,
7518 ········"1157u":·39,7518 ········"1157u":·39,
7519 ········"1171770\u03bc":·18,7519 ········"1171770\u03bc":·18,
7520 ········"1222u":·18,7520 ········"12564u":·18,
7521 ········"12_2":·7,7521 ········"12_2":·7,
7522 ········"12th":·19,7522 ········"12th":·19,
7523 ········"130u":·18, 
7524 ········"136u":·39,7523 ········"136u":·39,
7525 ········"13th":·19,7524 ········"13th":·19,
7526 ········"1423738u":·39,7525 ········"1423738u":·39,
 7526 ········"1468u":·18,
7527 ········"15177607\u03bc":·18,7527 ········"15177607\u03bc":·18,
7528 ········"1594300u":·39,7528 ········"1594300u":·39,
 7529 ········"165u":·18,
7529 ········"16th":·19,7530 ········"16th":·19,
7530 ········"1723168u":·39,7531 ········"1723168u":·39,
7531 ········"1801250u":·39,7532 ········"1801250u":·39,
7532 ········"1866816\u03bc":·18,7533 ········"1866816\u03bc":·18,
7533 ········"19th":·19,7534 ········"19th":·19,
7534 ········"1_2":·7,7535 ········"1_2":·7,
7535 ········"1_util":·1,7536 ········"1_util":·1,
Offset 7545, 29 lines modifiedOffset 7546, 28 lines modified
7545 ········"1e9":·[30,·41],7546 ········"1e9":·[30,·41],
7546 ········"1st":·[18,·19,·20,·40,·41],7547 ········"1st":·[18,·19,·20,·40,·41],
7547 ········"1styadeworkshop":·19,7548 ········"1styadeworkshop":·19,
7548 ········"2006jf000536":·20,7549 ········"2006jf000536":·20,
7549 ········"200k":·1,7550 ········"200k":·1,
7550 ········"20100413t144723p7625":·28,7551 ········"20100413t144723p7625":·28,
7551 ········"2017wr021769":·19,7552 ········"2017wr021769":·19,
7552 ········"20230121t183041":·18, 
7553 ········"20230121t183041p2799986":·18,7553 ········"20211220t205938":·18,
 7554 ········"20211220t205938p2605508":·18,
7554 ········"20230121t183046":·28,7555 ········"20211220t205944":·28,
7555 ········"20230121t183046p2799986":·28,7556 ········"20211220t205944p2605508":·28,
7556 ········"20mpa":·41,7557 ········"20mpa":·41,
7557 ········"210e9":·28,7558 ········"210e9":·28,
7558 ········"2150u":·39,7559 ········"2150u":·39,
7559 ········"21589\u03bc":·18,7560 ········"21589\u03bc":·18,
7560 ········"229u":·18, 
7561 ········"2315bd8":·15,7561 ········"2315bd8":·15,
7562 ········"23216292\u03bc":·18,7562 ········"23216292\u03bc":·18,
7563 ········"246x":·19,7563 ········"246x":·19,
7564 ········"2492u":·18, 
7565 ········"26015u":·39,7564 ········"26015u":·39,
7566 ········"291u":·39,7565 ········"291u":·39,
 7566 ········"2967u":·18,
7567 ········"2\u00b9\u03c0":·19,7567 ········"2\u00b9\u03c0":·19,
7568 ········"2_2":·7,7568 ········"2_2":·7,
7569 ········"2_3":·7,7569 ········"2_3":·7,
7570 ········"2_4":·7,7570 ········"2_4":·7,
7571 ········"2e3":·[28,·40],7571 ········"2e3":·[28,·40],
7572 ········"2k_":·7,7572 ········"2k_":·7,
7573 ········"2k_i":·7,7573 ········"2k_i":·7,
Offset 7578, 59 lines modifiedOffset 7578, 59 lines modified
7578 ········"2xlarg":·4,7578 ········"2xlarg":·4,
7579 ········"30e9":·[28,·40],7579 ········"30e9":·[28,·40],
7580 ········"30k":·1,7580 ········"30k":·1,
7581 ········"3272\u03bc":·18,7581 ········"3272\u03bc":·18,
7582 ········"345uiysdijkn":·18,7582 ········"345uiysdijkn":·18,
7583 ········"352x":·20,7583 ········"352x":·20,
7584 ········"35th":·19,7584 ········"35th":·19,
 7585 ········"399u":·18,
7585 ········"3_356":·19,7586 ········"3_356":·19,
7586 ········"3e10":·28,7587 ········"3e10":·28,
7587 ········"3gb":·15,7588 ········"3gb":·15,
7588 ········"3rd":·[18,·19,·20],7589 ········"3rd":·[18,·19,·20],
7589 ········"3sr":·[8,·18,·28,·41],7590 ········"3sr":·[8,·18,·28,·41],
7590 ········"3x3":·[7,·18,·24],7591 ········"3x3":·[7,·18,·24],
7591 ········"40u":·18,7592 ········"47u":·18,
7592 ········"4819289u":·39,7593 ········"4819289u":·39,
7593 ········"4_1":·7,7594 ········"4_1":·7,
7594 ········"4gb":·40,7595 ········"4gb":·40,
7595 ········"4th":·[18,·40,·41],7596 ········"4th":·[18,·40,·41],
7596 ········"500mb":·40,7597 ········"500mb":·40,
7597 ········"50161117\u03bc":·18,7598 ········"50161117\u03bc":·18,
7598 ········"5188u":·18, 
7599 ········"5_0":·7,7599 ········"5_0":·7,
7600 ········"5dt":·41,7600 ········"5dt":·41,
7601 ········"5e5":·24,7601 ········"5e5":·24,
7602 ········"5e6":·3,7602 ········"5e6":·3,
7603 ········"5th":·[18,·19],7603 ········"5th":·[18,·19],
7604 ········"61th":·19,7604 ········"61th":·19,
Max diff block lines reached; 2748/6522 bytes (42.13%) of diff not shown.
7.07 KB
./usr/share/doc/yade/html/tutorial-geo.html
    
Offset 135, 18 lines modifiedOffset 135, 18 lines modified
135 <p>Periodic·boundary·is·a·“boundary”·created·by·using·periodic·(rather·than·infinite)·space.·Such·boundary·is·activated·by·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.periodic">O.periodic=True·</a>,·and·the·space·configuration·is·decribed·by·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.cell">O.cell·</a>.·It·is·well·suited·for·studying·bulk·material·behavior,·as·boundary·effects·are·avoided,·leading·to·smaller·number·of·particles.·On·the·other·hand,·it·might·not·be·suitable·for·studying·localization,·as·any·cell-level·effects·(such·as·shear·bands)·have·to·satisfy·periodicity·as·well.</p>135 <p>Periodic·boundary·is·a·“boundary”·created·by·using·periodic·(rather·than·infinite)·space.·Such·boundary·is·activated·by·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.periodic">O.periodic=True·</a>,·and·the·space·configuration·is·decribed·by·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.cell">O.cell·</a>.·It·is·well·suited·for·studying·bulk·material·behavior,·as·boundary·effects·are·avoided,·leading·to·smaller·number·of·particles.·On·the·other·hand,·it·might·not·be·suitable·for·studying·localization,·as·any·cell-level·effects·(such·as·shear·bands)·have·to·satisfy·periodicity·as·well.</p>
136 <p>The·periodic·cell·is·described·by·its·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.refSize">reference·size·</a>·of·box·aligned·with·global·axes,·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.trsf">current·transformation</a>,·which·can·capture·stretch,·shear·and·rotation.·Deformation·is·prescribed·via·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.velGrad">velocity·gradient</a>,·which·updates·the·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.trsf">transformation</a>·before·the·next·step.·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.homoDeform">Homothetic·deformation</a>·can·smear·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.velGrad">velocity·gradient</a>·accross·the·cell,·making·the·boundary·dissolve·in·the·whole·cell.</p>136 <p>The·periodic·cell·is·described·by·its·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.refSize">reference·size·</a>·of·box·aligned·with·global·axes,·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.trsf">current·transformation</a>,·which·can·capture·stretch,·shear·and·rotation.·Deformation·is·prescribed·via·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.velGrad">velocity·gradient</a>,·which·updates·the·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.trsf">transformation</a>·before·the·next·step.·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.homoDeform">Homothetic·deformation</a>·can·smear·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Cell.velGrad">velocity·gradient</a>·accross·the·cell,·making·the·boundary·dissolve·in·the·whole·cell.</p>
137 <p>Stress·and·strains·can·be·controlled·with·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController">PeriTriaxController</a>;·it·is·possible·to·prescribe·mixed·strain/stress·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.goal">goal</a>·state·using·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.stressMask">PeriTriaxController.stressMask</a>.</p>137 <p>Stress·and·strains·can·be·controlled·with·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController">PeriTriaxController</a>;·it·is·possible·to·prescribe·mixed·strain/stress·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.goal">goal</a>·state·using·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.stressMask">PeriTriaxController.stressMask</a>.</p>
138 <p>The·following·creates·periodic·cloud·of·spheres·and·compresses·to·achieve·<span·class="math·notranslate·nohighlight">\(\sigma_x\)</span>=-10·kPa,·<span·class="math·notranslate·nohighlight">\(\sigma_y\)</span>=-10kPa·and·<span·class="math·notranslate·nohighlight">\(\eps_z\)</span>=-0.1.·Since·stress·is·specified·for·<span·class="math·notranslate·nohighlight">\(y\)</span>·and·<span·class="math·notranslate·nohighlight">\(z\)</span>,·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.stressMask">stressMask</a>·is·<code·class="docutils·literal·notranslate"><span·class="pre">0b011</span></code>·(x→1,·y→2,·z→4,·in·decimal·1+2=3).</p>138 <p>The·following·creates·periodic·cloud·of·spheres·and·compresses·to·achieve·<span·class="math·notranslate·nohighlight">\(\sigma_x\)</span>=-10·kPa,·<span·class="math·notranslate·nohighlight">\(\sigma_y\)</span>=-10kPa·and·<span·class="math·notranslate·nohighlight">\(\eps_z\)</span>=-0.1.·Since·stress·is·specified·for·<span·class="math·notranslate·nohighlight">\(y\)</span>·and·<span·class="math·notranslate·nohighlight">\(z\)</span>,·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.stressMask">stressMask</a>·is·<code·class="docutils·literal·notranslate"><span·class="pre">0b011</span></code>·(x→1,·y→2,·z→4,·in·decimal·1+2=3).</p>
139 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[1]:·</span><span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>139 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[1]:·</span><span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>
  
140 <span·class="gp">Yade·[2]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">makeCloud</span><span·class="p">((</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">),(</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="n">rMean</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">periodic</span><span·class="o">=</span><span·class="bp">True</span><span·class="p">)</span>140 <span·class="gp">Yade·[2]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">makeCloud</span><span·class="p">((</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">),(</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="n">rMean</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">periodic</span><span·class="o">=</span><span·class="bp">True</span><span·class="p">)</span>
141 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">2</span><span·class="p">]:</span>·<span·class="mi">8</span>141 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">2</span><span·class="p">]:</span>·<span·class="mi">9</span>
  
142 <span·class="gp">Yade·[3]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">toSimulation</span><span·class="p">()</span>·············<span·class="c1">#·implicitly·sets·O.periodic=True,·and·O.cell.refSize·to·the·packing·period·size</span>142 <span·class="gp">Yade·[3]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">toSimulation</span><span·class="p">()</span>·············<span·class="c1">#·implicitly·sets·O.periodic=True,·and·O.cell.refSize·to·the·packing·period·size</span>
143 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">3</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">4</span><span·class="p">,</span>·<span·class="mi">5</span><span·class="p">,</span>·<span·class="mi">6</span><span·class="p">,</span>·<span·class="mi">7</span><span·class="p">,</span>·<span·class="mi">8</span><span·class="p">,</span>·<span·class="mi">9</span><span·class="p">,</span>·<span·class="mi">10</span><span·class="p">,</span>·<span·class="mi">11</span><span·class="p">]</span>143 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">3</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">4</span><span·class="p">,</span>·<span·class="mi">5</span><span·class="p">,</span>·<span·class="mi">6</span><span·class="p">,</span>·<span·class="mi">7</span><span·class="p">,</span>·<span·class="mi">8</span><span·class="p">,</span>·<span·class="mi">9</span><span·class="p">,</span>·<span·class="mi">10</span><span·class="p">,</span>·<span·class="mi">11</span><span·class="p">,</span>·<span·class="mi">12</span><span·class="p">]</span>
  
144 <span·class="gp">Yade·[4]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span><span·class="o">+=</span><span·class="p">[</span><span·class="n">PeriTriaxController</span><span·class="p">(</span><span·class="n">goal</span><span·class="o">=</span><span·class="p">(</span><span·class="o">-</span><span·class="mf">1e4</span><span·class="p">,</span><span·class="o">-</span><span·class="mf">1e4</span><span·class="p">,</span><span·class="o">-.</span><span·class="mi">1</span><span·class="p">),</span><span·class="n">stressMask</span><span·class="o">=</span><span·class="mb">0b011</span><span·class="p">,</span><span·class="n">maxUnbalanced</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">doneHook</span><span·class="o">=</span><span·class="s1">&#39;functionToRunWhenFinished()&#39;</span><span·class="p">)]</span>144 <span·class="gp">Yade·[4]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span><span·class="o">+=</span><span·class="p">[</span><span·class="n">PeriTriaxController</span><span·class="p">(</span><span·class="n">goal</span><span·class="o">=</span><span·class="p">(</span><span·class="o">-</span><span·class="mf">1e4</span><span·class="p">,</span><span·class="o">-</span><span·class="mf">1e4</span><span·class="p">,</span><span·class="o">-.</span><span·class="mi">1</span><span·class="p">),</span><span·class="n">stressMask</span><span·class="o">=</span><span·class="mb">0b011</span><span·class="p">,</span><span·class="n">maxUnbalanced</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">doneHook</span><span·class="o">=</span><span·class="s1">&#39;functionToRunWhenFinished()&#39;</span><span·class="p">)]</span>
145 </pre></div>145 </pre></div>
146 </div>146 </div>
147 <p>When·the·simulation·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.run">runs</a>,·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController">PeriTriaxController</a>·takes·over·the·control·and·calls·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.doneHook">doneHook</a>·when·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.goal">goal</a>·is·reached.·A·full·simulation·with·PeriTriaxController·might·look·like·the·following:</p>147 <p>When·the·simulation·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Omega.run">runs</a>,·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController">PeriTriaxController</a>·takes·over·the·control·and·calls·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.doneHook">doneHook</a>·when·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.PeriTriaxController.goal">goal</a>·is·reached.·A·full·simulation·with·PeriTriaxController·might·look·like·the·following:</p>
148 <div·class="highlight-default·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">from</span>·<span·class="nn">yade</span>·<span·class="k">import</span>·<span·class="n">pack</span><span·class="p">,</span><span·class="n">plot</span>148 <div·class="highlight-default·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">from</span>·<span·class="nn">yade</span>·<span·class="k">import</span>·<span·class="n">pack</span><span·class="p">,</span><span·class="n">plot</span>
149 <span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>149 <span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>
19.5 KB
./usr/share/doc/yade/html/tutorial-hands-on.html
    
Offset 385, 15 lines modifiedOffset 385, 15 lines modified
385 <li>Set·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.material">Body.material</a>·(last-defined·material·is·used,·otherwise·a·default·material·is·created)</li>385 <li>Set·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.material">Body.material</a>·(last-defined·material·is·used,·otherwise·a·default·material·is·created)</li>
386 <li>Set·position·and·orientation·in·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.state">Body.state</a>,·compute·mass·and·moment·of·inertia·based·on·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Material</a>·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Shape">Shape</a></li>386 <li>Set·position·and·orientation·in·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Body.state">Body.state</a>,·compute·mass·and·moment·of·inertia·based·on·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Material</a>·and·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Shape">Shape</a></li>
387 </ol>387 </ol>
388 <p>In·order·to·avoid·such·tasks,·shorthand·functions·are·defined·in·the·<a·class="reference·external"·href="yade.utils.html#">utils</a>·module;·to·mention·a·few·of·them,·they·are·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>,·<a·class="reference·external"·href="yade.utils.html#yade.utils.facet">utils.facet</a>,·<a·class="reference·external"·href="yade.utils.html#yade.utils.wall">utils.wall</a>.</p>388 <p>In·order·to·avoid·such·tasks,·shorthand·functions·are·defined·in·the·<a·class="reference·external"·href="yade.utils.html#">utils</a>·module;·to·mention·a·few·of·them,·they·are·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>,·<a·class="reference·external"·href="yade.utils.html#yade.utils.facet">utils.facet</a>,·<a·class="reference·external"·href="yade.utils.html#yade.utils.wall">utils.wall</a>.</p>
389 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[43]:·</span><span·class="n">s</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">)</span>····<span·class="c1">#·create·sphere·particle·centered·at·(0,0,0)·with·radius=1</span>389 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[43]:·</span><span·class="n">s</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">)</span>····<span·class="c1">#·create·sphere·particle·centered·at·(0,0,0)·with·radius=1</span>
  
390 <span·class="gp">Yade·[44]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span>·······················<span·class="c1">#·s.shape·describes·the·geometry·of·the·particle</span>390 <span·class="gp">Yade·[44]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span>·······················<span·class="c1">#·s.shape·describes·the·geometry·of·the·particle</span>
391 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">44</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Sphere</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558724d01f30</span><span·class="o">&gt;</span>391 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">44</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">Sphere</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517a5b3db0</span><span·class="o">&gt;</span>
  
392 <span·class="gp">Yade·[45]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>················<span·class="c1">#·we·already·know·the·Sphere·class</span>392 <span·class="gp">Yade·[45]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>················<span·class="c1">#·we·already·know·the·Sphere·class</span>
393 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">45</span><span·class="p">]:</span>·<span·class="mf">1.0</span>393 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">45</span><span·class="p">]:</span>·<span·class="mf">1.0</span>
  
394 <span·class="gp">Yade·[46]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">mass</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">inertia</span>·<span·class="c1">#·inertia·is·computed·from·density·and·geometry</span>394 <span·class="gp">Yade·[46]:·</span><span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">mass</span><span·class="p">,</span>·<span·class="n">s</span><span·class="o">.</span><span·class="n">state</span><span·class="o">.</span><span·class="n">inertia</span>·<span·class="c1">#·inertia·is·computed·from·density·and·geometry</span>
395 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">46</span><span·class="p">]:</span>·395 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">46</span><span·class="p">]:</span>·
396 <span·class="go">(4188.790204786391,</span>396 <span·class="go">(4188.790204786391,</span>
Offset 404, 15 lines modifiedOffset 404, 15 lines modified
  
404 <span·class="gp">Yade·[48]:·</span><span·class="n">s2</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="o">-</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">fixed</span><span·class="o">=</span><span·class="bp">True</span><span·class="p">)</span>·····<span·class="c1">#·explanation·below</span>404 <span·class="gp">Yade·[48]:·</span><span·class="n">s2</span><span·class="o">=</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="o">-</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">fixed</span><span·class="o">=</span><span·class="bp">True</span><span·class="p">)</span>·····<span·class="c1">#·explanation·below</span>
405 </pre></div>405 </pre></div>
406 </div>406 </div>
407 <p>In·the·last·example,·the·particle·was·fixed·in·space·by·the·<code·class="docutils·literal·notranslate"><span·class="pre">fixed=True</span></code>·parameter·to·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>;·such·a·particle·will·not·move,·creating·a·primitive·boundary·condition.</p>407 <p>In·the·last·example,·the·particle·was·fixed·in·space·by·the·<code·class="docutils·literal·notranslate"><span·class="pre">fixed=True</span></code>·parameter·to·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">utils.sphere</a>;·such·a·particle·will·not·move,·creating·a·primitive·boundary·condition.</p>
408 <p>A·particle·object·is·not·yet·part·of·the·simulation;·in·order·to·do·so,·a·special·function·is·called:</p>408 <p>A·particle·object·is·not·yet·part·of·the·simulation;·in·order·to·do·so,·a·special·function·is·called:</p>
409 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[49]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">s</span><span·class="p">)</span>············<span·class="c1">#·adds·particle·s·to·the·simulation;·returns·id·of·the·particle(s)·added</span>409 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[49]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">s</span><span·class="p">)</span>············<span·class="c1">#·adds·particle·s·to·the·simulation;·returns·id·of·the·particle(s)·added</span>
410 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">49</span><span·class="p">]:</span>·<span·class="mi">12</span>410 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">49</span><span·class="p">]:</span>·<span·class="mi">13</span>
411 </pre></div>411 </pre></div>
412 </div>412 </div>
413 </div>413 </div>
414 <div·class="section"·id="packs">414 <div·class="section"·id="packs">
415 <h4>Packs<a·class="headerlink"·href="#packs"·title="Permalink·to·this·headline">¶</a></h4>415 <h4>Packs<a·class="headerlink"·href="#packs"·title="Permalink·to·this·headline">¶</a></h4>
416 <p>There·are·functions·to·generate·a·specific·arrangement·of·particles·in·the·<a·class="reference·external"·href="yade.pack.html#">pack</a>·module;·for·instance,·cloud·(random·loose·packing)·of·spheres·can·be·generated·with·the·<a·class="reference·external"·href="yade.pack.html#yade._packSpheres.SpherePack">pack.SpherePack</a>·class:</p>416 <p>There·are·functions·to·generate·a·specific·arrangement·of·particles·in·the·<a·class="reference·external"·href="yade.pack.html#">pack</a>·module;·for·instance,·cloud·(random·loose·packing)·of·spheres·can·be·generated·with·the·<a·class="reference·external"·href="yade.pack.html#yade._packSpheres.SpherePack">pack.SpherePack</a>·class:</p>
417 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[50]:·</span><span·class="kn">from</span>·<span·class="nn">yade</span>·<span·class="kn">import</span>·<span·class="n">pack</span>417 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[50]:·</span><span·class="kn">from</span>·<span·class="nn">yade</span>·<span·class="kn">import</span>·<span·class="n">pack</span>
Offset 420, 41 lines modifiedOffset 420, 41 lines modified
420 <span·class="gp">Yade·[51]:·</span><span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>···················<span·class="c1">#·create·an·empty·cloud;·SpherePack·contains·only·geometrical·information</span>420 <span·class="gp">Yade·[51]:·</span><span·class="n">sp</span><span·class="o">=</span><span·class="n">pack</span><span·class="o">.</span><span·class="n">SpherePack</span><span·class="p">()</span>···················<span·class="c1">#·create·an·empty·cloud;·SpherePack·contains·only·geometrical·information</span>
  
421 <span·class="gp">Yade·[52]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">makeCloud</span><span·class="p">((</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">),(</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="n">rMean</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">)</span>·<span·class="c1">#·put·spheres·with·defined·radius·inside·box·given·by·corners·(1,1,1)·and·(2,2,2)</span>421 <span·class="gp">Yade·[52]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">makeCloud</span><span·class="p">((</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">),(</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="n">rMean</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">)</span>·<span·class="c1">#·put·spheres·with·defined·radius·inside·box·given·by·corners·(1,1,1)·and·(2,2,2)</span>
422 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">52</span><span·class="p">]:</span>·<span·class="mi">6</span>422 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">52</span><span·class="p">]:</span>·<span·class="mi">6</span>
  
423 <span·class="gp">Yade·[53]:·</span><span·class="k">for</span>·<span·class="n">c</span><span·class="p">,</span><span·class="n">r</span>·<span·class="ow">in</span>·<span·class="n">sp</span><span·class="p">:</span>·<span·class="k">print</span>·<span·class="n">c</span><span·class="p">,</span><span·class="n">r</span>···············<span·class="c1">#·print·center·and·radius·of·all·particles·(SpherePack·is·a·sequence·which·can·be·iterated·over)</span>423 <span·class="gp">Yade·[53]:·</span><span·class="k">for</span>·<span·class="n">c</span><span·class="p">,</span><span·class="n">r</span>·<span·class="ow">in</span>·<span·class="n">sp</span><span·class="p">:</span>·<span·class="k">print</span>·<span·class="n">c</span><span·class="p">,</span><span·class="n">r</span>···············<span·class="c1">#·print·center·and·radius·of·all·particles·(SpherePack·is·a·sequence·which·can·be·iterated·over)</span>
424 <span·class="gp">···....:</span>·424 <span·class="gp">···....:</span>·
425 <span·class="go">Vector3(1.7722311593333548,1.7702928045487896,1.2039690420999836)·0.2</span> 
426 <span·class="go">Vector3(1.3347688809361018,1.4286621238371935,1.349388091870945)·0.2</span> 
427 <span·class="go">Vector3(1.7023695724107042,1.481632031483233,1.6597988833298896)·0.2</span> 
428 <span·class="go">Vector3(1.3572624783564942,1.217102697880103,1.7643424727621884)·0.2</span> 
429 <span·class="go">Vector3(1.7970168493660323,1.2003358145247547,1.2101164033730667)·0.2</span> 
430 <span·class="go">Vector3(1.2984168646842398,1.6804864474390506,1.7613070168172074)·0.2</span>425 <span·class="go">Vector3(1.230606680950715,1.415108970566754,1.7251268793131476)·0.2</span>
 426 <span·class="go">Vector3(1.5540861212220844,1.6911630388266994,1.7310496500051111)·0.2</span>
 427 <span·class="go">Vector3(1.661284647473399,1.2712213062413236,1.7236854607459953)·0.2</span>
 428 <span·class="go">Vector3(1.5585056752511353,1.4274554756725724,1.3032745645412007)·0.2</span>
 429 <span·class="go">Vector3(1.3604811305743467,1.784663833756618,1.307919610205963)·0.2</span>
 430 <span·class="go">Vector3(1.2122934454235188,1.2169172488310536,1.2125314300065222)·0.2</span>
  
431 <span·class="gp">Yade·[54]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">toSimulation</span><span·class="p">()</span>······················<span·class="c1">#·create·particles·and·add·them·to·the·simulation</span>431 <span·class="gp">Yade·[54]:·</span><span·class="n">sp</span><span·class="o">.</span><span·class="n">toSimulation</span><span·class="p">()</span>······················<span·class="c1">#·create·particles·and·add·them·to·the·simulation</span>
432 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">54</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">13</span><span·class="p">,</span>·<span·class="mi">14</span><span·class="p">,</span>·<span·class="mi">15</span><span·class="p">,</span>·<span·class="mi">16</span><span·class="p">,</span>·<span·class="mi">17</span><span·class="p">,</span>·<span·class="mi">18</span><span·class="p">]</span>432 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">54</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">14</span><span·class="p">,</span>·<span·class="mi">15</span><span·class="p">,</span>·<span·class="mi">16</span><span·class="p">,</span>·<span·class="mi">17</span><span·class="p">,</span>·<span·class="mi">18</span><span·class="p">,</span>·<span·class="mi">19</span><span·class="p">]</span>
433 </pre></div>433 </pre></div>
434 </div>434 </div>
435 </div>435 </div>
436 <div·class="section"·id="boundaries">436 <div·class="section"·id="boundaries">
437 <h4>Boundaries<a·class="headerlink"·href="#boundaries"·title="Permalink·to·this·headline">¶</a></h4>437 <h4>Boundaries<a·class="headerlink"·href="#boundaries"·title="Permalink·to·this·headline">¶</a></h4>
438 <p><a·class="reference·external"·href="yade.utils.html#yade.utils.facet">utils.facet</a>·(triangle·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Facet">Facet</a>)·and·<a·class="reference·external"·href="yade.utils.html#yade.utils.wall">utils.wall</a>·(infinite·axes-aligned·plane·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Wall">Wall</a>)·geometries·are·typically·used·to·define·boundaries.·For·instance,·a·“floor”·for·the·simulation·can·be·created·like·this:</p>438 <p><a·class="reference·external"·href="yade.utils.html#yade.utils.facet">utils.facet</a>·(triangle·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Facet">Facet</a>)·and·<a·class="reference·external"·href="yade.utils.html#yade.utils.wall">utils.wall</a>·(infinite·axes-aligned·plane·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Wall">Wall</a>)·geometries·are·typically·used·to·define·boundaries.·For·instance,·a·“floor”·for·the·simulation·can·be·created·like·this:</p>
439 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[55]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">wall</span><span·class="p">(</span><span·class="o">-</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">axis</span><span·class="o">=</span><span·class="mi">2</span><span·class="p">))</span>439 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[55]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">wall</span><span·class="p">(</span><span·class="o">-</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">axis</span><span·class="o">=</span><span·class="mi">2</span><span·class="p">))</span>
440 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">55</span><span·class="p">]:</span>·<span·class="mi">19</span>440 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">55</span><span·class="p">]:</span>·<span·class="mi">20</span>
441 </pre></div>441 </pre></div>
442 </div>442 </div>
443 <p>There·are·other·conveinence·functions·(like·<a·class="reference·external"·href="yade.utils.html#yade.utils.facetBox">utils.facetBox</a>·for·creating·closed·or·open·rectangular·box,·or·family·of·<a·class="reference·external"·href="yade.ymport.html#">ymport</a>·functions)</p>443 <p>There·are·other·conveinence·functions·(like·<a·class="reference·external"·href="yade.utils.html#yade.utils.facetBox">utils.facetBox</a>·for·creating·closed·or·open·rectangular·box,·or·family·of·<a·class="reference·external"·href="yade.ymport.html#">ymport</a>·functions)</p>
444 </div>444 </div>
445 </div>445 </div>
446 <div·class="section"·id="look-inside">446 <div·class="section"·id="look-inside">
447 <h3>Look·inside<a·class="headerlink"·href="#look-inside"·title="Permalink·to·this·headline">¶</a></h3>447 <h3>Look·inside<a·class="headerlink"·href="#look-inside"·title="Permalink·to·this·headline">¶</a></h3>
448 <p>The·simulation·can·be·inspected·in·several·ways.·All·data·can·be·accessed·from·python·directly:</p>448 <p>The·simulation·can·be·inspected·in·several·ways.·All·data·can·be·accessed·from·python·directly:</p>
449 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[56]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">)</span>449 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[56]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">)</span>
450 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">56</span><span·class="p">]:</span>·<span·class="mi">20</span>450 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">56</span><span·class="p">]:</span>·<span·class="mi">21</span>
  
451 <span·class="gp">Yade·[57]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">]</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>···<span·class="c1">#·radius·of·body·#1·(will·give·error·if·not·sphere,·since·only·spheres·have·radius·defined)</span>451 <span·class="gp">Yade·[57]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">]</span><span·class="o">.</span><span·class="n">shape</span><span·class="o">.</span><span·class="n">radius</span>···<span·class="c1">#·radius·of·body·#1·(will·give·error·if·not·sphere,·since·only·spheres·have·radius·defined)</span>
  
452 <span·class="go">AttributeErrorTraceback·(most·recent·call·last)</span>452 <span·class="go">AttributeErrorTraceback·(most·recent·call·last)</span>
453 <span·class="go">/build/yade-2019.01a/debian/tmp/usr/lib/x86_64-linux-gnu/yade/py/yade/__init__.pyc·in·&lt;module&gt;()</span>453 <span·class="go">/build/yade-2019.01a/debian/tmp/usr/lib/x86_64-linux-gnu/yade/py/yade/__init__.pyc·in·&lt;module&gt;()</span>
454 <span·class="go">----&gt;·1·O.bodies[1].shape.radius···#·radius·of·body·#1·(will·give·error·if·not·sphere,·since·only·spheres·have·radius·defined)</span>454 <span·class="go">----&gt;·1·O.bodies[1].shape.radius···#·radius·of·body·#1·(will·give·error·if·not·sphere,·since·only·spheres·have·radius·defined)</span>
  
Offset 477, 15 lines modifiedOffset 477, 15 lines modified
477 <dd><em>Inspector</em>·is·opened·by·clicking·on·the·appropriate·button·in·the·<em>Controller</em>.·It·shows·(and·updated)·internal·data·of·the·current·simulation.·In·particular,·one·can·have·a·look·at·engines,·particles·(<em>Bodies</em>)·and·interactions·(<em>Interactions</em>).·Clicking·at·each·of·the·attribute·names·links·to·the·appropriate·section·in·the·documentation.</dd>477 <dd><em>Inspector</em>·is·opened·by·clicking·on·the·appropriate·button·in·the·<em>Controller</em>.·It·shows·(and·updated)·internal·data·of·the·current·simulation.·In·particular,·one·can·have·a·look·at·engines,·particles·(<em>Bodies</em>)·and·interactions·(<em>Interactions</em>).·Clicking·at·each·of·the·attribute·names·links·to·the·appropriate·section·in·the·documentation.</dd>
478 </dl>478 </dl>
479 <p·class="rubric">Exercises</p>479 <p·class="rubric">Exercises</p>
480 <ol·class="arabic">480 <ol·class="arabic">
481 <li><p·class="first">What·is·this·code·going·to481 <li><p·class="first">What·is·this·code·going·to
482 do?</p>482 do?</p>
483 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[59]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">([</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">2</span><span·class="o">*</span><span·class="n">i</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="mi">1</span><span·class="p">)</span>·<span·class="k">for</span>·<span·class="n">i</span>·<span·class="ow">in</span>·<span·class="nb">range</span><span·class="p">(</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">20</span><span·class="p">)])</span>483 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[59]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">([</span><span·class="n">utils</span><span·class="o">.</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">2</span><span·class="o">*</span><span·class="n">i</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="mi">1</span><span·class="p">)</span>·<span·class="k">for</span>·<span·class="n">i</span>·<span·class="ow">in</span>·<span·class="nb">range</span><span·class="p">(</span><span·class="mi">1</span><span·class="p">,</span><span·class="mi">20</span><span·class="p">)])</span>
484 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">59</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">20</span><span·class="p">,</span>·<span·class="mi">21</span><span·class="p">,</span>·<span·class="mi">22</span><span·class="p">,</span>·<span·class="mi">23</span><span·class="p">,</span>·<span·class="mi">24</span><span·class="p">,</span>·<span·class="mi">25[·...·truncated·by·diffoscope;·len:·663,·SHA:·8a0d58dc93e20144c44acc6f164a07da7cca0391640c43c96b64a6a0a474daef·...·]</span><span·class="p">]</span>484 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">59</span><span·class="p">]:</span>·<span·class="p">[</span><span·class="mi">21</span><span·class="p">,</span>·<span·class="mi">22</span><span·class="p">,</span>·<span·class="mi">23</span><span·class="p">,</span>·<span·class="mi">24</span><span·class="p">,</span>·<span·class="mi">25</span><span·class="p">,</span>·<span·class="mi">26[·...·truncated·by·diffoscope;·len:·663,·SHA:·b6c7715a9c4748d6fc96cc8dbaa2f4e1aaa303eadfb4da3cf835065ee9beefa9·...·]</span><span·class="p">]</span>
485 </pre></div>485 </pre></div>
486 </div>486 </div>
487 </li>487 </li>
488 <li><p·class="first">Create·a·simple·simulation·with·cloud·of·spheres·enclosed·in·the·box·<code·class="docutils·literal·notranslate"><span·class="pre">(0,0,0)</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">(1,1,1)</span></code>·with·mean·radius·.1.·(hint:·<a·class="reference·external"·href="yade.pack.html#yade._packSpheres.SpherePack.makeCloud">pack.SpherePack.makeCloud</a>)</p>488 <li><p·class="first">Create·a·simple·simulation·with·cloud·of·spheres·enclosed·in·the·box·<code·class="docutils·literal·notranslate"><span·class="pre">(0,0,0)</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">(1,1,1)</span></code>·with·mean·radius·.1.·(hint:·<a·class="reference·external"·href="yade.pack.html#yade._packSpheres.SpherePack.makeCloud">pack.SpherePack.makeCloud</a>)</p>
489 </li>489 </li>
490 <li><p·class="first">Enclose·the·cloud·created·above·in·box·with·corners·<code·class="docutils·literal·notranslate"><span·class="pre">(0,0,0)</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">(1,1,1)</span></code>;·keep·the·top·of·the·box·open.·(hint:·<a·class="reference·external"·href="yade.utils.html#yade.utils.facetBox">utils.facetBox</a>;·type·<code·class="docutils·literal·notranslate"><span·class="pre">utils.facetBox?</span></code>·or·<code·class="docutils·literal·notranslate"><span·class="pre">utils.facetBox??</span></code>·to·get·help·on·the·command·line)</p>490 <li><p·class="first">Enclose·the·cloud·created·above·in·box·with·corners·<code·class="docutils·literal·notranslate"><span·class="pre">(0,0,0)</span></code>·and·<code·class="docutils·literal·notranslate"><span·class="pre">(1,1,1)</span></code>;·keep·the·top·of·the·box·open.·(hint:·<a·class="reference·external"·href="yade.utils.html#yade.utils.facetBox">utils.facetBox</a>;·type·<code·class="docutils·literal·notranslate"><span·class="pre">utils.facetBox?</span></code>·or·<code·class="docutils·literal·notranslate"><span·class="pre">utils.facetBox??</span></code>·to·get·help·on·the·command·line)</p>
491 </li>491 </li>
Offset 506, 18 lines modifiedOffset 506, 18 lines modified
506 <span·class="gp">···....:</span>····<span·class="p">),</span>506 <span·class="gp">···....:</span>····<span·class="p">),</span>
507 <span·class="gp">···....:</span>····<span·class="n">NewtonIntegrator</span><span·class="p">(</span><span·class="n">damping</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">label</span><span·class="o">=</span><span·class="s1">&#39;newton&#39;</span><span·class="p">)</span>······<span·class="c1">#·define·a·name·under·which·we·can·access·this·engine·easily</span>507 <span·class="gp">···....:</span>····<span·class="n">NewtonIntegrator</span><span·class="p">(</span><span·class="n">damping</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">label</span><span·class="o">=</span><span·class="s1">&#39;newton&#39;</span><span·class="p">)</span>······<span·class="c1">#·define·a·name·under·which·we·can·access·this·engine·easily</span>
508 <span·class="gp">···....:</span>·<span·class="p">]</span>508 <span·class="gp">···....:</span>·<span·class="p">]</span>
509 <span·class="gp">···....:</span>·509 <span·class="gp">···....:</span>·
  
510 <span·class="gp">Yade·[61]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span>510 <span·class="gp">Yade·[61]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span>
511 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">61</span><span·class="p">]:</span>·511 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">61</span><span·class="p">]:</span>·
512 <span·class="go">[&lt;ForceResetter·instance·at·0x558724cbffa0&gt;,</span>512 <span·class="go">[&lt;ForceResetter·instance·at·0x56517a72b590&gt;,</span>
513 <span·class="go">·&lt;InsertionSortCollider·instance·at·0x558724509050&gt;,</span>513 <span·class="go">·&lt;InsertionSortCollider·instance·at·0x56517a4f5cc0&gt;,</span>
514 <span·class="go">·&lt;InteractionLoop·instance·at·0x55872459e7c0&gt;,</span>514 <span·class="go">·&lt;InteractionLoop·instance·at·0x56517a457360&gt;,</span>
515 <span·class="go">·&lt;NewtonIntegrator·instance·at·0x55872434a2c0&gt;]</span>515 <span·class="go">·&lt;NewtonIntegrator·instance·at·0x56517a769420&gt;]</span>
  
516 <span·class="gp">Yade·[62]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span><span·class="p">[</span><span·class="o">-</span><span·class="mi">1</span><span·class="p">]</span><span·class="o">==</span><span·class="n">newton</span>····<span·class="c1">#·is·it·the·same·object?</span>516 <span·class="gp">Yade·[62]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">engines</span><span·class="p">[</span><span·class="o">-</span><span·class="mi">1</span><span·class="p">]</span><span·class="o">==</span><span·class="n">newton</span>····<span·class="c1">#·is·it·the·same·object?</span>
517 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">62</span><span·class="p">]:</span>·<span·class="bp">True</span>517 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">62</span><span·class="p">]:</span>·<span·class="bp">True</span>
  
518 <span·class="gp">Yade·[63]:·</span><span·class="n">newton</span><span·class="o">.</span><span·class="n">damping</span>518 <span·class="gp">Yade·[63]:·</span><span·class="n">newton</span><span·class="o">.</span><span·class="n">damping</span>
519 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">63</span><span·class="p">]:</span>·<span·class="mf">0.2</span>519 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">63</span><span·class="p">]:</span>·<span·class="mf">0.2</span>
520 </pre></div>520 </pre></div>
8.59 KB
./usr/share/doc/yade/html/user.html
    
Offset 82, 15 lines modifiedOffset 82, 15 lines modified
82 <p>If·no·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Material</a>·is·specified·when·calling·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">sphere</a>,·the·<em>last</em>·defined·material·is·used;·that·is·a·convenient·default.·If·no·material·is·defined·yet·(hence·there·is·no·last·material),·a·default·material·will·be·created:·FrictMat(density=2e3,young=30e9,poisson=.3,frictionAngle=.5236).·This·should·not·happen·for·serious·simulations,·but·is·handy·in·simple·scripts,·where·exact·material·properties·are·more·or·less·irrelevant.</p>82 <p>If·no·<a·class="reference·external"·href="yade.wrapper.html#yade.wrapper.Material">Material</a>·is·specified·when·calling·<a·class="reference·external"·href="yade.utils.html#yade.utils.sphere">sphere</a>,·the·<em>last</em>·defined·material·is·used;·that·is·a·convenient·default.·If·no·material·is·defined·yet·(hence·there·is·no·last·material),·a·default·material·will·be·created:·FrictMat(density=2e3,young=30e9,poisson=.3,frictionAngle=.5236).·This·should·not·happen·for·serious·simulations,·but·is·handy·in·simple·scripts,·where·exact·material·properties·are·more·or·less·irrelevant.</p>
83 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[1]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="p">)</span>83 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[1]:·</span><span·class="nb">len</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="p">)</span>
84 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">]:</span>·<span·class="mi">0</span>84 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">1</span><span·class="p">]:</span>·<span·class="mi">0</span>
  
85 <span·class="gp">Yade·[2]:·</span><span·class="n">idConcrete</span><span·class="o">=</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">FrictMat</span><span·class="p">(</span><span·class="n">young</span><span·class="o">=</span><span·class="mf">30e9</span><span·class="p">,</span><span·class="n">poisson</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">frictionAngle</span><span·class="o">=.</span><span·class="mi">6</span><span·class="p">,</span><span·class="n">label</span><span·class="o">=</span><span·class="s2">&quot;concrete&quot;</span><span·class="p">))</span>85 <span·class="gp">Yade·[2]:·</span><span·class="n">idConcrete</span><span·class="o">=</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">FrictMat</span><span·class="p">(</span><span·class="n">young</span><span·class="o">=</span><span·class="mf">30e9</span><span·class="p">,</span><span·class="n">poisson</span><span·class="o">=.</span><span·class="mi">2</span><span·class="p">,</span><span·class="n">frictionAngle</span><span·class="o">=.</span><span·class="mi">6</span><span·class="p">,</span><span·class="n">label</span><span·class="o">=</span><span·class="s2">&quot;concrete&quot;</span><span·class="p">))</span>
  
86 <span·class="gp">Yade·[3]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="p">[</span><span·class="n">idConcrete</span><span·class="p">]</span>86 <span·class="gp">Yade·[3]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">materials</span><span·class="p">[</span><span·class="n">idConcrete</span><span·class="p">]</span>
87 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">3</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">FrictMat</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558724ce93d0</span><span·class="o">&gt;</span>87 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">3</span><span·class="p">]:</span>·<span·class="o">&lt;</span><span·class="n">FrictMat</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517aedc570</span><span·class="o">&gt;</span>
  
88 <span·class="c">#·uses·the·last·defined·material</span>88 <span·class="c">#·uses·the·last·defined·material</span>
89 <span·class="gp">Yade·[4]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">sphere</span><span·class="p">(</span><span·class="n">center</span><span·class="o">=</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">))</span>89 <span·class="gp">Yade·[4]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">sphere</span><span·class="p">(</span><span·class="n">center</span><span·class="o">=</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">),</span><span·class="n">radius</span><span·class="o">=</span><span·class="mi">1</span><span·class="p">))</span>
90 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">4</span><span·class="p">]:</span>·<span·class="mi">0</span>90 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">4</span><span·class="p">]:</span>·<span·class="mi">0</span>
  
91 <span·class="c">#·material·given·by·id</span>91 <span·class="c">#·material·given·by·id</span>
92 <span·class="gp">Yade·[5]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">material</span><span·class="o">=</span><span·class="n">idConcrete</span><span·class="p">))</span>92 <span·class="gp">Yade·[5]:·</span><span·class="n">O</span><span·class="o">.</span><span·class="n">bodies</span><span·class="o">.</span><span·class="n">append</span><span·class="p">(</span><span·class="n">sphere</span><span·class="p">((</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">2</span><span·class="p">),</span><span·class="mi">1</span><span·class="p">,</span><span·class="n">material</span><span·class="o">=</span><span·class="n">idConcrete</span><span·class="p">))</span>
Offset 514, 15 lines modifiedOffset 514, 15 lines modified
514 <span·class="gp">···....:</span>·<span·class="p">]</span>514 <span·class="gp">···....:</span>·<span·class="p">]</span>
515 <span·class="gp">···....:</span>·515 <span·class="gp">···....:</span>·
  
516 <span·class="gp">Yade·[29]:·</span><span·class="n">i</span><span·class="o">=</span><span·class="n">createInteraction</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">)</span>516 <span·class="gp">Yade·[29]:·</span><span·class="n">i</span><span·class="o">=</span><span·class="n">createInteraction</span><span·class="p">(</span><span·class="mi">0</span><span·class="p">,</span><span·class="mi">1</span><span·class="p">)</span>
  
517 <span·class="c">#·created·by·functors·in·InteractionLoop</span>517 <span·class="c">#·created·by·functors·in·InteractionLoop</span>
518 <span·class="gp">Yade·[30]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">geom</span><span·class="p">,</span>·<span·class="n">i</span><span·class="o">.</span><span·class="n">phys</span>518 <span·class="gp">Yade·[30]:·</span><span·class="n">i</span><span·class="o">.</span><span·class="n">geom</span><span·class="p">,</span>·<span·class="n">i</span><span·class="o">.</span><span·class="n">phys</span>
519 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">30</span><span·class="p">]:</span>·<span·class="p">(</span><span·class="o">&lt;</span><span·class="n">ScGeom</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558724dc8290</span><span·class="o">&gt;</span><span·class="p">,</span>·<span·class="o">&lt;</span><span·class="n">FrictPhys</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x558724d2bc90</span><span·class="o">&gt;</span><span·class="p">)</span>519 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">30</span><span·class="p">]:</span>·<span·class="p">(</span><span·class="o">&lt;</span><span·class="n">ScGeom</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517a4a5dc0</span><span·class="o">&gt;</span><span·class="p">,</span>·<span·class="o">&lt;</span><span·class="n">FrictPhys</span>·<span·class="n">instance</span>·<span·class="n">at</span>·<span·class="mh">0x56517af44a20</span><span·class="o">&gt;</span><span·class="p">)</span>
520 </pre></div>520 </pre></div>
521 </div>521 </div>
522 <p>This·method·will·be·rather·slow·if·many·interaction·are·to·be·created·(the·functor·lookup·will·be·repeated·for·each·of·them).·In·such·case,·ask·on·<a·class="reference·external"·href="mailto:yade-dev&#37;&#52;&#48;lists&#46;launchpad&#46;net">yade-dev<span>&#64;</span>lists<span>&#46;</span>launchpad<span>&#46;</span>net</a>·to·have·the·<a·class="reference·external"·href="yade.utils.html#yade.utils.createInteraction">createInteraction</a>·function·accept·list·of·pairs·id’s·as·well.</p>522 <p>This·method·will·be·rather·slow·if·many·interaction·are·to·be·created·(the·functor·lookup·will·be·repeated·for·each·of·them).·In·such·case,·ask·on·<a·class="reference·external"·href="mailto:yade-dev&#37;&#52;&#48;lists&#46;launchpad&#46;net">yade-dev<span>&#64;</span>lists<span>&#46;</span>launchpad<span>&#46;</span>net</a>·to·have·the·<a·class="reference·external"·href="yade.utils.html#yade.utils.createInteraction">createInteraction</a>·function·accept·list·of·pairs·id’s·as·well.</p>
523 </div>523 </div>
524 </div>524 </div>
525 <div·class="section"·id="base-engines">525 <div·class="section"·id="base-engines">
526 <h3>Base·engines<a·class="headerlink"·href="#base-engines"·title="Permalink·to·this·headline">¶</a></h3>526 <h3>Base·engines<a·class="headerlink"·href="#base-engines"·title="Permalink·to·this·headline">¶</a></h3>
Offset 810, 19 lines modifiedOffset 810, 19 lines modified
810 <ul·class="simple">810 <ul·class="simple">
811 <li><code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·is·<em>saved·and·loaded·with·simulation</em>;</li>811 <li><code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·is·<em>saved·and·loaded·with·simulation</em>;</li>
812 <li><code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·has·some·values·pre-initialized.</li>812 <li><code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·has·some·values·pre-initialized.</li>
813 </ul>813 </ul>
814 <p>After·Yade·startup,·<code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·contains·the·following:</p>814 <p>After·Yade·startup,·<code·class="docutils·literal·notranslate"><span·class="pre">O.tags</span></code>·contains·the·following:</p>
815 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[45]:·</span><span·class="nb">dict</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">tags</span><span·class="p">)</span>·<span·class="c1">#·convert·to·real·dictionary</span>815 <div·class="highlight-ipython·notranslate"><div·class="highlight"><pre><span></span><span·class="gp">Yade·[45]:·</span><span·class="nb">dict</span><span·class="p">(</span><span·class="n">O</span><span·class="o">.</span><span·class="n">tags</span><span·class="p">)</span>·<span·class="c1">#·convert·to·real·dictionary</span>
816 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">45</span><span·class="p">]:</span>·816 <span·class="gr">Out</span><span·class="p">[</span><span·class="mi">45</span><span·class="p">]:</span>·
817 <span·class="go">{&#39;author&#39;:·&#39;root~(root@ionos5-amd64)&#39;,</span>817 <span·class="go">{&#39;author&#39;:·&#39;root~(root@i-capture-the-hostname)&#39;,</span>
818 <span·class="go">·&#39;d.id&#39;:·&#39;20230121T183046p2799986&#39;,</span>818 <span·class="go">·&#39;d.id&#39;:·&#39;20211220T205944p2605508&#39;,</span>
819 <span·class="go">·&#39;id&#39;:·&#39;20230121T183046p2799986&#39;,</span>819 <span·class="go">·&#39;id&#39;:·&#39;20211220T205944p2605508&#39;,</span>
820 <span·class="go">·&#39;id.d&#39;:·&#39;20230121T183046p2799986&#39;,</span>820 <span·class="go">·&#39;id.d&#39;:·&#39;20211220T205944p2605508&#39;,</span>
821 <span·class="go">·&#39;isoTime&#39;:·&#39;20230121T183046&#39;}</span>821 <span·class="go">·&#39;isoTime&#39;:·&#39;20211220T205944&#39;}</span>
822 </pre></div>822 </pre></div>
823 </div>823 </div>
824 <dl·class="docutils">824 <dl·class="docutils">
825 <dt>author</dt>825 <dt>author</dt>
826 <dd>Real·name,·username·and·machine·as·obtained·from·your·system·at·simulation·creation</dd>826 <dd>Real·name,·username·and·machine·as·obtained·from·your·system·at·simulation·creation</dd>
827 <dt>id</dt>827 <dt>id</dt>
828 <dd>Unique·identifier·of·this·Yade·instance·(or·of·the·instance·which·created·a·loaded·simulation).·It·is·composed·of·date,·time·and·process·number.·Useful·if·you·run·simulations·in·parallel·and·want·to·avoid·overwriting·each·other’s·outputs;·embed·<code·class="docutils·literal·notranslate"><span·class="pre">O.tags['id']</span></code>·in·output·filenames·(either·as·directory·name,·or·as·part·of·the·file’s·name·itself)·to·avoid·it.·This·is·explained·in·<a·class="reference·internal"·href="#batch-output-separate"><span·class="std·std-ref">Separating·output·files·from·jobs</span></a>·in·detail.</dd>828 <dd>Unique·identifier·of·this·Yade·instance·(or·of·the·instance·which·created·a·loaded·simulation).·It·is·composed·of·date,·time·and·process·number.·Useful·if·you·run·simulations·in·parallel·and·want·to·avoid·overwriting·each·other’s·outputs;·embed·<code·class="docutils·literal·notranslate"><span·class="pre">O.tags['id']</span></code>·in·output·filenames·(either·as·directory·name,·or·as·part·of·the·file’s·name·itself)·to·avoid·it.·This·is·explained·in·<a·class="reference·internal"·href="#batch-output-separate"><span·class="std·std-ref">Separating·output·files·from·jobs</span></a>·in·detail.</dd>
1.12 KB
yade_2019.01a-2_amd64.deb
367 B
file list
    
Offset 1, 3 lines modifiedOffset 1, 3 lines modified
1 -rw-r--r--···0········0········0········4·2019-01-30·18:41:45.000000·debian-binary1 -rw-r--r--···0········0········0········4·2019-01-30·18:41:45.000000·debian-binary
2 -rw-r--r--···0········0········0····10988·2019-01-30·18:41:45.000000·control.tar.xz2 -rw-r--r--···0········0········0····10988·2019-01-30·18:41:45.000000·control.tar.xz
3 -rw-r--r--···0········0········0··1716552·2019-01-30·18:41:45.000000·data.tar.xz3 -rw-r--r--···0········0········0··1716540·2019-01-30·18:41:45.000000·data.tar.xz
98.0 B
control.tar.xz
70.0 B
control.tar
48.0 B
./md5sums
30.0 B
./md5sums
Files differ
631 B
data.tar.xz
609 B
data.tar
593 B
./usr/share/man/man1/yade-batch.1.gz
521 B
yade-batch.1
    
Offset 17, 15 lines modifiedOffset 17, 15 lines modified
17 .TP17 .TP
18 \fB\-h\fR,·\fB\-\-help\fR18 \fB\-h\fR,·\fB\-\-help\fR
19 show·this·help·message·and·exit19 show·this·help·message·and·exit
20 .TP20 .TP
21 \fB\-j\fR·NUM,·\fB\-\-jobs\fR·NUM21 \fB\-j\fR·NUM,·\fB\-\-jobs\fR·NUM
22 Maximum·number·of·simultaneous·threads·to·run22 Maximum·number·of·simultaneous·threads·to·run
23 (default:·number·of·cores,·further·limited·by23 (default:·number·of·cores,·further·limited·by
24 OMP_NUM_THREADS·if·set·by·the·environment:·16)24 OMP_NUM_THREADS·if·set·by·the·environment:·15)
25 .TP25 .TP
26 \fB\-v\fR,·\fB\-\-version\fR26 \fB\-v\fR,·\fB\-\-version\fR
27 Print·version·and·exit.27 Print·version·and·exit.
28 .TP28 .TP
29 \fB\-\-job\-threads\fR·NUM29 \fB\-\-job\-threads\fR·NUM
30 Default·number·of·threads·for·one·job;·can·be30 Default·number·of·threads·for·one·job;·can·be
31 overridden·by·per\-job·with·!THREADS·(or31 overridden·by·per\-job·with·!THREADS·(or