0
$\begingroup$

I need to solve this function, but I cannot copy mathematical function, so I display in picture, sorry enter image description here

u=(y0-μ)/(σ+r);
v=(y0-μ)/(σ-r);
a=PDF[NormalDistribution[μ,σ],u];
b=PDF[NormalDistribution[μ,σ],v];
q=CDF[NormalDistribution[μ,σ],u]-CDF[NormalDistribution[μ,σ],v];
μt=μ+σ/q(b-a);
σt=σ^2(1+1/q(v*b-u*a)-1/q^2(b-a)^2);
L=k((μt-y0)^2+σt^2);
Cpm=r*σ/(3 Sqrt[σ^2+(μ-y0)^2]);
TC=L+(1-q)SC+IC+Exp[1-Abs[1-μ/y0]]MC+(Exp[(σ1-σ)/(σ1-σ2)]-1)DC;
g=4/3<=Cpm<=5/3;
h=D[TC,{σ,μ}];
Solve[h==0,g,{σ,μ}]
$\endgroup$
  • 1
    $\begingroup$ You certainly can copy and paste code rather than post images and you should do so. Copy the code as Input Text, an option that is available from the Edit > Copy As submenu. $\endgroup$ – m_goldberg Apr 15 at 3:11
  • $\begingroup$ oke I'll try, thankyou $\endgroup$ – Maghfira Apr 15 at 4:31
  • $\begingroup$ D[TC,{σ,μ}] in the help pages shows you want mu to be the degree of differentiation. I doubt that is what you want. I imagine you want D[TC,σ,μ] to differentiate first by sigma and then by mu. Solve is usually for polynomials. Reduce[{h==0,g},{σ,μ}] might be better. But there are still problems trying to make this a simple enough problem to find solutions. Please check this carefully to make certain there are no errors. $\endgroup$ – Bill Apr 15 at 6:17
1
$\begingroup$

It's easier to differentiate if you define TC with RealAbs instead of Abs:

TC = L + (1-q) SC + IC + Exp[1-RealAbs[1-μ/y0]] MC + (Exp[(σ1-σ)/(σ1-σ2)]-1) DC;

Then, if you want to set both of the derivatives with respect to $\sigma$ and $\mu$ to zero, try

h = D[TC, {{σ, μ}}];
Solve[Thread[h == 0], {σ, μ}]

It's taking a long time to generate results though.

$\endgroup$
  • $\begingroup$ What if I need to solve based on differentiating sigma, mu and Cpm? @Roman $\endgroup$ – Maghfira Apr 18 at 4:28
  • $\begingroup$ Solve[Thread[D[TC, {{σ, μ, Cpm}}]; == 0], {σ, μ, Cpm}] $\endgroup$ – Roman Apr 18 at 6:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.