[yade] 01/06: Remove some machine-specific items in documentation.

Anton Gladky gladk at moszumanska.debian.org
Thu Jun 2 21:02:30 UTC 2016


This is an automated email from the git hooks/post-receive script.

gladk pushed a commit to branch master
in repository yade.

commit bc45d1254be03a7eddd8fe8f0dbedccac5de065f
Author: Anton Gladky <gladky.anton at gmail.com>
Date:   Mon May 30 21:17:05 2016 +0200

    Remove some machine-specific items in documentation.
    
    This is the first step to remove some machine-specific
    items in generated documentation to get a reproducible
    builds [1].
    
    [1] https://wiki.debian.org/ReproducibleBuilds/About
---
 doc/sphinx/introduction.rst      | 34 ++++++++++++----------------------
 doc/sphinx/tutorial-hands-on.rst |  2 --
 2 files changed, 12 insertions(+), 24 deletions(-)

diff --git a/doc/sphinx/introduction.rst b/doc/sphinx/introduction.rst
index cc6de5f..9788d45 100644
--- a/doc/sphinx/introduction.rst
+++ b/doc/sphinx/introduction.rst
@@ -157,14 +157,8 @@ Normal simulations, however, are run continuously. Starting/stopping the loop is
 
 	In [1]: O.pause()
 
-	In [1]: O.iter
-	104587
-
 	In [1]: O.run(100000,True)
 
-	In [1]: O.iter
-	204587
-
 	In [1]: O.stopAtIter=500000
 
 	In [1]: O.wait()
@@ -253,11 +247,9 @@ Entire simulation, i.e. both data and functions, are stored in a single ``Scene`
 
 .. ipython::
 
-	Yade [1]: O.bodies       # some data components
-
-	Yade [2]: len(O.bodies)  # there are no bodies as of yet
+	Yade [1]: len(O.bodies)  # there are no bodies as of yet
 
-	Yade [3]: O.engines      # functional components, empty at the moment
+	Yade [2]: O.engines      # functional components, empty at the moment
 
 Data components
 ^^^^^^^^^^^^^^^
@@ -288,13 +280,11 @@ Explicitly assigning all 4 properties to each particle by hand would be not prac
 
 .. ipython::
 	
-   In [3]: s=utils.sphere(center=[0,0,0],radius=1)
-
-   In [5]: s.shape, s.state, s.mat, s.bound
+   In [2]: s=utils.sphere(center=[0,0,0],radius=1)
 
-   In [6]: s.state.pos
+   In [3]: s.state.pos
 
-   In [7]: s.shape.radius
+   In [4]: s.shape.radius
 
 
 We see that a sphere with material of type :yref:`FrictMat` (default, unless you provide another :yref:`Material`) and bounding volume of type :yref:`Aabb` (axis-aligned bounding box) was created. Its position is at origin and its radius is 1.0. Finally, this object can be inserted into the simulation; and we can insert yet one sphere as well.
@@ -360,21 +350,21 @@ Suppose now interactions have been already created. We can access them by the id
 
 .. ipython::
 
-	In [1]: O.interactions[0,1]
-	<Interaction instance at 0x93f9528>
+	In [1]: if (O.interactions[0,1]): print ("Interaction exists!")
+	Interaction exists!
 
-	In [2]: O.interactions[1,0]     # order of ids is not important
+	In [2]: if (O.interactions[1,0]): print ("Interaction exists!")     # order of ids is not important
 
 	In [2]: i=O.interactions[0,1]
 	
 	In [3]: i.id1,i.id2
 	(0, 1)
 
-	In [4]: i.geom
-	<ScGeom instance at 0x9403838>
+	In [4]: if (i.geom): print ("Geom instance exists!")
+	Geom instance exists!
 
-	In [5]: i.phys
-	<ElasticContactInteraction instance at 0x94038d0>
+	In [5]: if (i.phys): print ("Phys instance exists!")
+	Phys instance exists!
 
 	In [6]: O.interactions[100,10111]
 	ValueError: No such interaction
diff --git a/doc/sphinx/tutorial-hands-on.rst b/doc/sphinx/tutorial-hands-on.rst
index 3e68080..42567cd 100644
--- a/doc/sphinx/tutorial-hands-on.rst
+++ b/doc/sphinx/tutorial-hands-on.rst
@@ -320,8 +320,6 @@ In order to avoid such tasks, shorthand functions are defined in the :yref:`yade
 	
 	Yade [1]: s=utils.sphere((0,0,0),radius=1)    # create sphere particle centered at (0,0,0) with radius=1
 
-	Yade [1]: s.shape                       # s.shape describes the geometry of the particle
-
 	Yade [1]: s.shape.radius                # we already know the Sphere class
 
 	Yade [1]: s.state.mass, s.state.inertia # inertia is computed from density and geometry

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/yade.git



More information about the debian-science-commits mailing list