Questions tagged [symbolic-math]

Symbolic math tools allows for analytically process mathematical expressions - without the necessity of assigning specific numeric values to variables.

Filter by
Sorted by
Tagged with
8
votes
5answers
727 views

Expanding powers of expressions of the form ax+b

I solved the following problem: Write a function expand that takes in an expresion with a single, one character variable, and expands it. The expresion is in the form ...
10
votes
2answers
135 views

Synthetic division calculator

I've written a python program do perform synthetic division on a polynomial. There are a few constraints (listed in the module docstring of the program) on the polynomial, mainly because I haven't had ...
4
votes
1answer
56 views

Evaluator for adding and subtracting algebraic expressions

I wrote a little program that adds and subtracts some algebraic expressions. In my code (2 x 3) represents \$2x^3\$. The purpose of this post is to get some ...
2
votes
0answers
44 views

quaternion renormalization

Edit 1: changed a few portions of the code to hopefully make it runnable code and more understandable. If something is still incorrect please let me know. Edit 2: just remembered I am doing this in ...
3
votes
1answer
75 views

Polynomial implementation in Golang

I am writing a numerical analysis library in golang for which I need to implement a polynomial struct. Here is the source code: ...
1
vote
1answer
168 views

Expression tree in Haskell with support for differentiation

A simple binary expression tree in Haskell without operator precedence and without parentheses. Any comments would be much appreciated. ...
0
votes
1answer
71 views

Building an equation [closed]

I've developed a function in the Julia language, using the SymEngine library, which builds an equation. This function works quite quickly, returning a lambdified ...
3
votes
1answer
76 views

Replace a^b by Pow(a,b)

The application uses NCalc to execute diverse calculations. The 'natural' way to write powers using a computer is using the ^ symbol. However, NCalc already uses ...
2
votes
0answers
41 views

Simplify radicands

I am attempting to create a program that can, given an integer as input, simplify the radicand by removing all square factors. For use on my TI 84+ CE Code: for clarity reasons I've indented ...
3
votes
1answer
188 views

Symbolic derivative in Swift

I just wrote my first Swift program! It is a little computer algebra test that computes the nth derivative of the symbolic expression \$x^x\$. I chose this example because I'm keen to see how ARC will ...
8
votes
1answer
2k views

Library, that finds the derivative of a function

I've written a small library, that provides a way to store mathematical expressions in a tree-like structure, and provides a method, that finds the first derivative of a function. I know, that there ...
6
votes
2answers
1k views

Math app/library that solves calculus problems (symbolic derivative, etc)

Let me start off by saying that this project is a mess, and I know it. I believe it is a mess because I threw it together in a few days just to get it working. Unfortunately, my undergraduate ...
8
votes
2answers
532 views

Solve simple derivative questions

Built my first script and its function is to solve simple derivative questions. How can I improve this code? This is my first time posting. ...
7
votes
3answers
4k views

Algorithm to compute the n-th derivative of a polynomial in Python

As a personal exercise, I'm trying to write an algorithm to compute the n-th derivative of an ordered, simplified polynomial (i.e., all like terms have been combined). The polynomial is passed as an ...
2
votes
1answer
871 views

Parsing a string containing arithmetic operations in prefix notation

This is a piece from the complete program. What it does is parses mathematical expressions of the form (+(*3,x),5) to 3*x + 5 ...
2
votes
0answers
47 views

Symbolic Math/Computer Algebra System redundant code problems

I am programming this Computer Algebra System, it works fine, but I'm running into some problems where I'm writing a lot of redundant code, I'd like some advice on that. The most problems I'm having ...
3
votes
1answer
198 views

Computer Algebra System implementation

I have got it working in a way so that there is one superclass, MathObject. In this implementation there is only a Constant ...
4
votes
1answer
2k views

Boolean expressions from infix to postfix notation using Dijkstra's Shunting Yard algorithm

I began working on a Java library that receives a boolean expression such as not A and (B or not C), compiles it to a circuit of logical gates \$\mathcal{C}\$, ...
8
votes
1answer
4k views

Equation parser and solver

I wrote this equation parser and solver, I feel like it is well documented and tested: ...
2
votes
1answer
59 views

Differentiate simple expressions

This is the first program I have written in Rust and I would like to know what some Rust experts think of it. I must be doing some stuff wrong, such as breaking code style, etc. The code ...
8
votes
3answers
5k views

String representation of a polynomial

We all know that math notation is idiosyncratic. Canonical representation of math objects often have irregular grammar rules to improve readability. For example we write a polynomial \$3x^3 + x^2\$ ...
11
votes
1answer
4k views

Factoring quadratic equation

I have a program I am writing that calculates Algebra 2 functions and equations. The interface is all CLI, and I even made commands that are similar to shell commands. That's not the part I want ...
1
vote
1answer
138 views

Extending basic differentiator to handle more kinds of expressions

Exercise 2.56. Show how to extend the basic differentiator to handle more kinds of expressions. For instance, implement the differentiation rule $$ \frac{d(u^n)}{dr} = nu^{n-1}(\frac{...