In mathematics, an integrating factor is a function that is chosen to facilitate the solving of a given equation involving differentials. It is commonly used to solve ordinary differential equations, but is also used within multivariable calculus when multiplying through by an integrating factor allows an inexact differential to be made into an exact differential (which can then be integrated to give a scalar field). This is especially useful in thermodynamics where temperature becomes the integrating factor that makes entropy an exact differential. Use An integrating factor is any expression that a differential equation is multiplied by to facilitate integration. For example, the nonlinear second order equation admits as an integrating factor: To integrate, note that both sides of the equation may be expressed as derivatives by going backwards with the chain rule: Therefore, where is a constant. This form may be more useful, depending on application. Performing a separation of variables will give This is an implicit solution which involves a nonelementary integral. This same method is used to solve the period of a simple pendulum. Solving first order linear ordinary differential equations Integrating factors are useful for solving ordinary differential equations that can be expressed in the form The basic idea is to find some function, say , called the "integrating factor", which we can multiply through our differential equation in order to bring the left-hand side under a common derivative. For the canonical first-order linear differential equation shown above, the integrating factor is . Note that it is not necessary to include the arbitrary constant in the integral, or absolute values in case the integral of involves a logarithm. Firstly, we only need one integrating factor to solve the equation, not all possible ones; secondly, such constants and absolute values will cancel out even if included. For absolute values, this can be seen by writing , where refers to the sign function, which will be constant on an interval if is continuous. As is undefined when , and a logarithm in the antiderivative only appears when the original function involved a logarithm or a reciprocal (neither of which are defined for 0), such an interval will be the interval of validity of our solution. To derive this, let be the integrating factor of a first order linear differential equation such that multiplication by transforms a partial derivative into a total derivative, then: Going from step 2 to