0
$\begingroup$
qmax[Dia_, Wt_, leff_, Rs_, Ks_, theta_, phi_, T_] := ((((((999.8995 + (16.9451*T) - ((7.987040*10^-3)*
           T^2) - ((46.170461*10^-6)*T^3) + ((105.56302*10^-9)*
           T^4) - ((280.54253*10^-12)*
           T^5))/(1 + (16.897850*10^-3)*T))*
     Ks*(3.14*Dia*
       Wt*10^-6))/(((0.02939*Exp[507.88/((T + 273) - 149.3)])/
       1000)*leff))*(((2*
       Cos[theta/
         57.2958]*((1 - 
           0.625*((647.15 - (T + 273))/
              647.15))*(235.8*10^-3)*(((647.15 - (T + 273))/
             647.15)^1.256))*10^3)/
     Rs) - ((999.8995 + (16.9451*T) - ((7.987040*10^-3)*
          T^2) - ((46.170461*10^-6)*T^3) + ((105.56302*10^-9)*
          T^4) - ((280.54253*10^-12)*T^5))/(1 + (16.897850*10^-3)*
         T))*9.81*leff*
    Sin[phi/57.2958]))*(2.5*10^6 - (2.386*10^3)*((T + 273) - 273)))  effl[Lp_, Lc_, Le_] := ((((Lc + Le)/2) + (Lp - Le - Lc))) Manipulate["Effective Length of Heat Pipe (mm):" <> 
ToString@Style[effl[Lp, Lc, Le], 14]Plot[ qmax[Dia, Wt, Leff, Rs, Ks, theta, phi, T], {Leff, 0, 0.5},
FrameTicks -> {Automatic, {{#, 1000 #} & /@ 
     FindDivisions[{0, 1}, 10] // N, Automatic}},
PlotLabel -> 
 Style["Maximum Heat Transfer Vs Effective Length", 
  FontSize -> 10, Bold, Black, 12],
PlotRange -> {0, 250},
PlotStyle -> {Thickness[0.01], Lighter[ Blue, 0.5]},
GridLines -> Automatic,
Frame -> True,
FrameStyle -> Directive[Black, 12],
FrameLabel -> {Row[{Style["Effective Length of HP (mm)", Italic, 
     Bold, 11]}], 
  Row[{Style["Maximum Heat Transfer (W)", Italic, Bold, 11]}]},
PerformanceGoal -> "Quality",
ImageSize -> 400,
Background -> LightGreen,
GridLinesStyle -> {Directive[Dashed, Blue], 
  Directive[Dashed, Red]}],Delimiter,Style["Dimensions of heat pipe", Italic, Bold, Blue, 13],{{Lp, 300, "Length of HP (mm) : "}, ControlType -> InputField,FieldSize -> 3}, {{Le, 150, "Length of Evaporator Section (mm) : "},ControlType -> InputField, FieldSize -> 3},{{Lc, 150, "Length of Condenser Section (mm) : "},ControlType -> InputField, FieldSize -> 3},{{Dia, 10 , "Tube Inner Diameter (mm) :"}, ControlType -> InputField,FieldSize -> 3},Delimiter,Style["Operating Temperature", Italic, Bold, Blue, 13],{{T, 100, "T (\[Degree]C): "}, ControlType -> InputField,FieldSize -> 3},Delimiter,Style["Wick Thickness", Italic, Bold, Blue, 13],{{Wt, 0.18, "Wt (mm) : "}, ControlType -> InputField, FieldSize -> 3},Delimiter,Style["Radius of the pore", Italic, Bold, Blue, 13],{{Rs, 0.02, "Rs (mm) : "}, ControlType -> InputField, FieldSize -> 3},Delimiter,Style["Permeability of Wick", Italic, Bold, Blue, 13],{{Ks, 0.302*10^-10, "Ks (m^2) : "}, ControlType -> InputField,FieldSize -> 6},Delimiter,Style["Weting angle", Italic, Bold, Blue, 13],{{theta, 0, "Angle in Degrees : "}, ControlType -> InputField,FieldSize -> 3},Delimiter,Style["Inclination angle", Italic, Bold, Blue, 13],{{phi, 30, "Angle in Degrees : "}, ControlType -> InputField, FieldSize -> 3},Delimiter,Item[Button["Display Graph", Nothing, BaseStyle -> {14},Background -> Lighter[Gray, 0.5]]],LabelStyle -> {15},ContentSize -> 850,TrackedSymbols :> All,ControlPlacement -> Left,Frame -> True]

I am trying to build a dashboard for my group so that they can use that effectively for their analysis. But I want to do one change which I am not able to do. I need your help folks. I am displaying the value of "Effective Length of Heat Pipe (mm)" above the plot but I want to place it below the "Display Graph" button.

How I can move that string below the left-hand side. I don't want o display it above the plot. Please help me with this small change in my code.

Thanks in advance.

$\endgroup$

1 Answer 1

3
$\begingroup$

Try this:

Manipulate[
 Column[{"Effective Length of Heat Pipe (mm):" <> 
    ToString@Style[effl[Lp, Lc, Le], 14], 
   Plot[qmax[Dia, Wt, Leff, Rs, Ks, theta, phi, T], {Leff, 0, 0.5}, 
    FrameTicks -> {Automatic, {{#, 1000 #} & /@ 
         FindDivisions[{0, 1}, 10] // N, Automatic}}, 
    PlotLabel -> 
     Style["Maximum Heat Transfer Vs Effective Length", 
      FontSize -> 10, Bold, Black, 12], PlotRange -> {0, 250}, 
    PlotStyle -> {Thickness[0.01], Lighter[Blue, 0.5]}, 
    GridLines -> Automatic, Frame -> True, 
    FrameStyle -> Directive[Black, 12], 
    FrameLabel -> {Row[{Style["Effective Length of HP (mm)", Italic, 
         Bold, 11]}], 
      Row[{Style["Maximum Heat Transfer (W)", Italic, Bold, 11]}]}, 
    PerformanceGoal -> "Quality", ImageSize -> 400, 
    Background -> LightGreen, 
    GridLinesStyle -> {Directive[Dashed, Blue], 
      Directive[Dashed, Red]}]
   }, Alignment -> Center], Delimiter, 
 Style["Dimensions of heat pipe", Italic, Bold, Blue, 
  13], {{Lp, 300, "Length of HP (mm) : "}, ControlType -> InputField, 
  FieldSize -> 3}, {{Le, 150, "Length of Evaporator Section (mm) : "},
   ControlType -> InputField, 
  FieldSize -> 3}, {{Lc, 150, "Length of Condenser Section (mm) : "}, 
  ControlType -> InputField, 
  FieldSize -> 3}, {{Dia, 10, "Tube Inner Diameter (mm) :"}, 
  ControlType -> InputField, FieldSize -> 3}, Delimiter, 
 Style["Operating Temperature", Italic, Bold, Blue, 
  13], {{T, 100, "T (\[Degree]C): "}, ControlType -> InputField, 
  FieldSize -> 3}, Delimiter, 
 Style["Wick Thickness", Italic, Bold, Blue, 
  13], {{Wt, 0.18, "Wt (mm) : "}, ControlType -> InputField, 
  FieldSize -> 3}, Delimiter, 
 Style["Radius of the pore", Italic, Bold, Blue, 
  13], {{Rs, 0.02, "Rs (mm) : "}, ControlType -> InputField, 
  FieldSize -> 3}, Delimiter, 
 Style["Permeability of Wick", Italic, Bold, Blue, 
  13], {{Ks, 0.302*10^-10, "Ks (m^2) : "}, ControlType -> InputField, 
  FieldSize -> 6}, Delimiter, 
 Style["Weting angle", Italic, Bold, Blue, 
  13], {{theta, 0, "Angle in Degrees : "}, ControlType -> InputField, 
  FieldSize -> 3}, Delimiter, 
 Style["Inclination angle", Italic, Bold, Blue, 
  13], {{phi, 30, "Angle in Degrees : "}, ControlType -> InputField, 
  FieldSize -> 3}, Delimiter, 
 Item[Button["Display Graph", Nothing, BaseStyle -> {14}, 
   Background -> Lighter[Gray, 0.5]]], LabelStyle -> {15}, 
 ContentSize -> 850, TrackedSymbols :> All, ControlPlacement -> Left, 
 Frame -> True]

enter image description here

Have fun!

$\endgroup$
5
  • $\begingroup$ Thanks, @Alexei... I already did that but I want to display the string not on top of the graph but below the Display graph Button... $\endgroup$
    – ASHISH
    Commented Dec 10, 2021 at 4:20
  • $\begingroup$ Or is it possible to put these strings separately from Plot? $\endgroup$
    – ASHISH
    Commented Dec 10, 2021 at 7:17
  • $\begingroup$ I do not understand your question. Where precisely do you want to put it? $\endgroup$ Commented Dec 10, 2021 at 9:18
  • $\begingroup$ Ah, OK, I understand, what you have in mind. It is a bit difficult because the part of the code defining the button "Display graph" is outside of the body of the Manipulate statement. For this reason, you can put some static text above or below the button (using the same function Column) but the dynamic part of the text will not work. There is a workaround. It consists in making a nested Manipulate statement. That is, one Manipulate inside the other. You need then to include the button "Display graph" into the inner Manipulate and wrap it by the Column statement with your text. $\endgroup$ Commented Dec 10, 2021 at 9:31
  • $\begingroup$ Continuation: All the other controls you can then include into the outer Manipulate statement. However, this will make your demonstration "heavy," and I would not recommend it. $\endgroup$ Commented Dec 10, 2021 at 9:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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