Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
deleted trailing whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
drewitz committed Feb 28, 2018
1 parent 31edde6 commit 231cd56
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 36 deletions.
52 changes: 26 additions & 26 deletions src/doc/en/thematic_tutorials/geometry/lectures.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Lecture 0: Basic definitions and constructions
==============================================

A real :math:`(k\times d)`-matrix :math:`A` and a real vector :math:`b`
in :math:`\mathbb{R}^d` define a (convex) **polyhedron** :math:`P` as the set of solutions
in :math:`\mathbb{R}^d` define a (convex) **polyhedron** :math:`P` as the set of solutions
of the system of linear inequalities:

.. MATH::
Expand All @@ -43,22 +43,22 @@ of the system of linear inequalities:
Each row of :math:`A` defines a closed half-space of :math:`\mathbb{R}^d`.
Hence a polyhedron is the intersection of finitely many closed half-spaces in
:math:`\mathbb{R}^d`. The matrix :math:`A` may contain equal rows, which may lead to a
set of *equalities* satisfied by the polyhedron. If there are no redundant rows
in the above definition, this definition is refered to as the
set of *equalities* satisfied by the polyhedron. If there are no redundant rows
in the above definition, this definition is refered to as the
:math:`\mathbf{H}` **-representation** of a polyhedron.

The maximal affine subspace :math:`L` contained in a polyhedron is the
**lineality** space. Fixing a point :math:`o` of the lineality space to act
**lineality** space. Fixing a point :math:`o` of the lineality space to act
as the *origin*, one can write every point :math:`p` inside a polyhedron as a combination

.. MATH::
p = \ell +\sum_{i=1}^{n}\lambda_iv_i+\sum_{i=1}^{m}\mu_ir_i,
where :math:`\ell\in L` (using :math:`o` as the origin), :math:`\sum_{i=1}^n\lambda_i=1`,
:math:`\mu_i\geq0`, and :math:`r_i\neq0` for all :math:`0\leq i\leq m` and the
set of :math:`r_i` 's are positively independant (the origin is not in their positive span).
There are many equivalent ways write the above, so one asks :math:`n` and :math:`m`
where :math:`\ell\in L` (using :math:`o` as the origin), :math:`\sum_{i=1}^n\lambda_i=1`,
:math:`\mu_i\geq0`, and :math:`r_i\neq0` for all :math:`0\leq i\leq m` and the
set of :math:`r_i` 's are positively independant (the origin is not in their positive span).
There are many equivalent ways write the above, so one asks :math:`n` and :math:`m`
to be minimal with that property.

The points :math:`v_i` 's are called the *vertices* of :math:`P` and the points
Expand All @@ -71,7 +71,7 @@ polyhedral cone* generated by finitely many rays.
When the lineality space and the rays are reduced to a point (i.e. no rays and
no lines) the object is often refered to as a **polytope**.

.. note :: As mentioned in the documentation of the constructor when typing :code:`Polyhedron?`,
.. note :: As mentioned in the documentation of the constructor when typing :code:`Polyhedron?`,
*You may either define it with vertex/ray/line or
inequalities/equations data, but not both. Redundant data will
Expand Down Expand Up @@ -231,7 +231,7 @@ polyhedron over it:

.. end of output
Similarly, it is not possible to create polyhedron objects over :code:`RR`
Similarly, it is not possible to create polyhedron objects over :code:`RR`
(no matter how many bits of precision).

::
Expand Down Expand Up @@ -281,8 +281,8 @@ without having specified the base ring :code:`RDF` by the user.
`H`-representation
------------------

If a polyhedron object was constructed via a :math:`V`-representation, Sage can provide
the :math:`H`-representation of the object.
If a polyhedron object was constructed via a :math:`V`-representation, Sage can provide
the :math:`H`-representation of the object.

::

Expand All @@ -309,7 +309,7 @@ defined. The :math:`H`-representation may contain equations:
The construction of a polyhedron object via its :math:`H`-representation,
requires a precise format. Each inequality :math:`(a_{i1}, \dots, a_{id})\cdot
x + b_i \geq 0` must be written as :code:`[b_i,a_i1, ..., a_id]`.
x + b_i \geq 0` must be written as :code:`[b_i,a_i1, ..., a_id]`.

::

Expand Down Expand Up @@ -354,20 +354,20 @@ second group of four rows.

.. end of output
Of course, this is a toy example, but it is generally worth to preprocess
Of course, this is a toy example, but it is generally worth to preprocess
the data before defining the polyhedron if possible.

Lecture 1: Representation objects
===================================

Many objects are related to the :math:`H`- and :math:`V`-representations. Sage
Many objects are related to the :math:`H`- and :math:`V`-representations. Sage
has classes implemented for them.

`H`-representation
------------------

You can store the :math:`H`-representation in a variable and use the
inequalities and equalities as objects.
inequalities and equalities as objects.

::

Expand Down Expand Up @@ -409,7 +409,7 @@ as follows.
.. NOTE ::
It is recommended to use :code:`equations` or :code:`equation_generator`
It is recommended to use :code:`equations` or :code:`equation_generator`
(and similarly for inequalities) if one wants to iterate over them instead
of :code:`equations_list`.
Expand Down Expand Up @@ -465,7 +465,7 @@ as follows.
.. NOTE ::
It is recommended to use :code:`vertices` or :code:`vertex_generator`
It is recommended to use :code:`vertices` or :code:`vertex_generator`
(and similarly for rays and lines) if one wants to iterate over them instead
of :code:`vertices_list`.
Expand All @@ -491,13 +491,13 @@ These backends offer various functionalities and have their own specific strengt

- This is a :code:`python` backend that provides an implementation of
polyhedron over irrational coordinates.

- :ref:`sage.geometry.polyhedron.backend_normaliz`, (requires the optional package :code:`pynormaliz`)

- `Normaliz Homepage <https://www.normaliz.uni-osnabrueck.de/>`_


The default backend is :code:`ppl`. Whenever one needs **speed** it is good to try out
The default backend is :code:`ppl`. Whenever one needs **speed** it is good to try out
the different backends. The backend :code:`field` is **not** specifically designed
for dealing with extremal computations but can do computations in exact
coordinates.
Expand Down Expand Up @@ -617,7 +617,7 @@ The default backend for polyhedron objects i :code:`ppl`.

.. end of output
As you see, it does not accepts values in :code:`RDF` and the polyhedron constructor
As you see, it does not accepts values in :code:`RDF` and the polyhedron constructor
used the :code:`cdd` backend.

The :code:`polymake` backend
Expand Down Expand Up @@ -647,7 +647,7 @@ An example with quadratic field:
The :code:`field` backend
-------------------------

As it turns out, the rational numbers do not suffice to represent all combinatorial
As it turns out, the rational numbers do not suffice to represent all combinatorial
types of polytopes. For example, Perles constructed a `8`-dimensional polytope with
`12` vertices which does not have a realization with rational coordinates, see
Example 6.21 p. 172 of [Zie2007]_.
Expand Down Expand Up @@ -710,7 +710,7 @@ This backend does not work with :code:`RDF`, or algebraic numbers or the :code:`

sage: P4_normaliz = Polyhedron(vertices = [[sqrt_2, 0], [0, cbrt_2]], backend='normaliz') # optional - pynormaliz
Traceback (most recent call last):
...
...
ValueError: No such backend (=normaliz) implemented for given basering (=Algebraic Real Field).

sage: P5_normaliz = Polyhedron(vertices = [[sqrt_2s, 0], [0, cbrt_2s]], backend='normaliz') # optional - pynormaliz
Expand All @@ -720,7 +720,7 @@ This backend does not work with :code:`RDF`, or algebraic numbers or the :code:`

.. end of output
The backend :code:`normaliz` provides other methods such as
The backend :code:`normaliz` provides other methods such as
:code:`integral_hull`, which also works on unbounded polyhedron.

::
Expand All @@ -746,7 +746,7 @@ In order to **know all the methods that a polyhedron object has** one has to loo
- :ref:`sage.geometry.polyhedron.base_RDF`

Don't be surprised if the classes look empty! The classes mainly contain private
methods that implement some comparison methods: to verify equality and inequality
methods that implement some comparison methods: to verify equality and inequality
of numbers in the base ring and other internal functionalities.

To get a full overview of methods offered to you, :ref:`sage.geometry.polyhedron.base` is the first place you want to go.
Expand Down Expand Up @@ -788,5 +788,5 @@ Bibliography
978-1-4613-0019-9
.. [Zie2007] Ziegler, G. M., Lectures on polytopes, volume 152 of Graduate
Texts in Mathematics. Springer-Verlag, New York, 2007.
Texts in Mathematics. Springer-Verlag, New York, 2007.
ISBN 978-0-387-94365-7
8 changes: 4 additions & 4 deletions src/doc/en/thematic_tutorials/geometry/polytope_tikz.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Then, you can either copy-paste it to your article by typing ``Img`` in Sage or

.. end of output
Then in the pwd (present working directory of sage, the one of your article)
Then in the pwd (present working directory of sage, the one of your article)
you will have a file named ``Img_poly.tex`` containing the tikzpicture of your polytope.

Customization
Expand Down Expand Up @@ -77,7 +77,7 @@ In Sage, you type:
Then, you visualize the polytope by typing ``P.show(aspect_ratio=1)``

When you found a good angle, follow the above procedure to obtain the values
When you found a good angle, follow the above procedure to obtain the values
[674,108,-731] and angle=112, for example.

::
Expand Down Expand Up @@ -117,7 +117,7 @@ It is also possible to replace it by the following 4 lines (and adding ``\usetik

.. end of output
Finally, you may want to tweak your picture my adding labels, elements on
Finally, you may want to tweak your picture my adding labels, elements on
vertices, edges, facets, etc.

Automatize using SageTex
Expand All @@ -129,7 +129,7 @@ For this you need to put

in the preamble of your article

There are different ways to use sagetex and you may create your own. Here are
There are different ways to use sagetex and you may create your own. Here are
some possibilities.

1) You can directly type in a sagestr in the article:
Expand Down
10 changes: 5 additions & 5 deletions src/doc/en/thematic_tutorials/geometry/polytutorial.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ A Brief Introduction to Polytopes in Sage

If you already know some convex geometry *a la* Grünbaum or
Brøndsted, then you may have itched to get your hands dirty with some
polytope calculations. Here is a mini\-guide to doing just that.
polytope calculations. Here is a mini\-guide to doing just that.

Basics
""""""
Expand Down Expand Up @@ -114,7 +114,7 @@ Surely you want to compute the polar dual:
Check it out\-\-\-we started with an integer\-lattice polytope and dualized
to a rational\-lattice polytope. Let's look at that.




::
Expand Down Expand Up @@ -171,7 +171,7 @@ at this...

.. end of output
Here is what's going on.
Here is what's going on.

If a polytope ``P`` is in `\ZZ`, then...

Expand All @@ -190,7 +190,7 @@ However, if a polytope is *not* in `\ZZ`, for example if it's in `\QQ` or

Keep all of this in mind as you take polar duals.



Polytope Constructions
""""""""""""""""""""""
Expand Down Expand Up @@ -350,7 +350,7 @@ Once you've constructed some polytope, you can ask Sage questions about it.

.. end of output
Face information can be useful.
Face information can be useful.


::
Expand Down
2 changes: 1 addition & 1 deletion src/doc/en/thematic_tutorials/geometry/visualization.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ This plots the graph (with unbounded edges) of the polyhedron

.. end of output
:code:`plot`
:code:`plot`
==================================================

The :code:`plot` method draws the graph, the polygons and vertices of the
Expand Down

0 comments on commit 231cd56

Please sign in to comment.