-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.cpp
2 lines (2 loc) · 2.92 KB
/
default.cpp
1
2
//char DRULES[]="x fgh abc mn x +- */ ^ diff 100 1 1\n70\nsin(x) 1 cos(x)\ncos(x) 1 -(sin(x))\ntg(x) 1 1/((cos(x))^2)\nctg(x) 1 (-(1))/((sin(x))^2)\nsec(x) 1 (sin(x))/((cos(x))^2)\ncosec(x) 1 (-(cos(x)))/((sin(x))^2)\nexp(x) 1 exp(x)\nln(x) 1 1/x\nsqrt(x) 1 1/(2*(sqrt(x)))\nerf(x) 1 (2/(sqrt(pi)))*(e^(-(x^2)))\narcsin(x) 1 1/(sqrt(1-(x^2)))\narccos(x) 1 (-(1))/(sqrt(1-(x^2)))\narctg(x) 1 1/(1+(x^2))\narcctg(x) 1 (-(1))/(1+(x^2))\nabs(f) 1 diff(sqrt(f)^2)\nx^a 1 a*x^(a-1)\nf+g 1 (diff(f))+(diff(g))\nf-g 1 (diff(f))-(diff(g))\nf*g 1 diff(f)*g+f*diff(g)\nf/g 1 (diff(f)*g-f*diff(g))/g^2\nf^g 1 diff(exp(ln(f)*g))\n-(f) 1 -(diff(f))\nf(g) 1 (diff(g))*(diffm(f(m)))|m=g\nx 1 1\na 1 0\nsin(x)^2+cos(x)^2 0 1\n0*f 0 0\nf*1 0 f\n0+f 0 f\nf-0 0 f\n0-f 0 -(f)\n0/f 0 0\nf^1 0 f\nf^0 0 1\n1/(f^g) 0 f^-g\n(f*g)+(f*h) 0 f*(g+h)\nf+(-(g)) 0 f-g\nf+g 0 g+f\nf*g 0 g*f\n(f+g)+h 0 f+(g+h)\n(f*g)*h 0 f*(g*h)\nf^2+g^2+2*f*g 0 (f+g)^2\nf^2+g^2-2*f*g 0 (f-g)^2\n(f-g)*(f+g) 0 (f^2)-(g^2)\nf+f 0 2*f\n(a*f)+(b*f) 0 (a+b)*f\nf+g*f 0 (1+g)*f\nexp(ln(f)*g) 0 f^g\n-(-f) 0 f\nf+g*(-h) 0 f-g*h\nf*(1/g) 0 f/g\nf+((-g)/h) 0 f-(g/h)\nsin(x)/cos(x) 0 tg(x)\ncos(x)/sin(x) 0 ctg(x)\nf/f 0 1\nf+(g+h) 0 (f+g)+h\n(f+g)+h 0 f+(g+h)\nf+(g-h) 0 (f+g)-h\na*f+f 0 (a+1)*f\na+b 0 calc(a+b)\na-b 0 calc(a-b)\na*b 0 calc(a*b)\na^b 0 calc(a^b)\nf*(g*h) 0 (f*g)*h\na*f-b*f 0 (a-b)*f\nf*0 0 0\n1*f 0 f\nf+0 0 f\nx+x 0 2*x\n1/x*x 0 1\n(-f)/g 0 -(f/g)\n(-f)*g 0 -(f*g)";
char DRULES[]="x fgh abc mn x +- */ ^ diff 100 1 1\n75\nsin(x) 1 cos(x)\ncos(x) 1 -sin(x)\ntg(x) 1 1/((cos(x))^2)\nctg(x) 1 (-1)/((sin(x))^2)\nsec(x) 1 (sin(x))/((cos(x))^2)\ncosec(x) 1 (-cos(x))/((sin(x))^2)\nexp(x) 1 exp(x)\nln(x) 1 1/x\nsqrt(x) 1 1/(2*(sqrt(x)))\nerf(x) 1 (2/(sqrt(pi)))*(e^(-(x^2)))\narcsin(x) 1 1/(sqrt(1-(x^2)))\narccos(x) 1 (-1)/(sqrt(1-(x^2)))\narctg(x) 1 1/(1+(x^2))\narcctg(x) 1 (-1)/(1+(x^2))\nabs(f) 1 diff((sqrt(f))^2)\nx^a 1 a*(x^(a-1))\nf+g 1 (diff(f))+(diff(g))\nf-g 1 (diff(f))-(diff(g))\nf*g 1 ((diff(f))*g)+(f*(diff(g)))\nf/g 1 (((diff(f))*g)-(f*(diff(g))))/(g^2)\nf^g 1 diff(exp((ln(f))*g))\n-f 1 -diff(f)\nf(g) 1 (diff(g))*(diffm(f(m)))|m=g\nx 1 1\na 1 0\n((sin(x))^2)+((cos(x))^2) 0 1\n0*f 0 0\nf*1 0 f\n0+f 0 f\nf-0 0 f\n0-f 0 -f\n0/f 0 0\nf^1 0 f\nf^0 0 1\n1/(f^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