3 次代碼提交 527889872d ... 7fb9aafa4e

作者 SHA1 備註 提交日期
  Gilbert Brault 7fb9aafa4e added mkdocs for mybinder 5 年之前
  Gilbert Brault e4afbe2ec3 added jupyter-server-proxy 5 年之前
  Gilbert Brault 858e7ff5d2 updated user guide 5 年之前

文件差異過大導致無法顯示
+ 354 - 0
jupysketch-doc/docs/reference/trajectory.svg


文件差異過大導致無法顯示
+ 354 - 0
jupysketch-doc/site/reference/trajectory.svg


文件差異過大導致無法顯示
+ 1 - 1
jupysketch-doc/site/search/search_index.json


+ 125 - 42
jupysketch-doc/site/shapereference/index.html

@@ -612,6 +612,33 @@
       </ul>
     </nav>
   
+</li>
+      
+        <li class="md-nav__item">
+  <a href="#trajectory" class="md-nav__link">
+    Trajectory
+  </a>
+  
+    <nav class="md-nav" aria-label="Trajectory">
+      <ul class="md-nav__list">
+        
+          <li class="md-nav__item">
+  <a href="#yaml_14" class="md-nav__link">
+    Yaml
+  </a>
+  
+</li>
+        
+          <li class="md-nav__item">
+  <a href="#python_14" class="md-nav__link">
+    Python
+  </a>
+  
+</li>
+        
+      </ul>
+    </nav>
+  
 </li>
       
         <li class="md-nav__item">
@@ -623,14 +650,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_14" class="md-nav__link">
+  <a href="#yaml_15" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_14" class="md-nav__link">
+  <a href="#python_15" class="md-nav__link">
     Python
   </a>
   
@@ -650,14 +677,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_15" class="md-nav__link">
+  <a href="#yaml_16" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_15" class="md-nav__link">
+  <a href="#python_16" class="md-nav__link">
     Python
   </a>
   
@@ -677,14 +704,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_16" class="md-nav__link">
+  <a href="#yaml_17" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_16" class="md-nav__link">
+  <a href="#python_17" class="md-nav__link">
     Python
   </a>
   
@@ -704,14 +731,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_17" class="md-nav__link">
+  <a href="#yaml_18" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_17" class="md-nav__link">
+  <a href="#python_18" class="md-nav__link">
     Python
   </a>
   
@@ -731,14 +758,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_18" class="md-nav__link">
+  <a href="#yaml_19" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_18" class="md-nav__link">
+  <a href="#python_19" class="md-nav__link">
     Python
   </a>
   
@@ -758,14 +785,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_19" class="md-nav__link">
+  <a href="#yaml_20" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_19" class="md-nav__link">
+  <a href="#python_20" class="md-nav__link">
     Python
   </a>
   
@@ -785,14 +812,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_20" class="md-nav__link">
+  <a href="#yaml_21" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_20" class="md-nav__link">
+  <a href="#python_21" class="md-nav__link">
     Python
   </a>
   
@@ -1240,6 +1267,33 @@
       </ul>
     </nav>
   
+</li>
+      
+        <li class="md-nav__item">
+  <a href="#trajectory" class="md-nav__link">
+    Trajectory
+  </a>
+  
+    <nav class="md-nav" aria-label="Trajectory">
+      <ul class="md-nav__list">
+        
+          <li class="md-nav__item">
+  <a href="#yaml_14" class="md-nav__link">
+    Yaml
+  </a>
+  
+</li>
+        
+          <li class="md-nav__item">
+  <a href="#python_14" class="md-nav__link">
+    Python
+  </a>
+  
+</li>
+        
+      </ul>
+    </nav>
+  
 </li>
       
         <li class="md-nav__item">
@@ -1251,14 +1305,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_14" class="md-nav__link">
+  <a href="#yaml_15" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_14" class="md-nav__link">
+  <a href="#python_15" class="md-nav__link">
     Python
   </a>
   
@@ -1278,14 +1332,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_15" class="md-nav__link">
+  <a href="#yaml_16" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_15" class="md-nav__link">
+  <a href="#python_16" class="md-nav__link">
     Python
   </a>
   
@@ -1305,14 +1359,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_16" class="md-nav__link">
+  <a href="#yaml_17" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_16" class="md-nav__link">
+  <a href="#python_17" class="md-nav__link">
     Python
   </a>
   
@@ -1332,14 +1386,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_17" class="md-nav__link">
+  <a href="#yaml_18" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_17" class="md-nav__link">
+  <a href="#python_18" class="md-nav__link">
     Python
   </a>
   
@@ -1359,14 +1413,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_18" class="md-nav__link">
+  <a href="#yaml_19" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_18" class="md-nav__link">
+  <a href="#python_19" class="md-nav__link">
     Python
   </a>
   
@@ -1386,14 +1440,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_19" class="md-nav__link">
+  <a href="#yaml_20" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_19" class="md-nav__link">
+  <a href="#python_20" class="md-nav__link">
     Python
   </a>
   
@@ -1413,14 +1467,14 @@
       <ul class="md-nav__list">
         
           <li class="md-nav__item">
-  <a href="#yaml_20" class="md-nav__link">
+  <a href="#yaml_21" class="md-nav__link">
     Yaml
   </a>
   
 </li>
         
           <li class="md-nav__item">
-  <a href="#python_20" class="md-nav__link">
+  <a href="#python_21" class="md-nav__link">
     Python
   </a>
   
@@ -1466,6 +1520,7 @@
 <li><a href="#force">Force</a>: defines an Indication of a force by an arrow and a text (symbol)</li>
 <li><a href="#wall">Wall</a>: defines an hached box given starting, ending point and thickness, filled with a pattern</li>
 <li><a href="#curve">Curve</a>: defines a general curve as a sequence of (x,y) coordinates</li>
+<li><a href="#trajectory">Trajectory</a>: defines a general curve as a sequence of Point (subclass Curve)</li>
 <li><a href="#gravity">Gravity</a>: defines a downward-pointing gravity arrow with the symbol g or user given symbol.</li>
 <li><a href="#moment">Moment</a>: defines a Moment arrow with text given text, center and radius</li>
 <li><a href="#text_warrow">Text_wArrow</a>: defines Text, but an arrow is drawn from the mid part of the text to some point arrow_tip</li>
@@ -1740,9 +1795,37 @@ curve.set_name(&quot;curve&quot;)
 </code></pre>
 
 <p><img alt="Curve" src="../reference/curve.svg" /></p>
+<h2 id="trajectory">Trajectory</h2>
+<p><a href="#list-of-shapes">home</a> defines a general curve as a sequence of Point (subclass Curve)</p>
+<h3 id="yaml_14">Yaml</h3>
+<pre><code class="yaml">trajectory=&quot;&quot;&quot;\
+name: trajectory
+shapes:
+    P1: Point(1,-1)
+    P2: P1 + Point(0,2)
+    P3: P2 + Point(-2,0)
+    P4: P3 + Point(0,-2)
+    psq: |
+       [P1,P2,P3,P4]  
+    trajectory: Trajectory(psq)
+&quot;&quot;&quot;
+</code></pre>
+
+<h3 id="python_14">Python</h3>
+<pre><code class="python">P1 = Point(1,-1)
+P2 = P1 + Point(0,2)
+P3 = P2 + Point(-2,0)
+P4 = P3 + Point(0,-2)
+psq = [P1,P2,P3,P4]
+trajectory = Trajectory(psq)
+trajectory.draw()
+curve.set_name(&quot;trajectory&quot;)
+</code></pre>
+
+<p><img alt="Curve" src="../reference/trajectory.svg" /></p>
 <h2 id="gravity">Gravity</h2>
 <p><a href="#list-of-shapes">home</a> defines a downward-pointing gravity arrow with the symbol g or user given symbol.</p>
-<h3 id="yaml_14">Yaml</h3>
+<h3 id="yaml_15">Yaml</h3>
 <pre><code class="yaml">gravity=&quot;&quot;&quot;
 name: gravity
 shapes:
@@ -1753,7 +1836,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_14">Python</h3>
+<h3 id="python_15">Python</h3>
 <pre><code class="python">c = point(0,0)
 r = 2
 gravity = Gravity(c, r, text='$Mg$')
@@ -1763,7 +1846,7 @@ gravity.set_name(&quot;gravity&quot;)
 <p><img alt="Gravity" src="../reference/gravity.svg" /></p>
 <h2 id="moment">Moment</h2>
 <p><a href="#list-of-shapes">home</a> defines a Moment arrow with text given text, center and radius.</p>
-<h3 id="yaml_15">Yaml</h3>
+<h3 id="yaml_16">Yaml</h3>
 <pre><code class="yaml">moment=&quot;&quot;&quot;
 name: moment
 shapes:
@@ -1771,7 +1854,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_15">Python</h3>
+<h3 id="python_16">Python</h3>
 <pre><code class="python">moment = Moment(&quot;$T$&quot;, point(0,0), 2)
 moment.shape_name=&quot;moment&quot;
 </code></pre>
@@ -1779,7 +1862,7 @@ moment.shape_name=&quot;moment&quot;
 <p><img alt="Moment" src="../reference/moment.svg" /></p>
 <h2 id="text_warrow">Text_wArrow</h2>
 <p><a href="#list-of-shapes">home</a> Text, but an arrow is drawn from the mid part of the text to some point arrow_tip</p>
-<h3 id="yaml_16">Yaml</h3>
+<h3 id="yaml_17">Yaml</h3>
 <pre><code class="yaml">txtarrow=&quot;&quot;&quot;
 name: txtarrow
 shapes:
@@ -1787,7 +1870,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_16">Python</h3>
+<h3 id="python_17">Python</h3>
 <pre><code class="python">txtarrow = Text_wArrow(&quot;$Text$&quot;, point(0,0), point(2,2))
 txtarrow.set_name(&quot;txtarrow&quot;)
 </code></pre>
@@ -1795,7 +1878,7 @@ txtarrow.set_name(&quot;txtarrow&quot;)
 <p><img alt="Text_wArrow" src="../reference/textwarrow.svg" /></p>
 <h2 id="wheel">Wheel</h2>
 <p><a href="#list-of-shapes">home</a> Hub and spokes Wheel given center, radius, spokes (default 10), inner_radius(default 1/5 of radius)</p>
-<h3 id="yaml_17">Yaml</h3>
+<h3 id="yaml_18">Yaml</h3>
 <pre><code class="yaml">wheel=&quot;&quot;&quot;
 name: wheel
 shapes:
@@ -1803,7 +1886,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_17">Python</h3>
+<h3 id="python_18">Python</h3>
 <pre><code class="python">wheel = Wheel(point(0,0), 5)
 wheel.set_name(&quot;wheel&quot;)
 </code></pre>
@@ -1811,7 +1894,7 @@ wheel.set_name(&quot;wheel&quot;)
 <p><img alt="Wheel" src="../reference/wheel.svg" /></p>
 <h2 id="spring">Spring</h2>
 <p><a href="#list-of-shapes">home</a> Specify a vertical spring, starting at start and with length as total vertical length</p>
-<h3 id="yaml_18">Yaml</h3>
+<h3 id="yaml_19">Yaml</h3>
 <pre><code class="yaml">spring=&quot;&quot;&quot;
 name: spring
 shapes: 
@@ -1823,7 +1906,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_18">Python</h3>
+<h3 id="python_19">Python</h3>
 <pre><code class="python">spring = Spring(point(0,0),5)
 spring.set_linecolor('black')
 spring.set_linewidth(1)
@@ -1833,7 +1916,7 @@ spring.set_name(&quot;spring&quot;)
 <p><img alt="Spring" src="../reference/spring.svg" /></p>
 <h2 id="dashpot">Dashpot</h2>
 <p><a href="#list-of-shapes">home</a> Defines a vertical dashpot of height <code>total_length</code> and <code>start</code> as bottom/starting point.</p>
-<h3 id="yaml_19">Yaml</h3>
+<h3 id="yaml_20">Yaml</h3>
 <pre><code class="yaml">dashpot=&quot;&quot;&quot;
 name: dashpot
 shapes:
@@ -1841,7 +1924,7 @@ shapes:
 &quot;&quot;&quot;
 </code></pre>
 
-<h3 id="python_19">Python</h3>
+<h3 id="python_20">Python</h3>
 <pre><code class="python">dashpot = Dashpot(point(0,0),5)
 dashpot.set_name(&quot;dashpot&quot;)
 </code></pre>
@@ -1866,7 +1949,7 @@ sketch.append(head)
 </code></pre>
 
 <p>The above code initialize myfig sketch space loading into it libraries references so samples can use tan, radians, si, cos and all the objects defined in pysketcher (the module name of jupytersketcher) and numpy as well: this is used by the yaml definition of shapes</p>
-<h3 id="yaml_20">Yaml</h3>
+<h3 id="yaml_21">Yaml</h3>
 <pre><code class="python">myfig={}
 sketch=&quot;&quot;&quot;
 # put here the yaml 'object' definition
@@ -1879,7 +1962,7 @@ drawing_tool.display()
 display(SVG(Sketch.matplotlib2SVG()))
 </code></pre>
 
-<h3 id="python_20">Python</h3>
+<h3 id="python_21">Python</h3>
 <pre><code class="python">drawing_tool.erase()
 # put the code of the object case here
 # replace object by the actual name line, rectangle, circle...

+ 7 - 7
jupysketch-doc/site/sitemap.xml

@@ -1,31 +1,31 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url><url>
      <loc>None</loc>
-     <lastmod>2020-08-10</lastmod>
+     <lastmod>2020-08-11</lastmod>
      <changefreq>daily</changefreq>
     </url>
 </urlset>

二進制
jupysketch-doc/site/sitemap.xml.gz


文件差異過大導致無法顯示
+ 42 - 397
notebooks/.ipynb_checkpoints/DryFriction-checkpoint.ipynb


文件差異過大導致無法顯示
+ 42 - 483
notebooks/DryFriction.ipynb


+ 1 - 1
notebooks/Gallery.ipynb

@@ -156,7 +156,7 @@
    "name": "python",
    "nbconvert_exporter": "python",
    "pygments_lexer": "ipython3",
-   "version": "3.8.2"
+   "version": "3.8.5"
   }
  },
  "nbformat": 4,

文件差異過大導致無法顯示
+ 32 - 32
notebooks/Reference.ipynb


+ 3 - 0
postBuild

@@ -1,6 +1,9 @@
 conda update -n base conda
 conda update -y notebook
 conda update -y jupyterlab
+pip install jupyter-server-proxy
+pip install mkdocs
+pip install mkdocs-material
 pip install git+https://github.com/pycontribs/ruyaml.git
 pip install ipywidgets
 jupyter labextension update --all