How to Solve for T in the Wagner Equation using MatLAB

  • Thread starter Thread starter CrazyDiamond
  • Start date Start date
AI Thread Summary
The discussion focuses on solving for T in the Wagner Equation for vapor pressure, specifically when p is known. Users express difficulty in finding an analytical solution and suggest that approximate methods, such as the bisection method in Excel, could be used. VBA in Excel is mentioned as a potential solution, although it comes with warnings about script safety. Alternatives like downloading software such as Pari/GP are also recommended, but they require manual data entry into Excel. Overall, the consensus is that while direct solutions are challenging, various workaround methods exist for calculating T.
CrazyDiamond
Messages
5
Reaction score
0
I'm using the Wagner Equation for Vapour pressure at work.This equation is :

lnp=((-7.7069(1-T)) + (2.4932(1-T)^1.5158) -(2.9212(1-T)^1.9907) -(3.8684(1-T)^4.3798) + (0.46898(1-T)^1.7461) - (0.00008336))/x

[I haven't been able to find an online version of this equation]

Here, T and p are variables. Its obviously easy to find p if I know T, but now I need to find T given that p is known. This is getting very complicated, and I don't have access to MatLAB either.Could someone who has MatLAB please help me out - I simply need an equation for T in terms of p.

Online Equation solvers give me an answer for T if I feed in the equation, but they do not give me an equation for T, which is what I need so I can put it into an Excel Spreadsheet.

Thanks.
 
Mathematics news on Phys.org
Don't think there is an analytical solution for this equation.
 
I also don't think there is an analytical solution.

If you must, you can probably solve it approximately in Excel (without scripting!) with bisection. If you want 9 decimals of precision you'll need ~30 rows for the calculation.

You could solve it with VBA in Excel, though you'll get warnings about the script being potentially unsafe whenever you open it. (Kinda makes you wish Excel could tell when no file access was being done by the script...)

You could download any number of programs, like Pari/GP, that would make solving it simple. Of course then you'd have to enter the data into Excel manually.
 
I used linear regression in Excel..my boss is too stingy to give me access to VBA.
Thanks for the help guys !
 
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Fermat's Last Theorem has long been one of the most famous mathematical problems, and is now one of the most famous theorems. It simply states that the equation $$ a^n+b^n=c^n $$ has no solutions with positive integers if ##n>2.## It was named after Pierre de Fermat (1607-1665). The problem itself stems from the book Arithmetica by Diophantus of Alexandria. It gained popularity because Fermat noted in his copy "Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos, et...
Thread 'Imaginary Pythagorus'
I posted this in the Lame Math thread, but it's got me thinking. Is there any validity to this? Or is it really just a mathematical trick? Naively, I see that i2 + plus 12 does equal zero2. But does this have a meaning? I know one can treat the imaginary number line as just another axis like the reals, but does that mean this does represent a triangle in the complex plane with a hypotenuse of length zero? Ibix offered a rendering of the diagram using what I assume is matrix* notation...
Back
Top