solve() is unable to find a solution
Afficher commentaires plus anciens
Hello everyone,
I was trying to solve a transcendental eqation in MATLAB
I performed two programs one graphical approach and another by solve()
In the graphical approach, I find one solution exists in the range
∈ (
) for
, as shown in the figure below
∈ (
i.e., the intersection of blue and red curve (
)
Now, when i performed another program (T2.m) using solve() :
Command Prompt is giving empty sym with the following message:
Warning: 3 equations in 1 variables.
> In C:\Program Files\MATLAB\R2013a\toolbox\symbolic\symbolic\symengine.p>symengine at 56
In mupadengine.mupadengine>mupadengine.evalin at 97
In mupadengine.mupadengine>mupadengine.feval at 150
In solve at 170
In T2 at 16
Warning: Explicit solution could not be found.
> In solve at 179
In T2 at 16
k1_sol = [ empty sym ]
My T2.m is as follows:
clc
clear all
close all
one_eV= 1.6/(10^19);
Vo=0.3 * one_eV;
b=5/(10^9);
S=Vo*b;
a=10/(10^9);
m=0.067 * 9.1/(10^31);
h=6.626/(10^34);
hbar= h/(2*pi);
k=pi/(4*a);
lhs= cos(k*a);
syms k1
rhs=cos(k1*a) + (m*S)*sin(k1*a)/(hbar^2 * k1);
k1_sol= solve(lhs== rhs,k1 >= 0.27*(10^9), k1 <= 0.32*(10^9))
so, how to rectify this?
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Mathematics dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!