Ejemplo n.º 1
0
<?php

include 'garrisonsmath.php';
$func = new GarrisonsMath();
$func->printDoMathPage();
if (!empty($_POST)) {
    $x = $_POST["x"];
    $h = $_POST["h"];
    $before = ($func->mathstuff($x + $h) - $func->mathstuff($x)) / $h;
    echo "before (((x+h)^2 + 7(x+h) + 2) - (x^2 + 7x + 2)) / h: = " . $before;
    echo "<br>after (2x + h  + 7): = " . $func->simple($x, $h);
}
Ejemplo n.º 2
0
<?php

include "garrisonsmath.php";
$gmath = new GarrisonsMath();
$gmath->printRecPage();
$gmath->printXYDrawForm();
if (key_exists("x", $_POST) && key_exists("y", $_POST)) {
    $gmath->drawRec($_POST["x"], $_POST["y"]);
}
$gmath->printGuessDrawForm();
if (key_exists("parameter_g", $_POST)) {
    $gmath->guessRec($_POST["parameter_g"]);
}
$gmath->printOptimizedForm();
if (key_exists("parameter", $_POST)) {
}
$gmath->printEnd();