Posted By

bfrank on 04/09/11


Tagged

1010


Versions (?)

Simulator


 / Published in: MatLab
 

  1. % 10.10 Project
  2. % Spring 2011
  3. % Jackie Simpson and Ben Frank
  4. %==========================================================================
  5. % Simulation ||
  6. %==========================================================================
  7. function F = Simulator(X)
  8. %This function directs the sequential simulation of the processing units in
  9. %the process.
  10. %
  11. %INPUT: X--Vector of Optimization Variables
  12. % X(1) = ReactorHeater
  13. % X(2) = ReactionHeatingPeriod
  14. % X(3) = AmountSolvent
  15. %OUPUT: Global Variables
  16. global ReactorHeater ReactorHeatingPeriod AmountSolvent_S2
  17. %
  18. %OUPUT: F - the value of the net operating profit
  19. %
  20. ReactorHeater = X(1);
  21. ReactorHeatingPeriod = X(2);
  22. AmountSolvent_S2 = X(3);
  23. %
  24. disp('The simulator function has been visited'); %remove when filled in
  25. %::::::::::::::::::::::::::::::::::::::::::::
  26. % 2A1-Simulate Batch Reactor :
  27. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  28. Reactor;
  29. %::::::::::::::::::::::::::::::::::::::::::::
  30. % 2A2-Simulate Batch Extractor :
  31. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  32. Extractor;
  33. %::::::::::::::::::::::::::::::::::::::::::::
  34. % 2A3-Simulate Batch Distillation :
  35. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  36. Distillation
  37. %::::::::::::::::::::::::::::::::::::::::::::
  38. % 2A4-Simulate Batch Crystallizer :
  39. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  40. Crystallizer
  41. %::::::::::::::::::::::::::::::::::::::::::::
  42. % 2A5-Simulate Batch Dryer :
  43. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  44. Dryer
  45. %::::::::::::::::::::::::::::::::::::::::::::
  46. % 2A6-Simulate Waste treatment :
  47. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  48. Waste_Treatment
  49. %::::::::::::::::::::::::::::::::::::::::::::
  50. % 2A7-Compute Process Economics :
  51. %::::::::::::::::::::::::::::::::::::::::::::------------------------------
  52. F = Overall_Process_Economic_Objective(X);
  53. end

Report this snippet  

You need to login to post a comment.