How do you solve equations with multiple variables?

7 views (last 30 days)
I have a list of variables. Then, I have equations that I would like to solve with said variables. How would I go about this?
Appreciate the help,
Ilan
%List of Variables
E1f = 233
v12f = 0.200
E2f = 23.1
G12f = 8.96
a1f = -0.540*10^-6
a2f = 10.10*10^-6
Em = 4.62
am = 41.4 * 10^-6
vm = 0.360
Vf = 0.2
%Equations I would like to solve with the above variables
E1c = [E1f * v12f + Em(1 - v12f)]
v12c = v12f * Vf + vm(1 - Vf)
E2c = [(1 - sqrt(Vf)) / (Em)] + [(sqrt(Vf)) / (E2f * sqrt(Vf) + (1 - sqrt(Vf)) * Em)]
%G12c = Gm * [((Gm + G12f) - Vf*(Gm - G12f)) / ((Gm + G12f) + Vf * (Gm - G12f))]
%a1c = [E1f * a1f * Vf + Em * am(1 - Vf)] / [E1f * Vf + E1m(1 - Vf)]
a2c = [a2f - (Em / E1c) * v12f * (am - a1f) * (1 - Vf)] * Vf + [am + (E1f / E1c) * vm * (am - a1f) * Vf] * (1 - Vf)

Accepted Answer

Sam Chak
Sam Chak on 19 Sep 2023
Hi @Ilan, some multiplication operators (*) are missing. It is working now.
% List of Parameters
E1f = 233;
v12f = 0.200;
E2f = 23.1;
G12f = 8.96;
a1f = -0.540e-6;
a2f = 10.10e-6;
Em = 4.62;
am = 41.4e-6;
vm = 0.360;
Vf = 0.2;
% Equations I would like to 'obtain' with the above 'parameters'
E1c = E1f*v12f + Em*(1 - v12f)
E1c = 50.2960
v12c = v12f*Vf + vm*(1 - Vf)
v12c = 0.3280
E2c = (1 - sqrt(Vf))/Em + sqrt(Vf)/(E2f*sqrt(Vf) + (1 - sqrt(Vf))*Em)
E2c = 0.1544
a2c = (a2f - (Em/E1c)*v12f*(am - a1f)*(1 - Vf))*Vf + (am + (E1f/E1c)*vm*(am - a1f)*Vf)*(1 - Vf)
a2c = 4.6208e-05

More Answers (0)

Categories

Find more on Symbolic Math Toolbox in Help Center and File Exchange

Products


Release

R2023a

Community Treasure Hunt

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

Start Hunting!