facebookresearch / SymbolicMathematics

Deep Learning for Symbolic Mathematics
Other
523 stars 114 forks source link

Symbolic solving #21

Closed arthurserres closed 3 years ago

arthurserres commented 3 years ago

Hi everyone !

I played a bit with the solver but there is something I tried but didn't succeed: Of course we can solve simple ODEs like f'+12=0 but can we solve f'+c=0 for c a fixed arbitrary real constant ? And in the latter case how to do so ?

Many thanks by advance for those of you that will spent some time on my question :)

f-charton commented 3 years ago

Coefficients will do this for you : you need to solve f' + a0 = 0. However, this will probably not work if you use the models and dataset we provide, which have not been trained with coefficients. As mentioned in my comment in issue #20, you have two strategies : 1- generate a new dataset with coefficients, and train a new model 2- start from a trained model, and try training it on a smaller set of examples that include coefficients.

1 will most certainly work, but you are going to need a lot of computing for the data generation (which tend to be slow because of Sympy). 2 is not guaranteed, but it is worth a try, since we know that transformers can be good few shot learners (cf GPT-3)

arthurserres commented 3 years ago

Thanks again for answering.

Yes I didn't realised that you model wasn't trained with coefficient so of course it will probably fail to predict this kind of ODEs.

Thanks for the two proposed solutions I will probably try them.

Best and thanks again for you work this is really interesting :)