Matlab Problem: Solving a code for four unknowns

A little bit long Matlab code that I just developed to solve for four unknowns. There are three files. One with the name "water-CO2 coexistence _curve1.m" which contains the main code equations. The other one which is "literature_H2O-CO2.m" contains the initial 4 guesses and also the fsolve function. The third one is a "findDifference_H2O_CO2.m" which is to show the 4 equality equations that needs to be satisfied in order to solve for the four unknowns. The specified variables are T and P. On the other hand the unknowns are: 2 different rau and 2 different [url removed, login to view] four equations are as follows:

1) P_res = P (vapor phase as function of T and x_c at the vapor phase; P is specified)

2) P_res = P (liquid phase as function of T and x_c at the liquid phase; P is specified)

3) chempt_w (vapor phase) = chempt_w (liquid phase) (function of T and x_c at liquid and vapor phase)

4)chempt_c (vapor phase) = chempt_c (liquid phase) (function of T and x_c at liquid and vapor phase)

Initial guess: raul (rau at liquid phase), rauv (rau at vapor phase), x_c (x_c at liquid phase), y_c (x_c at vapor phase).

I know that it will be confusing just reading the above paragraph. But, please have a look at the code and then we can discuss things out to make it clearer. The code is ALREADY DONE, however, I am facing errors while solving, probably because I have some small programming mistakes here and there.

Ready for giving out a good award for submitting good quality work.

Thanks.

Compétences : Génie Chimique, Ingénierie, Matlab and Mathematica

Concernant l'employeur :
( 8 commentaires ) Houston, United States

N° du projet : #1675184

Décerné à :

stephensmith0682

Ok. Had a look at it. Let us discuss. On Gtalk or Skype.

250 \$ USD en 1 jour
(1 Commentaire)
2.8

5 freelance ont fait une offre moyenne de 544 \$ pour ce travail

MikroStar

hi, i can help.

720 \$ USD en 30 jours
(38 Commentaires)
6.4
zoltannagy

Hi. phd in engineering with extensive matlab and optimization experience. let's talk.

750 \$ USD en 7 jours
(4 Commentaires)
4.5
deepak19041991