Solve equtaion with sinh en coth in matlab

  • Context: MATLAB 
  • Thread starter Thread starter mrcannibal
  • Start date Start date
  • Tags Tags
    Matlab
Click For Summary
SUMMARY

The discussion centers on solving a mathematical equation involving hyperbolic functions in MATLAB. The user encountered an error related to argument types while attempting to compute a solution using the 'sinh' function. A solution was provided, which involved declaring the variables 'Bi' and 't' as symbolic variables using the 'syms' command. This adjustment resolved the error, allowing for the successful computation of the variable 'C' based on the derived equations.

PREREQUISITES
  • Familiarity with MATLAB symbolic toolbox
  • Understanding of hyperbolic functions, specifically 'sinh' and 'coth'
  • Basic knowledge of solving equations in MATLAB
  • Concept of symbolic variables in MATLAB
NEXT STEPS
  • Explore MATLAB symbolic toolbox documentation for advanced usage
  • Learn about hyperbolic function properties and their applications
  • Research error handling in MATLAB for symbolic computations
  • Investigate numerical methods for solving equations in MATLAB
USEFUL FOR

Mathematicians, engineers, and students working with MATLAB who need to solve equations involving hyperbolic functions and symbolic variables.

mrcannibal
Messages
1
Reaction score
0
Hi, I need the numerical solution of C. But i get an Error: argument must be of 'Type::Arithmetical' [sinh]! Can you help me the code please,I would be of great help!
Thanks

syms x

Bi = 0.43;

t = -16.9;

N = x/(2*Bi)+ t/2;

y = 2*(1-coth(x))*(cosh(x)-cosh(N))+x/((2*Bi)*exp(-N))+(1-coth(x)/(2*Bi))*x*sinh(x);

P = solve(y);

M = P/(2*Bi)+t/2;

C = (P^2/sinh(P)^2)*exp(-M)*(cosh(P)-cosh(M));
 
Physics news on Phys.org
Hi, declare Bi and t also as syms variables, it worked for me
 

Similar threads

  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 2 ·
Replies
2
Views
4K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 6 ·
Replies
6
Views
4K
Replies
5
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
Replies
2
Views
1K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K