skip to navigation
skip to content

megua 2016.1.1a1

MEGUA project for SageMath

MEGUA package for SageMath and SageMath Cloud
=============================================

MEGUA is a package for SageMath for creating parametrized exercises in HTML+MathJAX or LaTeX+PDF files (more formats are planned).

This tutorials are older than code but give a good ideia of the topics of this project:

* `Tutorial em português <http: megua.readthedocs.io="" pt="" latest=""/>`_
* `Tutorial in english <http: megua.readthedocs.io="" en="" latest=""/>`_
* Contact: pedrocruz@ua.pt

Development state: `alpha version <https: en.wikipedia.org="" wiki="" software_release_life_cycle#alpha="">`_


INSTALL and USE in SageMath Cloud (SMC)
---------------------------------------


1. Create an account in SMC `https://cloud.sagemath.com`_,
::


- then create a project;
- other users must create an account
- and then add them to this project.


2. Create a terminal named BASH.term
::


- Button "+NEW"
- Change name to "BASH"
- Press ">_Terminal" button


3. In the terminal do:
::

$ sage -pip install --user git+https://github.com/jpedroan/megua


4. Run for initialization:
::

$ megua

5. Change working options with (portuguese: for siacua system see bellow):
::

$ open ~/.megua/conf.py

6. Create the first exercise targeting LaTeX (a worksheet will open)
::

$ megua new E12X34_AddTwoNumbers_001_latex.sagews


7. Create a catalog of all exercises:
::

$ megua catalog


8. More options with:
::

$ megua help



MEGUA para o sistema SIACUA (português)
---------------------------------------

As instruções seguintes são para o sistema SIACUA (siacua.web.ua.pt).

- Devem ser realizados os passos de instalação mencionados acima.

- Em particular, deve ser criado um terminal com nome BASH.term

- O SIACUA requer o nome do curso, um username e uma password de sistema. Para isso deve ser editar 'conf.py' com:
::

$ open ~/.megua/conf.py

- Contacto luisd@ua.pt ou pedrocruz@ua.pt para ajuda.
::

- A conversão de exercícios de "SIACUA" para "LaTeX" está satisfatória e outras conversões vão sendo criadas.

Para criar exercícios:


1. Criar um exercício para o SIACUA (esta etapa abre uma janela com o novo exercício)
::

$ megua new E12X34_AddTwoNumbers_001_siacua.sagews


2. Criar um catálogo com todos os exercícios transcritos para um ficheiro LaTeX (catalog.tex):
::

$ megua catalog



HISTORY
-------


Started in 2011, MEGUA is an external package for Sagemath for creating parametrized exercises in HTML+MathJAX or LaTeX PDF files. Software docs strings are in english but the following documentation is in [portuguese](https://pt.wikipedia.org/wiki/L%C3%ADngua_portuguesa):

- `MEGUA PACKAGE FOR PARAMETERIZED EXERCISES <http: cms.ua.pt="" megua="">`_: people, works, seminars, and related things.
- `Tutorial (portuguese) <http: megua.readthedocs.org="" pt="" latest=""/>`_: concepts and practice.

Presented at:

- `MEGUA PACKAGE FOR PARAMETERIZED EXERCISES <http: library.iated.org="" view="" cruz2013meg="">`_


There are two branches in this repository:

- **master**: version to be adopted for SageMathCloud use, command-line, etc.
- **old_megua**: running in a non public server from november 2010 to 2015.


DEVELOPMENT NOTES
-----------------

* etoolbox.sty: sudo apt-get install texlive-latex-extra

* salvus: /projects/sage/sage-6.10/local/lib/python2.7/site-packages/smc_sagews

* from smc_sagews.sage_salvus import salvus #Functions: salvus.file(), salvus.html()

* sage_server.py: contains definitions of "def file()" and "def html()", see useful arguments

* decorators dynamically alter the functionality of a function, method or class without having to directly use subclasses, http://thecodeship.com/patterns/guide-to-python-function-decorators/

* http://doc.sagemath.org/html/en/reference/calculus/sage/symbolic/function_factory.html


**Answered questions by SMC team**

- startup file for sagews

- https://groups.google.com/forum/#!topic/sage-cloud/L-9QwvlfnvY
- https://github.com/sagemathinc/smc/issues/369

- about "salvus"

HTML and Links

- https://groups.google.com/forum/#!searchin/sage-cloud/salvus/sage-cloud/dg4mhp99cOg/9LiiIdEonlYJ

Images

- https://groups.google.com/forum/#!searchin/sage-cloud/salvus/sage-cloud/-nChfU76j7Q/D-y8rIPfUngJ


**END**  
File Type Py Version Uploaded on Size
megua-2016.1.1a1.tar.gz (md5)
It needs SageMath
Python Egg 2.7 2016-08-20 491KB