use symsum for equation forming and solving
Mostra commenti meno recenti
I want to make a equation to slolve for variable Kd and write a code
l is index as s & c
p & and Tiijj are function of r where r is define as r_s and r_c
syms alpha s b c phi
Eq = a-b== (c-b)*(3*a+4*b)*symsum(phi_l*Tiijj(alpha_l),l,s,c) eq(1)
a = solve(Eq,a)
2 Commenti
Arvind
il 10 Mag 2023
Don't use "symsum" in the case of only two terms in the sum.
Just write something like
syms alpha T(alpha,a) phi(alpha) a b c d
alpha_s = 1;
alpha_c = 5;
phi(alpha) = alpha^2;
T(alpha,a) = alpha^4 + a^2;
eqn = a-b==1/3*(c-b)*(3*a+4*d)/(3*b+4*d)*(phi(alpha_s)*T(alpha_s,a)+phi(alpha_c)*T(alpha_c,a));
sol = solve(eqn,a,'MaxDegree',3)
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Mathematics in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
