mathai 0.3.5__tar.gz → 0.3.6__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. {mathai-0.3.5 → mathai-0.3.6}/PKG-INFO +1 -1
  2. {mathai-0.3.5 → mathai-0.3.6}/mathai/integrate.py +6 -3
  3. {mathai-0.3.5 → mathai-0.3.6}/mathai.egg-info/PKG-INFO +1 -1
  4. {mathai-0.3.5 → mathai-0.3.6}/setup.py +1 -1
  5. {mathai-0.3.5 → mathai-0.3.6}/README.md +0 -0
  6. {mathai-0.3.5 → mathai-0.3.6}/mathai/__init__.py +0 -0
  7. {mathai-0.3.5 → mathai-0.3.6}/mathai/apart.py +0 -0
  8. {mathai-0.3.5 → mathai-0.3.6}/mathai/base.py +0 -0
  9. {mathai-0.3.5 → mathai-0.3.6}/mathai/console.py +0 -0
  10. {mathai-0.3.5 → mathai-0.3.6}/mathai/diff.py +0 -0
  11. {mathai-0.3.5 → mathai-0.3.6}/mathai/expand.py +0 -0
  12. {mathai-0.3.5 → mathai-0.3.6}/mathai/factor.py +0 -0
  13. {mathai-0.3.5 → mathai-0.3.6}/mathai/fraction.py +0 -0
  14. {mathai-0.3.5 → mathai-0.3.6}/mathai/inverse.py +0 -0
  15. {mathai-0.3.5 → mathai-0.3.6}/mathai/limit.py +0 -0
  16. {mathai-0.3.5 → mathai-0.3.6}/mathai/linear.py +0 -0
  17. {mathai-0.3.5 → mathai-0.3.6}/mathai/logic.py +0 -0
  18. {mathai-0.3.5 → mathai-0.3.6}/mathai/parser.py +0 -0
  19. {mathai-0.3.5 → mathai-0.3.6}/mathai/printeq.py +0 -0
  20. {mathai-0.3.5 → mathai-0.3.6}/mathai/search.py +0 -0
  21. {mathai-0.3.5 → mathai-0.3.6}/mathai/simplify.py +0 -0
  22. {mathai-0.3.5 → mathai-0.3.6}/mathai/structure.py +0 -0
  23. {mathai-0.3.5 → mathai-0.3.6}/mathai/tool.py +0 -0
  24. {mathai-0.3.5 → mathai-0.3.6}/mathai/trig.py +0 -0
  25. {mathai-0.3.5 → mathai-0.3.6}/mathai/univariate_inequality.py +0 -0
  26. {mathai-0.3.5 → mathai-0.3.6}/mathai.egg-info/SOURCES.txt +0 -0
  27. {mathai-0.3.5 → mathai-0.3.6}/mathai.egg-info/dependency_links.txt +0 -0
  28. {mathai-0.3.5 → mathai-0.3.6}/mathai.egg-info/requires.txt +0 -0
  29. {mathai-0.3.5 → mathai-0.3.6}/mathai.egg-info/top_level.txt +0 -0
  30. {mathai-0.3.5 → mathai-0.3.6}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mathai
3
- Version: 0.3.5
3
+ Version: 0.3.6
4
4
  Summary: Mathematics solving Ai tailored to NCERT
5
5
  Home-page: https://github.com/infinity390/mathai4
6
6
  Author: educated indians are having a low iq and are good for nothing
@@ -134,7 +134,8 @@ def solve_integrate(eq):
134
134
  eq2 = dowhile(eq, _solve_integrate)
135
135
  eq2 = dowhile(eq2, handle_try)
136
136
  eq2 = rm(eq2)
137
- eq2.children = list(set(eq2.children))
137
+ if eq2.name == "f_try":
138
+ eq2.children = list(set(eq2.children))
138
139
  return eq2
139
140
  def integrate_subs(equation, term, v1, v2):
140
141
  output = []
@@ -385,16 +386,18 @@ def integrate_formula(equation):
385
386
  integrand = eq2.children[0]
386
387
  wrt = eq2.children[1]
387
388
  if integrand == wrt:
388
- return TreeNode("f_add", [TreeNode("f_power", [wrt.copy_tree(), TreeNode("2")]), TreeNode("f_div", [TreeNode("1"), TreeNode("2")])]) # x^2/2
389
+ return wrt**2/2 # x^2/2
389
390
  if not contain(integrand, wrt):
390
- return TreeNode("f_mul", [wrt.copy_tree(), integrand.copy_tree()]) # constant * dx
391
+ return integrand*wrt
391
392
  out = transform_formula(simplify(trig0(integrand)), wrt.name, formula_gen[0], formula_gen[1], formula_gen[2])
392
393
  if out is not None:
394
+
393
395
  return out
394
396
  expr_str = str_form(integrand)
395
397
  if expr_str.count("f_sin") + expr_str.count("f_cos") > 2:
396
398
  out = transform_formula(integrand, wrt.name, formula_gen4[0], formula_gen4[1], formula_gen4[2])
397
399
  if out is not None:
400
+
398
401
  return out
399
402
  return TreeNode(eq2.name, [integrate_formula(child) for child in eq2.children])
400
403
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mathai
3
- Version: 0.3.5
3
+ Version: 0.3.6
4
4
  Summary: Mathematics solving Ai tailored to NCERT
5
5
  Home-page: https://github.com/infinity390/mathai4
6
6
  Author: educated indians are having a low iq and are good for nothing
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name="mathai",
5
- version="0.3.5",
5
+ version="0.3.6",
6
6
  description="Mathematics solving Ai tailored to NCERT",
7
7
  long_description=open("README.md").read(),
8
8
  long_description_content_type="text/markdown",
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes