Skip to content

Instantly share code, notes, and snippets.

View arihantparsoya's full-sized avatar

Arihant Parsoya arihantparsoya

View GitHub Profile
from sympy import *
from math import sqrt
A, L, I, E = symbols('A L I E')
total_members = 3
k = []
a = []
T = []
K = zeros(2)
from matchpy import *
a, b, c, d, m, n, p = map(Symbol, 'abcdmnp')
var = Symbol('var')
one = Symbol('1') # One
zero = Symbol('0') # Zero
Mul = Operation.new('*', Arity.variadic, 'Mul', associative=True, one_identity=True, infix=True)
Plus = Operation.new('+', Arity.variadic, 'Plus', associative=True, one_identity=True, infix=True)
Div = Operation.new('/', Arity.variadic, 'Div', associative=False, infix=True)
@arihantparsoya
arihantparsoya / test_rubi_integrator.py
Last active March 4, 2017 12:06
Implementation of Algebric (Linear Products) Integrands
from sympy import *
'''
Rubi integrator for:
1 Algebric:
1.1 Linear Products:
1.1.1 (a + b*x)**m
1.1.2 (a + b*x)**m * (c + d*x)**n