17
STACK TAKAYUKI MATSUKI (TOKYO KASEI UNIV./BOARD MEMBER OF MOODLE ASSOCIATION OF JAPAN) USING MAXIMA TO PROVIDE PROBLEMS/ANALYSIS OF ANSWERS 1

English version of STACK

Embed Size (px)

Citation preview

Page 1: English version of STACK

STACKTAKAYUKI MATSUKI (TOKYO KASEI UNIV./BOARD MEMBER OF MOODLE ASSOCIATION OF JAPAN)

USING MAXIMA TO PROVIDE PROBLEMS/ANALYSIS OF ANSWERS

1

Page 2: English version of STACK

Index

About STACK

How to install STACK/Maxima

Problem occurring after installing STACK

Solution to the problem

How to construct algebraic problems

Use with figures by gnuplot

Severe drawback/bug(?) of STACK

2

Note: “¥” should be replaced with “backslash” in the following

Page 3: English version of STACK

Home Page of STACK 3

Page 4: English version of STACK

About STACK

Moodle plugin to present algebraic problems

Plugins

Question types

True/False, STACK, …

Necessary Software CAS(Computer AlgebraSystem : algebraic software ; like Mathematica,Maple)

Plugin : STACK

Maxima 5.35.1 (CAS)

Latest Ver. : 5.36.1 : 5.23.2~5.36.0 (for Moodle2.8)

gnuplot (software for drawing curves)

4

Page 5: English version of STACK

How to install

CentOS

Install STACK

Go to github repository and read instructions

https://github.com/maths/moodle-qtype_stack/blob/master/doc/en/Installation/index.md

Install three plugins (question/behavior/ )

dfexplicitvaildate, dfcbmexplicitvaildate, adaptivemultipart

Install STACK itself

question/type/stack

mod/quiz/report/stack

question/format/stack

5

Page 6: English version of STACK

Install Maxima

Install Maxima

In the case of CentOS 6

# yum install maxima

Minimum Ver.3.23.2 is installed from epel repository

How to install latest version (Ver.5.36.0)

sbcl-1.2.7(Common Lisp) + maxima-5.36.1

# ./configure –enable-sbcl

# make

# make install

6

Page 7: English version of STACK

Problems after installing

moodle/question/type/stack/healthcheck.php

Error check when STACK is installed

Error message : not connected with CAS(maxima)

Reason : due to SELinux

http cannot access to maxima

# ps -eZ | grep httpd

unconfined_u:system_r:httpd_t:s0 4738 ?

00:01:33 httpd

# ls -Z /usr/local/lib/maxima/5.35.1/binary-

gcl/maxima

-rwxrwxrwx. apache apache

system_u:object_r:lib_t:s0

/usr/local/lib/maxima/5.35.1/binary-gcl/maxima

Diffe

ren

t lab

els

7

One line

Additional column for security data

One line

Page 8: English version of STACK

Solution to problems

1.Simplest solution

# setenforce Permissive

2.Prepare a policy file, mypolicy, and apply it to

OS

# yum install policycoreutils-python

# audit2allow –M mylisp –l –I

/var/log/audit/audit.log

Generate mylisp.pp, mylisp.te

# semodule –i mylisp.pp

Binary file Text file

8

One line

Page 9: English version of STACK

Construction of problems

Construct problem sentence

Equations are written in MathJax/TeX

Sentence :

Looks like

Student’s

answer

goes

into ans1

Answer box

9

problem

Page 10: English version of STACK

How to write in STACK 10

Help by Toyama

Univ. (rather old)

Page 11: English version of STACK

Construction of problems

Input : ans1

Correct answer

Maxima style (looks like the same as MathJax/TeX)

(2*x+1)*(x^2+2*x+3)+(x^2+1)*(2*x+2)

11

Substitute correct answer

in Maxima style

Need “*”

Page 12: English version of STACK

Construction of problems

(Feedbacks)

Potential response tree : prt1

SAns:write “ans1”

Tans : insert “correct answer”

Write in Stack/Maxima style

(2*x+1)*(x^2+2*x+3)+(x^2+1)*(2*x+2)

Or give solution by Maxima function

diff((x^2+1)*(x^2+2*x+3), x)

12

Page 13: English version of STACK

Use with gnuplot

Add graph with a problem

Calculate differentiation of ¥(¥frac{x}{x^2+1}¥) .

Function in blue and its differentiation in red.

@plot([x/(1+x^2),diff(x/(1+x^2),x)],[x,-3,3])@

Equation sandwitched ¥( and ¥) (inline expression)

display expression : use ¥[ and ¥]

Use @ for Maxima commands

plot function is converted into gnuplot

13

Page 14: English version of STACK

Problem with figure 14

Page 15: English version of STACK

Drawback of STACK

Can insert maxima commands in “ans1”

Obtain answer when inserting maxima command

15

Solution !

Page 16: English version of STACK

Summary

Large possibility of STACK

Problems when installing

Relatively easy to install maxima, gnuplot

Problem in connecting with Moodle (CASconnection)

Note where to put correct answer

Especially note potential response tree

Very effective when inserting figures by gnuplot

Remedy a big drawback (bug)

Don’t deeply teach smart students

Especially don’t tell them maxima (*^-^*)

16

Page 17: English version of STACK

Extra

Chemistry plugin Chemistry editor

atto_chemistry

https://moodle.org/plugins/pluginversions.php?plugin=atto_chemistry

How to install

Configure MathJax

TeX: { extensions: ["AMSmath.js","AMSsymbols.js","mhchem.js","noErrors.js","noUndefined.js"] },

Configure TeX

¥usepackage{mhchem}

Configure Atto Toolbar

insert = chemistry, equation, charmap, table, clear

17