benruijl / symbolica Goto Github PK
View Code? Open in Web Editor NEWA modern computer algebra library for Python and Rust.
Home Page: https://symbolica.io
License: Other
A modern computer algebra library for Python and Rust.
Home Page: https://symbolica.io
License: Other
Hello,
I tried running the program below,
from symbolica import Expression
e = Expression.num(0)
print(e)
print(e.factor())
and it produced
0
1
I'm wondering if that's expected. Thanks!
Sorry i couldn't find any "comment" feature on your blog so i decided to write here.
Your 'loop' pattern can be written like this:
let mut items = vec![3, 5, 7, 11, 13, 17];
let item = 19;
let location = items.iter().position(|x| *x == item).or_else(|| {
items.push(item);
Some(items.len() - 1)
});
To reproduce:
>>> x, y = Expression.vars('x', 'y')
>>> e = 5*x + x * y + x**2 + 5
>>> print(e.coefficient(x*y))
0
But of course it should be 1.
With the current version (0.8.0) of symbolica that includes the float representations I see that rational factors in python are sometimes converted to floats. This example demonstrates where depending on how I write the expression it either is represented as a float or a rational number:
e = Expression.symbol("e")
e1 = 2/5 * e
e2 = 2 * e / 5
print(e1) # gives: 4.00000000000000e-1*e
print(e2) # gives: 2/5*e
This page just isn't very useful, removing it should be as simple as removing the pub
keyword in front of the module name.
Since Symbolica is advertised as a blazing fast language, are there any benchmark comparisons to Form?
Imagined use: Suppose we have an ODE and we wish to solve it with the Frobenius method. The we would like to convert the ansatz
to some recurrence involving only the
c = Expression.var('c[0:infinity]')
or
c = Expression.vector_var('c[0:infinity]')
I submit this issue with some trepidation as I know absolutely nothing about this field and have no clue if I've made a feature request for something that's NP complete or undecidable.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.