In this paper, the theory behind the isotropic-nematic phase transition is discussed. Furthermore, an algorithm is given to calculate some properties of this phase transition. I have written a program in C which gives me the free energy, pressure, chemical potential and nematic order parameter for a given concentration $c$ of the particles in the system. Now I want to find the concentrations $c_I$ and $c_N$, which define the interval where the system phase separates, i.e., it is partly nematic and partly isotropic in order to lower its free energy.As the article explains, one needs to solve the system of equations$$p_{\text{iso}}(c_I) = p(c_N) \\\mu_{\text{iso}}(c_I) = \mu(c_N),$$for $c_{I,N}$. The expressions $p_{\text{iso}}$ and $\mu_{\text{iso}}$ are analytically known and I can calculate $p$ and $\mu$ for certain discrete values of of the concentration. My question is: how to solve these two equations in C? I know that one can use Newton-Rhapson to solve zeros of a function numerically. However, as I only know the functions $p$ and $\mu$ for certain values of $c$, I do not really know how to tackle this problem. Can someone help me find a way to do this? (Preferably an algorithm of some sorts.) Disclaimer: I am starting to learn C, but I am not extremely good at it.
Calculation of isotropic-nematic phase transition
c;newton method