Ask Your Question

Revision history [back]

With sage cell server implement an automatically generated and automatically checks the job in algebra or calculus.

Hello! I have a problem. How to organize a dialogue with the user? So that he could enter a reply, and the server gave the answer: right or wrong. On the example of computing the determinant of a matrix. The following quote program listing.

<html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width"> <title>Sage Cell Server</title> <script src="https://sagecell.sagemath.org/static/jquery.min.js"></script> <script src="https://sagecell.sagemath.org/static/embedded_sagecell.js"></script> <script>$(function () { // Make the div with id 'mycell' a Sage cell sagecell.makeSagecell({inputLocation: '#mycell1', template: sagecell.templates.minimal, evalButtonText: 'Generate'}); sagecell.makeSagecell({inputLocation: 'div.compute', evalButtonText: 'Evaluate'}); sagecell.makeSagecell({inputLocation: '#mycell2', template: sagecell.templates.minimal, evalButtonText: 'Generate'});

});
</script>

</head>

<body>

Calculate the determinant

<div id="mycell1"><script type="text/x-sage">

A=random_matrix(ZZ, 2, 2, x=-5, y=5)

D=A.det()

A=show(A)

</script>

<div class="compute"><script type="text/x-sage"></script></div>

</body> </html>

With sage cell server implement an automatically generated and automatically checks the job in algebra or calculus.

Hello! I have a problem. How to organize a dialogue with the user? So that he could enter a reply, and the server gave the answer: right or wrong. On the example of computing the determinant of a matrix. The following quote program listing.

<html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width"> content="width=device-width">

<title>Sage Cell Server</title>
  <script src="https://sagecell.sagemath.org/static/jquery.min.js"></script>
 <script src="https://sagecell.sagemath.org/static/embedded_sagecell.js"></script>
  <script>$(function () {
 // Make the div with id 'mycell' a Sage cell
 sagecell.makeSagecell({inputLocation:  '#mycell1',
                        template:       sagecell.templates.minimal,
                        evalButtonText: 'Generate'});
 sagecell.makeSagecell({inputLocation: 'div.compute',
                        evalButtonText: 'Evaluate'});
 sagecell.makeSagecell({inputLocation:  '#mycell2',
                        template:       sagecell.templates.minimal,
                        evalButtonText: 'Generate'});

'Generate'});

});
</script>

</head>

<body>

Calculate the determinant

<div id="mycell1"><script type="text/x-sage">

A=random_matrix(ZZ, 2, 2, x=-5, y=5)

D=A.det()

A=show(A)

</script>

<div class="compute"><script type="text/x-sage"></script></div>

</body> </html>

With sage cell server implement an automatically generated and automatically checks the job in algebra or calculus.

Hello! I have a problem. How to organize a dialogue with the user? So that he could enter a reply, and the server gave the answer: right or wrong. On the example of computing the determinant of a matrix. The following quote program listing.

<html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width">

<title>Sage Cell Server</title>

<script src="https://sagecell.sagemath.org/static/jquery.min.js"></script>
<script src="https://sagecell.sagemath.org/static/embedded_sagecell.js"></script>

<script>$(function () {
// Make the div with id 'mycell' a Sage cell
sagecell.makeSagecell({inputLocation:  '#mycell1',
                       template:       sagecell.templates.minimal,
                       evalButtonText: 'Generate'});
sagecell.makeSagecell({inputLocation: 'div.compute',
                       evalButtonText: 'Evaluate'});
sagecell.makeSagecell({inputLocation:  '#mycell2',
                       template:       sagecell.templates.minimal,
                       evalButtonText: 'Generate'});

});
</script>

</head>

<body>

Calculate the determinant

<body>

<h1>Calculate the determinant</h1>

<div id="mycell1"><script type="text/x-sage">

A=random_matrix(ZZ, 2, 2, x=-5, y=5)

D=A.det()

A=show(A)

</script>

<div class="compute"><script type="text/x-sage"></script></div>

</body> </html>

click to hide/show revision 4
No.4 Revision

updated 2013-11-05 09:50:38 -0500

kcrisman gravatar image

With sage cell server implement an automatically generated and automatically checks the job in algebra or calculus.

Hello! I have a problem. How to organize a dialogue with the user? So that he could enter a reply, and the server gave the answer: right or wrong. On the example of computing the determinant of a matrix. The following quote program listing.

<!DOCTYPE HTML>
<html>
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width">

content="width=device-width">

    <title>Sage Cell Server</title>

 <script src="https://sagecell.sagemath.org/static/jquery.min.js"></script>
 <script src="https://sagecell.sagemath.org/static/embedded_sagecell.js"></script>

 <script>$(function () {
 // Make the div with id 'mycell' a Sage cell
 sagecell.makeSagecell({inputLocation:  '#mycell1',
                        template:       sagecell.templates.minimal,
                        evalButtonText: 'Generate'});
 sagecell.makeSagecell({inputLocation: 'div.compute',
                        evalButtonText: 'Evaluate'});
 sagecell.makeSagecell({inputLocation:  '#mycell2',
                        template:       sagecell.templates.minimal,
                        evalButtonText: 'Generate'});

 });
 </script>

</head>

<body>

  </head>


  <body>

    <h1>Calculate the determinant</h1>

 <div id="mycell1"><script type="text/x-sage">

A=random_matrix(ZZ, 2, 2, x=-5, y=5)

D=A.det()

A=show(A)

y=5) D=A.det() A=show(A) </script>

</div>

    <div class="compute"><script type="text/x-sage"></script></div>

  </body>
</html>

</body> </html>

click to hide/show revision 5
retagged

With sage cell server implement an automatically generated and automatically checks the job in algebra or calculus.

Hello! I have a problem. How to organize a dialogue with the user? So that he could enter a reply, and the server gave the answer: right or wrong. On the example of computing the determinant of a matrix. The following quote program listing.

<!DOCTYPE HTML>
<html>
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width">

    <title>Sage Cell Server</title>

    <script src="https://sagecell.sagemath.org/static/jquery.min.js"></script>
    <script src="https://sagecell.sagemath.org/static/embedded_sagecell.js"></script>

    <script>$(function () {
    // Make the div with id 'mycell' a Sage cell
    sagecell.makeSagecell({inputLocation:  '#mycell1',
                           template:       sagecell.templates.minimal,
                           evalButtonText: 'Generate'});
    sagecell.makeSagecell({inputLocation: 'div.compute',
                           evalButtonText: 'Evaluate'});
    sagecell.makeSagecell({inputLocation:  '#mycell2',
                           template:       sagecell.templates.minimal,
                           evalButtonText: 'Generate'});

    });
    </script>
  </head>


  <body>

    <h1>Calculate the determinant</h1>

    <div id="mycell1"><script type="text/x-sage">
A=random_matrix(ZZ, 2, 2, x=-5, y=5)

D=A.det()

A=show(A)

 </script>
</div>

    <div class="compute"><script type="text/x-sage"></script></div>

  </body>
</html>