Simplify symbolic expressions with custom constraints

5 visualizzazioni (ultimi 30 giorni)
Is it possible to algebraically simplify a symbolic expression based on a custom assumption on the symbolic variables?
Let's take a simple example. Suppose we have:
syms x y
u = x^3 + x * y^2 + y ;
Let's say we want to add the following assumption on the symbolic variables:
x^2 + y^2 = 1
Upon which, u would simplify to
u = x + y
Is something like this possible?
I stumbled upon the following related pages, but none seemed to enable adding a custom expression for the simplification

Risposte (1)

Walter Roberson
Walter Roberson il 14 Lug 2019
No it is not possible.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by