diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.hpp new file mode 100644 index 0000000..da21db4 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.hpp @@ -0,0 +1,157 @@ +#ifndef ACTIVITYDIAGRAMACTION_HPP_INCLUDED +#define ACTIVITYDIAGRAMACTION_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramAction.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 17 Oct 2019 16:57:08 +//! @brief State +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramAction.nb*/ + +using namespace hopsan; + +class ActivityDiagramAction : public ComponentC +{ +private: + Port *mpPpn1; + Port *mpPpn2; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; +//==This code has been autogenerated using Compgen== + //inputVariables + //outputVariables + double state; + //InitialExpressions variables + double stated; + //Expressions variables + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + //inputParameters pointers + //outputVariables pointers + double *mpstate; + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramAction(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + //Add inputVariables to the component + + //Add inputParammeters to the component + //Add outputVariables to the component + addOutputVariable("state","State","",0.,&mpstate); + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //Read outputVariables from nodes + state = (*mpstate); + +//==This code has been autogenerated using Compgen== + //InitialExpressions + stated = state; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + qpn1 = (*mpP_qpn1); + //Port Ppn2 + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //LocalExpressions + + //Expressions + state = onPositive(-0.5 + qpn1 + qpn2 + stated); + spn1 = state; + spn2 = state; + stated = state; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_spn1)=spn1; + //Port Ppn2 + (*mpP_spn2)=spn2; + //outputVariables + (*mpstate)=state; + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMACTION_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.nb new file mode 100644 index 0000000..3884657 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.nb @@ -0,0 +1,850 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 45119, 842] +NotebookOptionsPosition[ 40523, 772] +NotebookOutlinePosition[ 40943, 788] +CellTagsIndexPosition[ 40900, 785] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel-> + "In[239]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.7747982976294117`*^9, + 3.774798305629897*^9}}, + CellLabel-> + "In[241]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955819626927`*^9, + 3.7748612729167113`*^9, 3.7748618498089046`*^9, {3.7748626953736324`*^9, + 3.7748627162538195`*^9}, {3.7748627484957123`*^9, 3.7748627655511484`*^9}, + 3.774862936436874*^9, 3.774863011346696*^9, 3.7748636510949306`*^9, + 3.7748637479339495`*^9, 3.7748646800967164`*^9, 3.774870146916913*^9, + 3.77487028499047*^9, 3.7748706042923727`*^9, 3.7748707175821958`*^9, + 3.7748708483282356`*^9, 3.774870980786578*^9, 3.774986571677526*^9, + 3.7803129134806423`*^9, 3.780312972657365*^9}, + CellLabel-> + "Out[241]=",ExpressionUUID->"42a8cded-7c2b-4e1b-bdbc-efc3e7dede99"] +}, Open ]], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input",ExpressionUUID->\ +"a5795f19-20e6-4fe4-996e-0c4224394789"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel-> + "In[242]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["Action", "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.76326139564559*^9, 3.763261396833707*^9}, { + 3.774856518932431*^9, 3.774856520029351*^9}, 3.774861262095235*^9, + 3.7748618470267663`*^9},ExpressionUUID->"3d597773-8bb1-48e6-9d32-\ +6c53852bc4f2"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137112151875*^9, 3.513711217109375*^9}, { + 3.51378596903125*^9, 3.513785980671875*^9}, {3.513786401703125*^9, + 3.51378641190625*^9}, 3.5153945400188417`*^9, {3.5719276782001615`*^9, + 3.5719276783561616`*^9}, 3.5757729448720746`*^9, 3.57577312705343*^9, + 3.605856906503504*^9, {3.763261401039956*^9, 3.7632614245461197`*^9}, + 3.763261486937274*^9, 3.7635554640323896`*^9, {3.77485650920687*^9, + 3.774856514950308*^9}, 3.7748612639428415`*^9, 3.7748618470267663`*^9, { + 3.7748863536595154`*^9, 3.7748864180854287`*^9}}, + CellLabel-> + "In[243]:=",ExpressionUUID->"30323ed5-d8c2-4713-8616-0c957d426752"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7635554294001036`*^9, 3.763555472659489*^9}, + 3.763555509393605*^9, 3.7748612729476795`*^9, {3.7748618470277653`*^9, + 3.774861849850853*^9}, {3.7748626955005016`*^9, 3.7748627163886805`*^9}, { + 3.774862748627576*^9, 3.7748627656810155`*^9}, 3.774862936566741*^9, + 3.7748630115315046`*^9, 3.77486365125976*^9, 3.7748637480708084`*^9, + 3.7748646802495584`*^9, 3.7748701470797434`*^9, 3.7748702851493063`*^9, + 3.77487060445021*^9, 3.774870717740034*^9, 3.774870848499059*^9, + 3.7748709809564033`*^9, 3.774986571863336*^9, 3.780312913634784*^9, + 3.7803129728554816`*^9}, + CellLabel-> + "Out[248]=",ExpressionUUID->"9fe442b1-8ad3-40e3-9c43-a1c1203f67ba"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "10", ",", "17", ",", "16", ",", "56", ",", + "12.7882775`8.859387008130836"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7635554294001036`*^9, 3.763555472659489*^9}, + 3.763555509393605*^9, 3.7748612729476795`*^9, {3.7748618470277653`*^9, + 3.774861849850853*^9}, {3.7748626955005016`*^9, 3.7748627163886805`*^9}, { + 3.774862748627576*^9, 3.7748627656810155`*^9}, 3.774862936566741*^9, + 3.7748630115315046`*^9, 3.77486365125976*^9, 3.7748637480708084`*^9, + 3.7748646802495584`*^9, 3.7748701470797434`*^9, 3.7748702851493063`*^9, + 3.77487060445021*^9, 3.774870717740034*^9, 3.774870848499059*^9, + 3.7748709809564033`*^9, 3.774986571863336*^9, 3.780312913634784*^9, + 3.780312972864458*^9}, + CellLabel-> + "Out[252]=",ExpressionUUID->"d54d8937-7727-4ae6-ae3d-78f3b4deefa5"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7748626773957825`*^9, 3.774862685600051*^9}}, + CellLabel-> + "In[253]:=",ExpressionUUID->"08535e74-7b0d-4a21-951d-5a86f4b367f3"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, + 3.7748563175374947`*^9, {3.7748564011997128`*^9, 3.7748564081021047`*^9}}, + CellLabel-> + "In[254]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774971588116584*^9, 3.774971621458659*^9}, + 3.7749719205128927`*^9, 3.7803127433380165`*^9}, + CellLabel-> + "In[255]:=",ExpressionUUID->"c7f362e2-aacc-4e3f-88b0-66142906a019"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9, + 3.7803127608689785`*^9}, + CellLabel-> + "In[256]:=",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"outputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "state", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.4779981058619356`*^9, 3.4779981542683554`*^9}, + 3.4780017782035847`*^9, {3.478002203430644*^9, 3.478002217153696*^9}, { + 3.478002277203772*^9, 3.4780023021490927`*^9}, {3.4780026209521627`*^9, + 3.478002664340765*^9}, {3.478021796078125*^9, 3.478021842203125*^9}, { + 3.478021885296875*^9, 3.47802199571875*^9}, {3.47802539628125*^9, + 3.478025479125*^9}, {3.478026054375*^9, 3.47802606034375*^9}, { + 3.47818056640625*^9, 3.47818064359375*^9}, {3.478184752578125*^9, + 3.478184788859375*^9}, {3.4781848254375*^9, 3.47818487890625*^9}, { + 3.47818496809375*^9, 3.478184980140625*^9}, {3.478189354859375*^9, + 3.478189379078125*^9}, {3.478582964046875*^9, 3.478583058015625*^9}, { + 3.47858310040625*^9, 3.478583226265625*^9}, {3.47858493834375*^9, + 3.478584967203125*^9}, {3.478593422734375*^9, 3.47859344625*^9}, { + 3.478593494703125*^9, 3.478593496375*^9}, {3.47859361503125*^9, + 3.478593622828125*^9}, {3.478593687*^9, 3.4785936875*^9}, { + 3.47860846046875*^9, 3.478608468515625*^9}, {3.478614677703125*^9, + 3.478614712453125*^9}, {3.47861477634375*^9, 3.4786147769375*^9}, { + 3.47861500284375*^9, 3.478615012546875*^9}, 3.50427041823978*^9, { + 3.504271184564065*^9, 3.50427119129844*^9}, {3.504271245001565*^9, + 3.50427125876719*^9}, 3.515900544738135*^9, {3.515917582755333*^9, + 3.5159176015052133`*^9}, {3.5160340846875*^9, 3.516034092609375*^9}, { + 3.51608751278125*^9, 3.51608752384375*^9}, 3.605409440222421*^9, { + 3.7632897318498783`*^9, 3.763289752695697*^9}, {3.763555436824448*^9, + 3.763555441278854*^9}, 3.7748618470277653`*^9, {3.774864662685793*^9, + 3.774864663355605*^9}}, + CellLabel-> + "In[257]:=",ExpressionUUID->"b61794f5-4c1b-4806-b168-4e11a52f0c57"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"OR", "[", + RowBox[{"x_", ",", "y_"}], "]"}], ":=", + RowBox[{"onPositive", "[", + RowBox[{"x", "+", "y", "-", "0.5"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.763547663225431*^9, 3.7635476971224737`*^9}, + 3.7748618470277653`*^9, {3.780198065667446*^9, 3.780198068473471*^9}}, + CellLabel-> + "In[258]:=",ExpressionUUID->"7c2e5afa-98be-4edf-a178-7e4f6bf53ba5"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"OR3", "[", + RowBox[{"x_", ",", "y_", ",", "z_"}], "]"}], ":=", + RowBox[{"onPositive", "[", + RowBox[{"x", "+", "y", "+", "z", "-", "0.5"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.763547663225431*^9, 3.7635476971224737`*^9}, + 3.7748618470277653`*^9, {3.780198065667446*^9, 3.7801980939313602`*^9}}, + CellLabel-> + "In[259]:=",ExpressionUUID->"47f53566-9a38-4c76-93c4-09d40b799f8a"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"stated", "\[Equal]", "state"}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.774783253698371*^9, 3.774971906112005*^9, {3.7750255655005226`*^9, + 3.7750255772118697`*^9}, {3.7801982939260798`*^9, 3.7801982945854645`*^9}, + 3.7803127336358166`*^9, 3.780312966819764*^9}, + CellLabel-> + "In[260]:=",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"state", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{"stated", "+", "qpn1", "+", "qpn2", "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"spn1", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"spn2", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"stated", "==", "state"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137867835*^9, 3.51378678615625*^9}, { + 3.513786819765625*^9, 3.513786836640625*^9}, {3.515774316984375*^9, + 3.515774329265625*^9}, 3.515900993277747*^9, {3.515901069901766*^9, + 3.51590115582348*^9}, 3.51590123047973*^9, 3.51590130276098*^9, { + 3.515901354682855*^9, 3.51590137691723*^9}, {3.5159023172550154`*^9, + 3.5159023331768904`*^9}, {3.515917393865917*^9, 3.5159173987252607`*^9}, { + 3.516031307734375*^9, 3.51603130809375*^9}, {3.516105630796875*^9, + 3.51610563796875*^9}, {3.516296275453125*^9, 3.516296276140625*^9}, { + 3.516350716859375*^9, 3.516350735953125*^9}, {3.5170224693432956`*^9, + 3.5170224723120646`*^9}, {3.5170375501720247`*^9, 3.517037561765849*^9}, { + 3.532020812921875*^9, 3.532020814265625*^9}, {3.5719277375426655`*^9, + 3.571927759008303*^9}, {3.7632895941054754`*^9, 3.763289623432971*^9}, { + 3.763289666706191*^9, 3.763289671400625*^9}, {3.763289757822764*^9, + 3.7632898416709385`*^9}, {3.7635474665352807`*^9, 3.763547467525259*^9}, { + 3.763547528268615*^9, 3.763547585669416*^9}, {3.763547626460348*^9, + 3.763547653668288*^9}, {3.76354770909213*^9, 3.763547735259143*^9}, { + 3.7635477914192247`*^9, 3.76354782225842*^9}, {3.7635478919715247`*^9, + 3.763547969476592*^9}, 3.7635546574542184`*^9, {3.7748565796257267`*^9, + 3.774856603480303*^9}, 3.7748618470277653`*^9, 3.7748627604755044`*^9, { + 3.7748629185077543`*^9, 3.7748629260418463`*^9}, {3.7748630026893625`*^9, + 3.7748630040421524`*^9}, {3.7748636325484133`*^9, + 3.7748636469639053`*^9}, {3.774863739468359*^9, 3.7748637410752134`*^9}, + 3.774870123426722*^9, {3.774870259400592*^9, 3.774870277122533*^9}, + 3.7749715341884336`*^9, {3.7749715704765964`*^9, 3.7749715741303487`*^9}, { + 3.775025438541661*^9, 3.775025508326749*^9}, {3.7750256211576815`*^9, + 3.7750256313100643`*^9}, {3.7803127945495996`*^9, 3.7803128141224346`*^9}}, + CellLabel-> + "In[261]:=",ExpressionUUID->"509e6d28-949d-4337-8cd7-f9b95184a065"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774862727374318*^9, 3.774862746875368*^9}}, + CellLabel-> + "In[262]:=",ExpressionUUID->"4f7ec10b-7ba8-4186-a59f-1e42b2118039"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7748618470287647`*^9, 3.774862692709778*^9}, + CellLabel-> + "In[263]:=",ExpressionUUID->"aec8810d-f333-480d-bfe9-4a0406b2bde4"] +}, Open ]], + +Cell[BoxData[ + TemplateBox[{ + "Write","noopen", + "\"Cannot open \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"H:\\\\\\\\\\\\\\\\PettersDropbox\\\\\\\\\\\\\\\\\ +Dropbox\\\\\\\\\\\\\\\\HopsanComponents\\\\\\\\\\\\\\\\ActivityDiagram\\\\\\\\\ +\\\\\\\\ActivityDiagram\\\\\\\\\\\\\\\\ActivityDiagramAction.hpp\\\\\\\"\\\"}]\ +\\).\"",2,263,79,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974087306*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"f9ae1ee8-a24b-4e48-a174-56045b83f0a0"], + +Cell[BoxData[ + TemplateBox[{ + "Write","noopen", + "\"Cannot open \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"H:\\\\\\\\\\\\\\\\PettersDropbox\\\\\\\\\\\\\\\\\ +Dropbox\\\\\\\\\\\\\\\\HopsanComponents\\\\\\\\\\\\\\\\ActivityDiagram\\\\\\\\\ +\\\\\\\\ActivityDiagram\\\\\\\\\\\\\\\\ActivityDiagramAction.hpp\\\\\\\"\\\"}]\ +\\).\"",2,263,80,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974121656*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"faaae5ad-65f0-405b-a86d-79a5cb710e22"], + +Cell[BoxData[ + TemplateBox[{ + "Write","noopen", + "\"Cannot open \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"H:\\\\\\\\\\\\\\\\PettersDropbox\\\\\\\\\\\\\\\\\ +Dropbox\\\\\\\\\\\\\\\\HopsanComponents\\\\\\\\\\\\\\\\ActivityDiagram\\\\\\\\\ +\\\\\\\\ActivityDiagram\\\\\\\\\\\\\\\\ActivityDiagramAction.hpp\\\\\\\"\\\"}]\ +\\).\"",2,263,81,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974138799*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"5bf0a64b-1231-4430-bd16-7522a224246c"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Write\\\", \\\"::\\\", \ +\\\"noopen\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,263,82,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.7803129742971926`*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"7c803583-69dc-4743-a94e-2e8a0da72ffa"], + +Cell[BoxData[ + TemplateBox[{ + "General","openx", + "\"\\!\\(\\*RowBox[{\\\"\\\\\\\"H:\\\\\\\\\\\\\\\\PettersDropbox\\\\\\\\\\\ +\\\\\\Dropbox\\\\\\\\\\\\\\\\HopsanComponents\\\\\\\\\\\\\\\\ActivityDiagram\\\ +\\\\\\\\\\\\\\ActivityDiagram\\\\\\\\\\\\\\\\ActivityDiagramAction.hpp\\\\\\\"\ +\\\"}]\\) is not open.\"",2,263,83,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974315183*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"71c8ae08-b63c-47da-bcca-bd726f15764f"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", RowBox[{\\\ +\"\\\\\\\"Ac\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"on\\\\\\\"\\\"}]}], \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \ +\\\"1\\\", \\\"\[RightSkeleton]\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramAction.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramAction.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.3333333333333333`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.6666666666666666`\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\ +\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0.5\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\ +\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"1\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"90\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"state\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,263, + 84,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974332173*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"39375aba-76e7-45b3-a453-8249b614dc56"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,263,85,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.7803129743521605`*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"710f5034-fffd-480a-8530-b30b9c66bcd8"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.3333333333333333`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.3333333333333333`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,263,86, + 18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.7803129743691516`*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"5ab92dc8-0a6f-4987-9b77-3beeabc0b30d"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,263,87,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974384142*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"7151b927-e1a4-43db-9c6c-8e24efe876b3"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.6666666666666666`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.6666666666666666`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,263,88, + 18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.780312974488336*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"f5be27fb-8b37-4f74-b1d6-fb358b98e683"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,263,89,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.7803129745043287`*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"a175acdf-5734-4b1c-94a8-901752e3cd36"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,263,90,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.780312914887529*^9, + 3.7803129745183344`*^9}, + CellLabel-> + "During evaluation of \ +In[263]:=",ExpressionUUID->"15bfc961-0be0-43fa-a169-b91e3587a8e2"] +}, +WindowSize->{948, 482}, +WindowMargins->{{Automatic, 13}, {Automatic, 22}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 96, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 379, 7, 28, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1235, 38, 685, 14, 28, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1923, 54, 1156, 17, 32, "Output",ExpressionUUID->"42a8cded-7c2b-4e1b-bdbc-efc3e7dede99", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[3094, 74, 414, 9, 48, "Input",ExpressionUUID->"a5795f19-20e6-4fe4-996e-0c4224394789"], +Cell[CellGroupData[{ +Cell[3533, 87, 303, 7, 28, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3839, 96, 302, 5, 67, "Section",ExpressionUUID->"3d597773-8bb1-48e6-9d32-6c53852bc4f2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4144, 103, 1693, 37, 200, "Input",ExpressionUUID->"30323ed5-d8c2-4713-8616-0c957d426752", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5840, 142, 837, 13, 32, "Output",ExpressionUUID->"9fe442b1-8ad3-40e3-9c43-a1c1203f67ba", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6680, 157, 902, 16, 32, "Output",ExpressionUUID->"d54d8937-7727-4ae6-ae3d-78f3b4deefa5", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7585, 175, 273, 6, 28, "Input",ExpressionUUID->"08535e74-7b0d-4a21-951d-5a86f4b367f3", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7861, 183, 1001, 19, 86, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8865, 204, 332, 7, 28, "Input",ExpressionUUID->"c7f362e2-aacc-4e3f-88b0-66142906a019", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9200, 213, 683, 12, 28, "Input",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9886, 227, 2077, 35, 67, "Input",ExpressionUUID->"b61794f5-4c1b-4806-b168-4e11a52f0c57", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11966, 264, 458, 10, 28, "Input",ExpressionUUID->"7c2e5afa-98be-4edf-a178-7e4f6bf53ba5", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12427, 276, 482, 10, 28, "Input",ExpressionUUID->"47f53566-9a38-4c76-93c4-09d40b799f8a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12912, 288, 557, 12, 67, "Input",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13472, 302, 2562, 41, 124, "Input",ExpressionUUID->"509e6d28-949d-4337-8cd7-f9b95184a065", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16037, 345, 271, 6, 28, "Input",ExpressionUUID->"4f7ec10b-7ba8-4186-a59f-1e42b2118039", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16311, 353, 267, 5, 28, "Input",ExpressionUUID->"aec8810d-f333-480d-bfe9-4a0406b2bde4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[16593, 361, 1804, 30, 21, "Message",ExpressionUUID->"f9ae1ee8-a24b-4e48-a174-56045b83f0a0"], +Cell[18400, 393, 1804, 30, 21, "Message",ExpressionUUID->"faaae5ad-65f0-405b-a86d-79a5cb710e22"], +Cell[20207, 425, 1804, 30, 21, "Message",ExpressionUUID->"5bf0a64b-1231-4430-bd16-7522a224246c"], +Cell[22014, 457, 1709, 28, 21, "Message",ExpressionUUID->"7c803583-69dc-4743-a94e-2e8a0da72ffa"], +Cell[23726, 487, 1803, 29, 21, "Message",ExpressionUUID->"71c8ae08-b63c-47da-bcca-bd726f15764f"], +Cell[25532, 518, 4723, 71, 76, "Message",ExpressionUUID->"39375aba-76e7-45b3-a453-8249b614dc56"], +Cell[30258, 591, 1639, 27, 21, "Message",ExpressionUUID->"710f5034-fffd-480a-8530-b30b9c66bcd8"], +Cell[31900, 620, 1811, 30, 21, "Message",ExpressionUUID->"5ab92dc8-0a6f-4987-9b77-3beeabc0b30d"], +Cell[33714, 652, 1637, 27, 21, "Message",ExpressionUUID->"7151b927-e1a4-43db-9c6c-8e24efe876b3"], +Cell[35354, 681, 1809, 30, 21, "Message",ExpressionUUID->"f5be27fb-8b37-4f74-b1d6-fb358b98e683"], +Cell[37166, 713, 1639, 27, 21, "Message",ExpressionUUID->"a175acdf-5734-4b1c-94a8-901752e3cd36"], +Cell[38808, 742, 1711, 28, 21, "Message",ExpressionUUID->"15bfc961-0be0-43fa-a169-b91e3587a8e2"] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.svg new file mode 100644 index 0000000..3a7c2b8 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.svg @@ -0,0 +1,199 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.xml new file mode 100644 index 0000000..ee00b72 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction.xml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.nb new file mode 100644 index 0000000..52f6b3d --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.nb @@ -0,0 +1,778 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 41013, 770] +NotebookOptionsPosition[ 38229, 702] +NotebookOutlinePosition[ 38656, 718] +CellTagsIndexPosition[ 38613, 715] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, 3.774794098262859*^9}}, + ExpressionUUID -> "5ee7c9b3-61b3-495d-947e-36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + ExpressionUUID -> "b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795581896713*^9, + 3.7748612729007797`*^9, 3.7748618497859235`*^9, {3.7748626953077*^9, + 3.7748627161878867`*^9}, {3.7748627484267826`*^9, 3.774862765485217*^9}, + 3.774862936369943*^9, 3.774863011141906*^9, 3.774863651011017*^9, + 3.774863747863023*^9, 3.7748646800177937`*^9, 3.7748701468329983`*^9, + 3.7748702849075556`*^9, 3.7748706042064624`*^9, 3.7748707175002804`*^9, + 3.7748708482413254`*^9, 3.7748709807026653`*^9, 3.77498657158222*^9, + 3.775025888224593*^9}, + ExpressionUUID -> "f7eb2186-9cf7-4c72-8ea5-01c96564841a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.7747982976294117`*^9, + 3.774798305629897*^9}}, + ExpressionUUID -> "f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955819626927`*^9, + 3.7748612729167113`*^9, 3.7748618498089046`*^9, {3.7748626953736324`*^9, + 3.7748627162538195`*^9}, {3.7748627484957123`*^9, 3.7748627655511484`*^9}, + 3.774862936436874*^9, 3.774863011346696*^9, 3.7748636510949306`*^9, + 3.7748637479339495`*^9, 3.7748646800967164`*^9, 3.774870146916913*^9, + 3.77487028499047*^9, 3.7748706042923727`*^9, 3.7748707175821958`*^9, + 3.7748708483282356`*^9, 3.774870980786578*^9, 3.774986571677526*^9, + 3.775025888350546*^9}, + ExpressionUUID -> "b0628de8-4240-4cb9-a759-c769c3d3e251"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + ExpressionUUID -> "96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["Action", "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.76326139564559*^9, 3.763261396833707*^9}, { + 3.774856518932431*^9, 3.774856520029351*^9}, 3.774861262095235*^9, + 3.7748618470267663`*^9}, + ExpressionUUID -> "3d597773-8bb1-48e6-9d32-6c53852bc4f2"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137112151875*^9, 3.513711217109375*^9}, { + 3.51378596903125*^9, 3.513785980671875*^9}, {3.513786401703125*^9, + 3.51378641190625*^9}, 3.5153945400188417`*^9, {3.5719276782001615`*^9, + 3.5719276783561616`*^9}, 3.5757729448720746`*^9, 3.57577312705343*^9, + 3.605856906503504*^9, {3.763261401039956*^9, 3.7632614245461197`*^9}, + 3.763261486937274*^9, 3.7635554640323896`*^9, {3.77485650920687*^9, + 3.774856514950308*^9}, 3.7748612639428415`*^9, 3.7748618470267663`*^9, { + 3.7748863536595154`*^9, 3.7748864180854287`*^9}}, + ExpressionUUID -> "30323ed5-d8c2-4713-8616-0c957d426752"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7635554294001036`*^9, 3.763555472659489*^9}, + 3.763555509393605*^9, 3.7748612729476795`*^9, {3.7748618470277653`*^9, + 3.774861849850853*^9}, {3.7748626955005016`*^9, 3.7748627163886805`*^9}, { + 3.774862748627576*^9, 3.7748627656810155`*^9}, 3.774862936566741*^9, + 3.7748630115315046`*^9, 3.77486365125976*^9, 3.7748637480708084`*^9, + 3.7748646802495584`*^9, 3.7748701470797434`*^9, 3.7748702851493063`*^9, + 3.77487060445021*^9, 3.774870717740034*^9, 3.774870848499059*^9, + 3.7748709809564033`*^9, 3.774986571863336*^9, 3.775025888593295*^9}], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "8", ",", "17", ",", "12", ",", "18", ",", + "8.4963944`8.681809631360546"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7635554294001036`*^9, 3.763555472659489*^9}, + 3.763555509393605*^9, 3.7748612729476795`*^9, {3.7748618470277653`*^9, + 3.774861849850853*^9}, {3.7748626955005016`*^9, 3.7748627163886805`*^9}, { + 3.774862748627576*^9, 3.7748627656810155`*^9}, 3.774862936566741*^9, + 3.7748630115315046`*^9, 3.77486365125976*^9, 3.7748637480708084`*^9, + 3.7748646802495584`*^9, 3.7748701470797434`*^9, 3.7748702851493063`*^9, + 3.77487060445021*^9, 3.774870717740034*^9, 3.774870848499059*^9, + 3.7748709809564033`*^9, 3.774986571863336*^9, 3.775025888597291*^9}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7748626773957825`*^9, 3.774862685600051*^9}}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, + 3.7748563175374947`*^9, {3.7748564011997128`*^9, 3.7748564081021047`*^9}}, + ExpressionUUID -> "2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774971588116584*^9, 3.774971621458659*^9}, + 3.7749719205128927`*^9}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "holdEvent", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9, { + 3.775025781047347*^9, 3.7750257815123925`*^9}, {3.775025834250453*^9, + 3.775025850421156*^9}}, + ExpressionUUID -> "938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"outputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "state", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.4779981058619356`*^9, 3.4779981542683554`*^9}, + 3.4780017782035847`*^9, {3.478002203430644*^9, 3.478002217153696*^9}, { + 3.478002277203772*^9, 3.4780023021490927`*^9}, {3.4780026209521627`*^9, + 3.478002664340765*^9}, {3.478021796078125*^9, 3.478021842203125*^9}, { + 3.478021885296875*^9, 3.47802199571875*^9}, {3.47802539628125*^9, + 3.478025479125*^9}, {3.478026054375*^9, 3.47802606034375*^9}, { + 3.47818056640625*^9, 3.47818064359375*^9}, {3.478184752578125*^9, + 3.478184788859375*^9}, {3.4781848254375*^9, 3.47818487890625*^9}, { + 3.47818496809375*^9, 3.478184980140625*^9}, {3.478189354859375*^9, + 3.478189379078125*^9}, {3.478582964046875*^9, 3.478583058015625*^9}, { + 3.47858310040625*^9, 3.478583226265625*^9}, {3.47858493834375*^9, + 3.478584967203125*^9}, {3.478593422734375*^9, 3.47859344625*^9}, { + 3.478593494703125*^9, 3.478593496375*^9}, {3.47859361503125*^9, + 3.478593622828125*^9}, {3.478593687*^9, 3.4785936875*^9}, { + 3.47860846046875*^9, 3.478608468515625*^9}, {3.478614677703125*^9, + 3.478614712453125*^9}, {3.47861477634375*^9, 3.4786147769375*^9}, { + 3.47861500284375*^9, 3.478615012546875*^9}, 3.50427041823978*^9, { + 3.504271184564065*^9, 3.50427119129844*^9}, {3.504271245001565*^9, + 3.50427125876719*^9}, 3.515900544738135*^9, {3.515917582755333*^9, + 3.5159176015052133`*^9}, {3.5160340846875*^9, 3.516034092609375*^9}, { + 3.51608751278125*^9, 3.51608752384375*^9}, 3.605409440222421*^9, { + 3.7632897318498783`*^9, 3.763289752695697*^9}, {3.763555436824448*^9, + 3.763555441278854*^9}, 3.7748618470277653`*^9, {3.774864662685793*^9, + 3.774864663355605*^9}}, + ExpressionUUID -> "b61794f5-4c1b-4806-b168-4e11a52f0c57"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"OR", "[", + RowBox[{"x_", ",", "y_"}], "]"}], ":=", + RowBox[{"onPositive", "[", + RowBox[{"x", "+", "y", "-", "0.5"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.763547663225431*^9, 3.7635476971224737`*^9}, + 3.7748618470277653`*^9}], + +Cell["\<\ +expressions = { + cpn2r == OnPositive[spn1 + limits[qpn1, -1, 1] - 0.5], + cpn1r == OnPositive[spn1 + limits[qpn2, -1, 1] - 0.5], + spn1 == cpn1r, + spn2 == cpn2r, + state == OR[spn1, spn2] + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137867835*^9, 3.51378678615625*^9}, { + 3.513786819765625*^9, 3.513786836640625*^9}, {3.515774316984375*^9, + 3.515774329265625*^9}, 3.515900993277747*^9, {3.515901069901766*^9, + 3.51590115582348*^9}, 3.51590123047973*^9, 3.51590130276098*^9, { + 3.515901354682855*^9, 3.51590137691723*^9}, {3.5159023172550154`*^9, + 3.5159023331768904`*^9}, {3.515917393865917*^9, 3.5159173987252607`*^9}, { + 3.516031307734375*^9, 3.51603130809375*^9}, {3.516105630796875*^9, + 3.51610563796875*^9}, {3.516296275453125*^9, 3.516296276140625*^9}, { + 3.516350716859375*^9, 3.516350735953125*^9}, {3.5170224693432956`*^9, + 3.5170224723120646`*^9}, {3.5170375501720247`*^9, 3.517037561765849*^9}, { + 3.532020812921875*^9, 3.532020814265625*^9}, {3.5719277375426655`*^9, + 3.571927759008303*^9}, {3.7632895941054754`*^9, 3.763289623432971*^9}, { + 3.763289666706191*^9, 3.763289671400625*^9}, {3.763289757822764*^9, + 3.7632898416709385`*^9}, {3.7635474665352807`*^9, 3.763547467525259*^9}, { + 3.763547528268615*^9, 3.763547585669416*^9}, {3.763547626460348*^9, + 3.763547653668288*^9}, {3.76354770909213*^9, 3.763547735259143*^9}, { + 3.7635477914192247`*^9, 3.76354782225842*^9}, {3.7635478919715247`*^9, + 3.763547969476592*^9}, 3.7635546574542184`*^9, {3.7748565796257267`*^9, + 3.774856603480303*^9}, 3.7748618470277653`*^9, 3.7748627604755044`*^9, { + 3.7748629185077543`*^9, 3.7748629260418463`*^9}, {3.7748630026893625`*^9, + 3.7748630040421524`*^9}, 3.7748700995859013`*^9}, + ExpressionUUID -> "509e6d28-949d-4337-8cd7-f9b95184a065"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"oldEvent", "\[Equal]", "event"}], ",", "\[IndentingNewLine]", + RowBox[{"stated", "==", "0."}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.774783253698371*^9, 3.774971906112005*^9, {3.7750255655005226`*^9, + 3.7750255772118697`*^9}}, + ExpressionUUID -> "6c284b1c-2e66-492e-90e5-21e73aaf28a9"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"state", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{"stated", "+", "qpn1", "+", "qpn2", "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"spn1", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"iEvent", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "+", + RowBox[{"holdEvent", "*", "oldiEvent", "*", "state"}], "-", "0.5"}], + "]"}]}], ",", "\[IndentingNewLine]", + RowBox[{"spn2", "==", + RowBox[{"state", " ", "iEvent"}]}], ",", "\[IndentingNewLine]", + RowBox[{"stated", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"oldiEvent", "\[Equal]", "iEvent"}]}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137867835*^9, 3.51378678615625*^9}, { + 3.513786819765625*^9, 3.513786836640625*^9}, {3.515774316984375*^9, + 3.515774329265625*^9}, 3.515900993277747*^9, {3.515901069901766*^9, + 3.51590115582348*^9}, 3.51590123047973*^9, 3.51590130276098*^9, { + 3.515901354682855*^9, 3.51590137691723*^9}, {3.5159023172550154`*^9, + 3.5159023331768904`*^9}, {3.515917393865917*^9, 3.5159173987252607`*^9}, { + 3.516031307734375*^9, 3.51603130809375*^9}, {3.516105630796875*^9, + 3.51610563796875*^9}, {3.516296275453125*^9, 3.516296276140625*^9}, { + 3.516350716859375*^9, 3.516350735953125*^9}, {3.5170224693432956`*^9, + 3.5170224723120646`*^9}, {3.5170375501720247`*^9, 3.517037561765849*^9}, { + 3.532020812921875*^9, 3.532020814265625*^9}, {3.5719277375426655`*^9, + 3.571927759008303*^9}, {3.7632895941054754`*^9, 3.763289623432971*^9}, { + 3.763289666706191*^9, 3.763289671400625*^9}, {3.763289757822764*^9, + 3.7632898416709385`*^9}, {3.7635474665352807`*^9, 3.763547467525259*^9}, { + 3.763547528268615*^9, 3.763547585669416*^9}, {3.763547626460348*^9, + 3.763547653668288*^9}, {3.76354770909213*^9, 3.763547735259143*^9}, { + 3.7635477914192247`*^9, 3.76354782225842*^9}, {3.7635478919715247`*^9, + 3.763547969476592*^9}, 3.7635546574542184`*^9, {3.7748565796257267`*^9, + 3.774856603480303*^9}, 3.7748618470277653`*^9, 3.7748627604755044`*^9, { + 3.7748629185077543`*^9, 3.7748629260418463`*^9}, {3.7748630026893625`*^9, + 3.7748630040421524`*^9}, {3.7748636325484133`*^9, + 3.7748636469639053`*^9}, {3.774863739468359*^9, 3.7748637410752134`*^9}, + 3.774870123426722*^9, {3.774870259400592*^9, 3.774870277122533*^9}, + 3.7749715341884336`*^9, {3.7749715704765964`*^9, 3.7749715741303487`*^9}, { + 3.775025438541661*^9, 3.775025508326749*^9}, {3.7750256211576815`*^9, + 3.7750256313100643`*^9}, {3.775025772158289*^9, 3.7750257746841974`*^9}, + 3.775025819211686*^9}, + ExpressionUUID -> "509e6d28-949d-4337-8cd7-f9b95184a065"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774862727374318*^9, 3.774862746875368*^9}}], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7748618470287647`*^9, 3.774862692709778*^9}, + ExpressionUUID -> "aec8810d-f333-480d-bfe9-4a0406b2bde4"] +}, Open ]], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", RowBox[{\\\ +\"\\\\\\\"Activi\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"mAction\\\\\\\"\\\"}]}], \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\ +\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\ +\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramAction.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramAction.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.3333333333333333`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.6666666666666666`\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\ +\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0.5\\\ +\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"1\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"90\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"state\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,1156, + 361,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258898919215`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,1156,362,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258899628477`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.3333333333333333`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.3333333333333333`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,1156,363, + 16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258899898195`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,1156,364,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258900197887`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.6666666666666666`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.6666666666666666`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,1156,365, + 16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258900467606`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,1156,366,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.775025890073733*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,1156,367,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258900997066`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,1156,368,16167503661247200239, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.775025890127678*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,1156,369,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7748612730880413`*^9, {3.7748618470307627`*^9, + 3.774861850012192*^9}, {3.774862695914073*^9, 3.7748627167887745`*^9}, { + 3.7748627491114388`*^9, 3.7748627662139416`*^9}, 3.774862937098192*^9, + 3.7748630120849338`*^9, 3.774863652144906*^9, 3.7748637487141438`*^9, + 3.774864681180854*^9, 3.774870147764037*^9, 3.774870285797638*^9, + 3.7748706052863464`*^9, 3.7748707185472*^9, 3.774870849374157*^9, + 3.7748709818644667`*^9, 3.7749865729363995`*^9, 3.7750258901536503`*^9}, + ExpressionUUID -> "f03dda11-b013-4c4f-b533-9b7aeca16382"] +}, +WindowSize->{1091, 684}, +WindowMargins->{{197, Automatic}, {23, Automatic}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 270, 4, 101, "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[852, 28, 355, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1210, 36, 1211, 21, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2424, 59, 1097, 16, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3524, 77, 661, 13, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4188, 92, 1108, 16, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5299, 110, 279, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5581, 118, 304, 5, 70, "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5888, 125, 1669, 36, 202, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7560, 163, 726, 10, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8289, 175, 791, 13, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9083, 190, 190, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9276, 196, 977, 18, 88, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10256, 216, 444, 11, 69, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10703, 229, 970, 18, 69, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11676, 249, 2053, 34, 69, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13732, 285, 329, 8, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14064, 295, 1862, 31, 144, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15929, 328, 517, 12, 88, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16449, 342, 2892, 48, 164, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[19344, 392, 188, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[19535, 398, 243, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[19793, 405, 5235, 76, 76, "Message"], +Cell[25031, 483, 1568, 24, 21, "Message"], +Cell[26602, 509, 1740, 27, 21, "Message"], +Cell[28345, 538, 1568, 24, 21, "Message"], +Cell[29916, 564, 1740, 27, 21, "Message"], +Cell[31659, 593, 1566, 24, 21, "Message"], +Cell[33228, 619, 1640, 25, 21, "Message"], +Cell[34871, 646, 1708, 27, 21, "Message"], +Cell[36582, 675, 1643, 25, 21, "Message"] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.svg new file mode 100644 index 0000000..5235120 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction1.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.hpp new file mode 100644 index 0000000..76c3ad9 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.hpp @@ -0,0 +1,152 @@ +/*----------------------------------------------------------------------------- + This source file is a part of Hopsan + + Copyright (c) 2009 to present year, Hopsan Group + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramActionN.hpp +//! @author Petter Krus, Robert Braun, Emilia Villani +//! @date 2019-08-15 +//! based on ElectricCapacitanceMultiPort.hpp and Volume component by Björn Eriksson +//! @brief Contains a Electric Volume Component +//! + +#ifndef ACTIVITYDIAGRAMACTIONN_HPP_INCLUDED +#define ACTIVITYDIAGRAMACTIONN_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A StateMachine state component + //! @ingroup StateMachine + //! + class ActivityDiagramActionN : public ComponentC + { + + private: + double state; + double *mpAlpha; + double *mpstate; +// double capacitance; + + std::vector mvpN_s, mvpN_q; + std::vector mvp_S0; + size_t mNumPorts; + Port *mpPpn1; + + std::mutex mTokenMutex; + bool mTokenLocked; + + public: + static Component *Creator() + { + return new ActivityDiagramActionN(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); +// addConstant("Capacitance", "Capacitance", "Fa", 0.0001, capacitance); + addInputVariable("alpha", "Low pass coeficient to dampen standing delayline waves", "-", 0.3, &mpAlpha); + addOutputVariable("state","State activated","",0.,&mpstate); + } + + + void initialize() + { + double alpha; + double state; + alpha = (*mpAlpha); + + mNumPorts = mpPpn1->getNumPorts(); + mvpN_s.resize(mNumPorts); + mvpN_q.resize(mNumPorts); + mvp_S0.resize(mNumPorts); + + for (size_t i=0; i + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.xml new file mode 100644 index 0000000..4fe92f0 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN.xml @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN_active.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN_active.svg new file mode 100644 index 0000000..a772e5f --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramActionN_active.svg @@ -0,0 +1,199 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_action.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_action.svg new file mode 100644 index 0000000..4e52d02 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_action.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_active.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_active.svg new file mode 100644 index 0000000..bd6ec35 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramAction_active.svg @@ -0,0 +1,199 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.hpp new file mode 100644 index 0000000..71d7446 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.hpp @@ -0,0 +1,155 @@ +#ifndef ACTIVITYDIAGRAMCONNECTOR_HPP_INCLUDED +#define ACTIVITYDIAGRAMCONNECTOR_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramConnector.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 15 Aug 2019 15:00:38 +//! @brief Connector between Q-components +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramConnector.nb*/ + +using namespace hopsan; + +class ActivityDiagramConnector : public ComponentC +{ +private: + Port *mpPpn1; + Port *mpPpn2; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; +//==This code has been autogenerated using Compgen== + //inputVariables + //outputVariables + //InitialExpressions variables + double stated; + //Expressions variables + double state; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + //inputParameters pointers + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramConnector(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + //Add inputVariables to the component + + //Add inputParammeters to the component + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + spn1 = state; + spn2 = state; + stated = state; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + qpn1 = (*mpP_qpn1); + //Port Ppn2 + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //LocalExpressions + + //Expressions + state = onPositive(-0.5 + qpn1 + qpn2 + stated); + spn1 = state; + spn2 = state; + stated = state; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_spn1)=spn1; + //Port Ppn2 + (*mpP_spn2)=spn2; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMCONNECTOR_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.nb new file mode 100644 index 0000000..2b68516 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.nb @@ -0,0 +1,551 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 28673, 543] +NotebookOptionsPosition[ 26548, 489] +NotebookOutlinePosition[ 26976, 505] +CellTagsIndexPosition[ 26933, 502] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, 3.774794098262859*^9}}, + ExpressionUUID -> "5ee7c9b3-61b3-495d-947e-36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + ExpressionUUID -> "b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795581896713*^9, + 3.774861290427595*^9, 3.7748618675437913`*^9, 3.7748628376552143`*^9}, + ExpressionUUID -> "f7eb2186-9cf7-4c72-8ea5-01c96564841a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.7747982976294117`*^9, + 3.774798305629897*^9}}, + ExpressionUUID -> "f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955819626927`*^9, + 3.77486129045057*^9, 3.7748618675707636`*^9, 3.774862837718149*^9}, + ExpressionUUID -> "b0628de8-4240-4cb9-a759-c769c3d3e251"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + ExpressionUUID -> "96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Connector", "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.76326139564559*^9, 3.763261396833707*^9}, { + 3.7651000854987707`*^9, 3.765100087443925*^9}, {3.7653865322639866`*^9, + 3.7653865340311356`*^9}, {3.7748562895395265`*^9, 3.77485628999905*^9}, + 3.7748618642499804`*^9}, + ExpressionUUID -> "3d597773-8bb1-48e6-9d32-6c53852bc4f2"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137112151875*^9, 3.513711217109375*^9}, { + 3.51378596903125*^9, 3.513785980671875*^9}, {3.513786401703125*^9, + 3.51378641190625*^9}, 3.5153945400188417`*^9, {3.5719276782001615`*^9, + 3.5719276783561616`*^9}, 3.5757729448720746`*^9, 3.57577312705343*^9, + 3.605856906503504*^9, {3.763261401039956*^9, 3.7632614245461197`*^9}, + 3.763261486937274*^9, 3.7635554640323896`*^9, {3.7651000790778112`*^9, + 3.765100080702778*^9}, {3.7653865380490265`*^9, 3.7653865624643803`*^9}, + 3.774856291577958*^9, 3.7748618642509794`*^9, {3.7753176502934604`*^9, + 3.775317651851361*^9}}, + ExpressionUUID -> "30323ed5-d8c2-4713-8616-0c957d426752"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "8", ",", "15", ",", "15", ",", "0", ",", + "37.7880757`9.329929664938739"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7635554294001036`*^9, 3.763555472659489*^9}, + 3.763555509393605*^9, 3.7651000962570324`*^9, 3.765386594754282*^9, + 3.76538691023928*^9, {3.7653869665779047`*^9, 3.765387006151044*^9}, + 3.774861290488532*^9, {3.7748618642509794`*^9, 3.7748618676217117`*^9}, + 3.7748628378510113`*^9}, + ExpressionUUID -> "9d107ea6-e9fe-41c6-a8e7-5bcedeab53a6"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774862824750338*^9, 3.774862835795474*^9}}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetCnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, + 3.7748563175374947`*^9, {3.7748564011997128`*^9, 3.7748564081021047`*^9}}, + ExpressionUUID -> "2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"spn1", "\[Equal]", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"spn2", "\[Equal]", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"stated", "\[Equal]", "state"}]}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.763289864104106*^9, 3.763289897920729*^9}, { + 3.7635474793820314`*^9, 3.763547509099383*^9}, {3.765176052051984*^9, + 3.7651760911784735`*^9}, {3.765386969540123*^9, 3.7653869746931953`*^9}, { + 3.774856340135704*^9, 3.774856341714076*^9}, 3.7748618642509794`*^9}, + ExpressionUUID -> "3d8202ca-d0f5-49af-a79f-b899cac3e64e"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"state", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{"stated", "+", "qpn1", "+", "qpn2", "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"spn1", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"spn2", "==", "state"}], ",", "\[IndentingNewLine]", + RowBox[{"stated", "==", "state"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5137867835*^9, 3.51378678615625*^9}, { + 3.513786819765625*^9, 3.513786836640625*^9}, {3.515774316984375*^9, + 3.515774329265625*^9}, 3.515900993277747*^9, {3.515901069901766*^9, + 3.51590115582348*^9}, 3.51590123047973*^9, 3.51590130276098*^9, { + 3.515901354682855*^9, 3.51590137691723*^9}, {3.5159023172550154`*^9, + 3.5159023331768904`*^9}, {3.515917393865917*^9, 3.5159173987252607`*^9}, { + 3.516031307734375*^9, 3.51603130809375*^9}, {3.516105630796875*^9, + 3.51610563796875*^9}, {3.516296275453125*^9, 3.516296276140625*^9}, { + 3.516350716859375*^9, 3.516350735953125*^9}, {3.5170224693432956`*^9, + 3.5170224723120646`*^9}, {3.5170375501720247`*^9, 3.517037561765849*^9}, { + 3.532020812921875*^9, 3.532020814265625*^9}, {3.5719277375426655`*^9, + 3.571927759008303*^9}, {3.7632895941054754`*^9, 3.763289623432971*^9}, { + 3.763289666706191*^9, 3.763289671400625*^9}, {3.763289757822764*^9, + 3.7632898416709385`*^9}, {3.7635474665352807`*^9, 3.763547467525259*^9}, { + 3.763547528268615*^9, 3.763547585669416*^9}, {3.763547626460348*^9, + 3.763547653668288*^9}, {3.76354770909213*^9, 3.763547735259143*^9}, { + 3.7635477914192247`*^9, 3.76354782225842*^9}, {3.7635478919715247`*^9, + 3.763547969476592*^9}, 3.7635546574542184`*^9, 3.7651039003541737`*^9, { + 3.7651759614596443`*^9, 3.7651760366289396`*^9}, {3.765176095975005*^9, + 3.7651760975217886`*^9}, 3.7653868967327237`*^9, {3.774856340612213*^9, + 3.774856358031646*^9}, 3.7748618642509794`*^9}, + ExpressionUUID -> "509e6d28-949d-4337-8cd7-f9b95184a065"], + +Cell[BoxData[ + RowBox[{"stated", "=."}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7653869016535296`*^9, 3.7653869038928185`*^9}, + 3.77486186425198*^9, 3.7748628357964735`*^9}], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7748618642529783`*^9, 3.7748628357964735`*^9}, + ExpressionUUID -> "aec8810d-f333-480d-bfe9-4a0406b2bde4"] +}, Open ]], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramConnector\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\\\\\\\"\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector.svg\\\\\\\"\\\"}]}], \\\"}\\\"}], \ +\\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\ +\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \ +\\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.3333333333333333`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.6666666666666666`\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\ +\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{\\\"\\\\\\\"version\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"0.1\\\\\\\"\\\"}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\\\\\\\"\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramConnector.svg\\\\\\\"\\\"}]}], \\\"}\\\"}], \ +\\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\ +\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \ +\\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.3333333333333333`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.6666666666666666`\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\ +\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of \ +contents. The third item in an XMLElement must be a list of contents, even if \ +it is an empty list.\"",2,602,168,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.7748628382695794`*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,602,169,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.774862838305542*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.3333333333333333`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.3333333333333333`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,602,170, + 16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.7748628383325143`*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,602,171,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.7748628383594866`*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.6666666666666666`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.6666666666666666`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,602,172, + 16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.774862838387458*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,602,173,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.774862838415429*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,602,174,16167503661247200239,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{ + 3.5757730376898375`*^9, 3.575773140505853*^9, 3.575773171674708*^9, + 3.5757732459312596`*^9, 3.57577337871232*^9, 3.575773437689036*^9, { + 3.5757736068026357`*^9, 3.575773631680291*^9}, 3.575773964573552*^9, + 3.5757742577284737`*^9, 3.5757743037687798`*^9, 3.575774383957745*^9, + 3.5757744581883354`*^9, 3.5757745324295645`*^9, 3.5757745960243807`*^9, + 3.575774636157867*^9, 3.5757747246884623`*^9, 3.575779425878719*^9, + 3.575785968311123*^9, 3.5757864542818437`*^9, 3.5757868538620157`*^9, + 3.5758175885229187`*^9, 3.578816692641367*^9, 3.5814060107874413`*^9, + 3.5814061612660484`*^9, 3.5814062947836847`*^9, 3.6031910270993757`*^9, + 3.6054095240498033`*^9, {3.7635554295259733`*^9, 3.7635554727523937`*^9}, + 3.7635555094785175`*^9, 3.7651000975310903`*^9, 3.7653865949111214`*^9, + 3.7653869104420753`*^9, {3.7653869668556175`*^9, 3.7653870063548346`*^9}, + 3.7748612906263895`*^9, 3.774861864253978*^9, 3.774862838442401*^9}, + ExpressionUUID -> "167b2bea-209f-456f-b205-bce89352fad9"] +}, +WindowSize->{1050, 735}, +WindowMargins->{{Automatic, 322}, {Automatic, 118}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 270, 4, 101, "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[852, 28, 355, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1210, 36, 1211, 21, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2424, 59, 702, 10, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3129, 71, 661, 13, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3793, 86, 706, 10, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4502, 98, 279, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4784, 106, 404, 6, 70, "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5191, 114, 1753, 38, 202, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6947, 154, 583, 11, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7533, 167, 188, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7724, 173, 977, 18, 88, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8704, 193, 768, 14, 107, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9475, 209, 2152, 35, 126, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11630, 246, 224, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11857, 252, 245, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[12117, 259, 6339, 89, 130, "Message"], +Cell[18459, 350, 1275, 20, 21, "Message"], +Cell[19737, 372, 1449, 23, 21, "Message"], +Cell[21189, 397, 1277, 20, 21, "Message"], +Cell[22469, 419, 1447, 23, 21, "Message"], +Cell[23919, 444, 1275, 20, 21, "Message"], +Cell[25197, 466, 1347, 21, 21, "Message"] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.svg new file mode 100644 index 0000000..30d89f2 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.svg @@ -0,0 +1,132 @@ + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.xml new file mode 100644 index 0000000..787a5d5 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramConnector.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.hpp new file mode 100644 index 0000000..91effe0 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.hpp @@ -0,0 +1,244 @@ +#ifndef ACTIVITYDIAGRAMDECISION_HPP_INCLUDED +#define ACTIVITYDIAGRAMDECISION_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" +//! +//! @file ActivityDiagramDecision.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Tue 20 Aug 2019 21:23:44 +//! @brief If selection for state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramDecision.nb*/ + +using namespace hopsan; + +class ActivityDiagramDecision : public ComponentQ +{ +private: + double diffevent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event2; + double event3; + //outputVariables + //InitialExpressions variables + double oldEvent2; + double oldEvent3; + //Expressions variables + double dEvent2; + double dEvent3; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent2; + double *mpevent3; + //inputParameters pointers + double *mpdiffevent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramDecision(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event2","trigger on positive \ +flank","",0.,&mpevent2); + addInputVariable("event3","trigger on positive \ +flank","",0.,&mpevent3); + + //Add inputParammeters to the component + addInputVariable("diffevent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffevent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event2 = (*mpevent2); + event3 = (*mpevent3); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent2 = event2; + oldEvent3 = event3; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event2 = (*mpevent2); + event3 = (*mpevent3); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //LocalExpressions + + //Expressions + dEvent2 = onPositive(-0.5 + event2 - diffevent*oldEvent2); + dEvent3 = onPositive(-0.5 + event3 - diffevent*oldEvent3); + + //Preventing creation of extra token + double qpn20 = dEvent2*onPositive(spn1 - spn2); + double qpn30 = dEvent3*onPositive(spn1 - spn3); + bool successP1; + bool successP2; + bool successP3; + + qpn2 = 0; + qpn3 = 0; + qpn1 = 0; + + if(qpn20 > 0 || qpn30 > 0) { + successP1 = true; + //Try to lock P1 + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP1 = component->tryAndLockToken(); + } + } + } + //Try to lock P2 + if(qpn20 > 0) { + successP2 = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP2 = component->tryAndLockToken(); + } + } + } + //Try to lock P3 + if(qpn30 > 0) { + successP3 = true; + for(auto pPort : mpPpn3->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP3 = component->tryAndLockToken(); + } + } + } + if(qpn20 > 0 || qpn30 > 0) { + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successP1 && successP2) { + addDebugMessage("Locked tokens!"); + qpn2 = dEvent2*onPositive(spn1 - spn2); + } + if(successP1 && successP3) { + qpn3 = dEvent3*(1 - qpn2)*onPositive(spn1 - spn3); + } + } + qpn1 = -onPositive(-0.5 + qpn2 + qpn3); + oldEvent2 = event2; + oldEvent3 = event3; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMDECISION_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.nb new file mode 100644 index 0000000..975f7d6 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.nb @@ -0,0 +1,746 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 40147, 738] +NotebookOptionsPosition[ 35550, 665] +NotebookOutlinePosition[ 35968, 681] +CellTagsIndexPosition[ 35925, 678] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel->"In[64]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.7747982976294117`*^9, + 3.774798305629897*^9}}, + CellLabel->"In[65]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"] +}, Open ]], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellChangeTimes->{3.7839336026642847`*^9}, + CellLabel->"Out[65]=",ExpressionUUID->"1a41fbbe-4cae-413c-9835-7598e46f812a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7839335960458083`*^9}, + CellLabel->"In[66]:=",ExpressionUUID->"3942318d-c5ab-4bbb-b9f9-af1d93363738"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellChangeTimes->{3.783933602781729*^9}, + CellLabel->"Out[66]=",ExpressionUUID->"6e065920-ee9c-4f29-ad85-37cfb9be7634"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel->"In[67]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Decision", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.755021377179763*^9, 3.7550213776352935`*^9}, {3.7551010992251368`*^9, + 3.7551011067453823`*^9}, {3.7552806950102434`*^9, 3.755280707559305*^9}, { + 3.7552808134950852`*^9, 3.755280835886998*^9}, 3.7571794848474817`*^9, { + 3.7653654640344186`*^9, 3.765365465561455*^9}, {3.7747937389060163`*^9, + 3.7747937761626363`*^9}, + 3.7747942097903123`*^9},ExpressionUUID->"579c246d-7234-4bbc-a83d-\ +653b42f152d9"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1,qpn2 and qpn3, are either \ +0 or 1 in one time step. The state variables spn1, spn2 and spn3 are either 0 \ +or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940079196377`*^9}, + 3.774794209791312*^9},ExpressionUUID->"bdc3e281-aa00-44be-ae84-\ +967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.755021382930831*^9, 3.7550214033397913`*^9}, { + 3.755101114360531*^9, 3.7551011191455984`*^9}, {3.755101168038189*^9, + 3.7551011721439543`*^9}, {3.755280720238233*^9, 3.7552807489446363`*^9}, { + 3.7552808264926853`*^9, 3.7552808399757824`*^9}, 3.757179487096159*^9, { + 3.7653654729463096`*^9, 3.7653654743850803`*^9}, {3.7747937498138437`*^9, + 3.7747937597243137`*^9}, 3.774794209791312*^9, 3.7753178059060497`*^9}, + CellLabel->"In[68]:=",ExpressionUUID->"c12350b7-5012-4a2e-bec0-d7181fc31046"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, {3.755021329018415*^9, 3.7550213665227485`*^9}, + 3.7550303361670485`*^9, 3.75509948840012*^9, 3.755099526958366*^9, + 3.7550997876705723`*^9, {3.755099820283948*^9, 3.75509982687815*^9}, { + 3.7551002782832775`*^9, 3.7551002917983437`*^9}, 3.7551003528322644`*^9, + 3.755100442002329*^9, 3.755100477968249*^9, 3.755100585680197*^9, + 3.755101132745575*^9, 3.7551013081956844`*^9, {3.7551015577480392`*^9, + 3.7551015772489343`*^9}, 3.7551017587433357`*^9, 3.7551045059350233`*^9, + 3.7552831648088813`*^9, 3.757179814550045*^9, {3.757437878596813*^9, + 3.75743788971733*^9}, 3.7574481003314004`*^9, 3.763203498934745*^9, + 3.763203573039265*^9, 3.7632048221363173`*^9, 3.7632050097741833`*^9, + 3.765365811250082*^9, 3.774794209791312*^9, 3.774795582092512*^9, + 3.7748613015248985`*^9, 3.774861875518277*^9, 3.7748629660436335`*^9, + 3.775317823771299*^9, 3.7839336029684124`*^9}, + CellLabel->"Out[73]=",ExpressionUUID->"565c5faf-895b-4afd-a9ec-6c5289b0951e"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "11", ",", "28", ",", "13", ",", "40", ",", + "2.8902734`8.21351390967783"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, {3.755021329018415*^9, 3.7550213665227485`*^9}, + 3.7550303361670485`*^9, 3.75509948840012*^9, 3.755099526958366*^9, + 3.7550997876705723`*^9, {3.755099820283948*^9, 3.75509982687815*^9}, { + 3.7551002782832775`*^9, 3.7551002917983437`*^9}, 3.7551003528322644`*^9, + 3.755100442002329*^9, 3.755100477968249*^9, 3.755100585680197*^9, + 3.755101132745575*^9, 3.7551013081956844`*^9, {3.7551015577480392`*^9, + 3.7551015772489343`*^9}, 3.7551017587433357`*^9, 3.7551045059350233`*^9, + 3.7552831648088813`*^9, 3.757179814550045*^9, {3.757437878596813*^9, + 3.75743788971733*^9}, 3.7574481003314004`*^9, 3.763203498934745*^9, + 3.763203573039265*^9, 3.7632048221363173`*^9, 3.7632050097741833`*^9, + 3.765365811250082*^9, 3.774794209791312*^9, 3.774795582092512*^9, + 3.7748613015248985`*^9, 3.774861875518277*^9, 3.7748629660436335`*^9, + 3.775317823771299*^9, 3.7839336029684124`*^9}, + CellLabel->"Out[77]=",ExpressionUUID->"de71617e-5329-4b4c-90a5-a75119ee28f7"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, { + 3.7753178114071627`*^9, 3.7753178126798496`*^9}}, + CellLabel->"In[78]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", " ", "=", " ", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"{", + RowBox[{ + "event2", ",", " ", "0.", ",", " ", "double", ",", " ", "\"\<\>\"", ",", + " ", "\"\\""}], "}"}], ",", + "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event3", ",", " ", "0.", ",", " ", "double", ",", " ", "\"\<\>\"", ",", + " ", "\"\\""}], "}"}]}], "\n", " ", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, {3.7550211707735662`*^9, 3.7550212091549945`*^9}, { + 3.7550213368433485`*^9, 3.755021361930483*^9}, {3.7551002377111077`*^9, + 3.755100273841857*^9}, {3.755100337895664*^9, 3.7551003437256527`*^9}, + 3.7551004328008165`*^9, {3.755100578582515*^9, 3.755100578669425*^9}, { + 3.7551014342164*^9, 3.7551014381583347`*^9}, {3.755101493431348*^9, + 3.755101495198529*^9}, {3.755101546333806*^9, 3.7551015485175548`*^9}, + 3.755280763360775*^9, {3.757179509086452*^9, 3.7571795220091095`*^9}, { + 3.757179560664197*^9, 3.7571795619668493`*^9}, 3.7747942097923093`*^9}, + CellLabel->"In[79]:=",ExpressionUUID->"84b1787a-183b-4920-a69d-4df94c20bba2"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffevent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7747942097923093`*^9}, + CellLabel->"In[80]:=",ExpressionUUID->"0c74128b-2532-4223-a2a4-740b1043b57b"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"oldEvent2", "\[Equal]", "event2"}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent3", "\[Equal]", "event3"}]}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7655533786392612`*^9, 3.765553382135273*^9}, + 3.765553549418847*^9, {3.765555534690852*^9, 3.765555545228863*^9}, + 3.7749722366624327`*^9}, + CellLabel->"In[81]:=",ExpressionUUID->"e5511e4a-3353-4719-a540-40dff57756df"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent2", "==", + RowBox[{"onPositive", "[", + RowBox[{"event2", "-", + RowBox[{"diffevent", " ", "oldEvent2"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"dEvent3", "==", + RowBox[{"onPositive", "[", + RowBox[{"event3", "-", + RowBox[{"diffevent", " ", "oldEvent3"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn2", "\[Equal]", + RowBox[{"dEvent2", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn2"}], "]"}]}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn3", "\[Equal]", + RowBox[{"dEvent3", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn3"}], "]"}], + RowBox[{"(", + RowBox[{"1", "-", "qpn2"}], ")"}]}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn1", "\[Equal]", + RowBox[{"-", + RowBox[{"onPositive", "[", + RowBox[{"qpn2", "+", "qpn3", "-", "0.5"}], "]"}]}]}], ",", + "\[IndentingNewLine]", + RowBox[{"oldEvent2", "==", "event2"}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent3", "==", "event3"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.755021228933604*^9, + 3.755021278948039*^9}, {3.7550991045618577`*^9, 3.755099112472701*^9}, { + 3.755099168634801*^9, 3.7550992698544407`*^9}, {3.7550993152716155`*^9, + 3.755099358142417*^9}, {3.7550994059501266`*^9, 3.7550994196639867`*^9}, + 3.7550995178927135`*^9, 3.7551004381113434`*^9, 3.7551045016584373`*^9, { + 3.7552807682737083`*^9, 3.755280770768137*^9}, {3.757179542215247*^9, + 3.757179752373249*^9}, {3.7574378471313057`*^9, 3.757437865501336*^9}, + 3.757448097268563*^9, {3.7595689924690266`*^9, 3.759568992946535*^9}, { + 3.76320347871198*^9, 3.763203482457853*^9}, {3.7632045298557444`*^9, + 3.7632045309021263`*^9}, {3.763204981137596*^9, 3.7632049858229017`*^9}, { + 3.7655555913655677`*^9, 3.765555595465226*^9}, {3.774793862135045*^9, + 3.7747938673846397`*^9}, {3.7747939015294933`*^9, 3.7747939124081473`*^9}, + 3.7747942097923093`*^9}, + CellLabel->"In[82]:=",ExpressionUUID->"3cfb1a01-c132-42a5-9718-0d816c76266d"], + +Cell[BoxData["file"], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.75509983772097*^9, 3.7550998382344413`*^9}, + 3.7747942097923093`*^9}, + CellLabel->"In[83]:=",ExpressionUUID->"2ac98d27-7834-4af5-8633-0d47fd58d28b"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\ +ActivityDiagramDecision.hpp\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755099839466172*^9, {3.7551002784451103`*^9, 3.755100291957179*^9}, + 3.7551003529920993`*^9, 3.7551004421621637`*^9, 3.7551004781310806`*^9, + 3.7551005858670053`*^9, 3.7551011329084063`*^9, 3.755101308363512*^9, { + 3.755101557911868*^9, 3.7551015773578196`*^9}, 3.755101758976097*^9, + 3.755104506123829*^9, 3.755283164925761*^9, 3.7571798146669254`*^9, { + 3.757437883899338*^9, 3.7574378898442*^9}, 3.7574481005791445`*^9, + 3.763203499779257*^9, 3.7632035734960213`*^9, 3.763204822587062*^9, + 3.7632050102229333`*^9, 3.7653658113939333`*^9, 3.7747942097933083`*^9, + 3.774795582508052*^9, 3.7748629664251757`*^9, 3.775317824124934*^9, + 3.7839336034559755`*^9}, + CellLabel->"Out[83]=",ExpressionUUID->"b052cbd8-eb76-426e-934e-f2f7007b974a"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7747942097933083`*^9}, + CellLabel->"In[84]:=",ExpressionUUID->"15f971df-cb2f-4ac0-8bbd-ca375d983568"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramDecision\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"di\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"ame\\\\\\\"\\\"}], \\\"\[Rule]\\\", \ +RowBox[{\\\"\\\\\\\"\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"\\\\\\\"\\\ +\"}]}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramDecision.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramDecision.svg\\\\\\\"\\\"}]}], \\\"}\\\ +\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"3\\\", \\\"\[RightSkeleton]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"0.6666666666666666`\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\ +\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{RowBox[{\\\"\\\\\\\"t\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"e\\\\\\\"\\\"}], \\\"\[Rule]\\\", \ +RowBox[{\\\"\\\\\\\"\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"\\\\\\\"\\\ +\"}]}], \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramDecision.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramDecision.svg\\\\\\\"\\\"}]}], \\\"}\\\ +\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"3\\\", \\\"\[RightSkeleton]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"0.6666666666666666`\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\ +\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\ +\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of \ +contents. The third item in an XMLElement must be a list of contents, even if \ +it is an empty list.\"",2,84,31,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.783933603848233*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"76ff43ed-3ee0-4554-a868-23fe63b7c7b4"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,84,32,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336039082193`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"dfa857ec-dcfe-42a8-9bec-6439f25007b7"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 84,33,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336041041718`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"09d2bd23-7376-46e8-9475-096e75678d98"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,84,34,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336041281643`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"6a5823bc-facd-4a54-bcfd-26e0fa38e28d"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,84,35,19014042857157888424, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.783933604148158*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"ac828d08-81de-41ce-ada3-e69cfc0a22cf"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,84,36,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336041721535`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"007fff6f-42a3-4aca-b643-f8f2aca075c0"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,84,37,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336042886777`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"c519699f-3054-42fd-b694-3a18e2e4fcff"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 84,38,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336043043046`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"38d286a5-2bd2-4211-92d5-4572295974f6"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,84,39,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, {3.755021329155275*^9, 3.755021366659608*^9}, + 3.7550303363828263`*^9, 3.755099488643869*^9, 3.755099527170148*^9, + 3.7550997878733644`*^9, {3.7550998204387884`*^9, 3.7550998270959263`*^9}, { + 3.7551002785250273`*^9, 3.7551002920360975`*^9}, 3.7551003530740137`*^9, + 3.7551004422470765`*^9, 3.7551004782090006`*^9, 3.755100585945923*^9, + 3.755101133012299*^9, 3.755101308445428*^9, {3.7551015579927855`*^9, + 3.7551015780371203`*^9}, 3.7551017590570126`*^9, 3.7551045062177305`*^9, + 3.7552831650126696`*^9, 3.7571798149016824`*^9, {3.7574378852958965`*^9, + 3.757437889949091*^9}, 3.7574481008258905`*^9, 3.7632035003979006`*^9, + 3.7632035736738987`*^9, 3.763204822793942*^9, 3.7632050104028273`*^9, + 3.7653658114788456`*^9, 3.7747942097933083`*^9, 3.774795582694857*^9, + 3.774862966540056*^9, 3.7753178242947607`*^9, 3.7839336043199244`*^9}, + CellLabel-> + "During evaluation of \ +In[84]:=",ExpressionUUID->"2e2c0e96-81cd-4686-a8fb-6e8f22e38def"] +}, Open ]] +}, +WindowSize->{862, 669}, +WindowMargins->{{Automatic, 0}, {Automatic, 0}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 96, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 375, 6, 28, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1231, 37, 681, 13, 48, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[1927, 53, 253, 3, 32, "Output",ExpressionUUID->"1a41fbbe-4cae-413c-9835-7598e46f812a"], +Cell[2183, 58, 535, 11, 48, "Input",ExpressionUUID->"3942318d-c5ab-4bbb-b9f9-af1d93363738", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2721, 71, 270, 3, 32, "Output",ExpressionUUID->"6e065920-ee9c-4f29-ad85-37cfb9be7634"], +Cell[CellGroupData[{ +Cell[3016, 78, 299, 6, 28, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3318, 86, 697, 11, 67, "Section",ExpressionUUID->"579c246d-7234-4bbc-a83d-653b42f152d9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4018, 99, 578, 11, 56, "Text",ExpressionUUID->"bdc3e281-aa00-44be-ae84-967524ca58f1", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4599, 112, 2053, 42, 200, "Input",ExpressionUUID->"c12350b7-5012-4a2e-bec0-d7181fc31046", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6655, 156, 1224, 17, 32, "Output",ExpressionUUID->"565c5faf-895b-4afd-a9ec-6c5289b0951e", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7882, 175, 1289, 20, 32, "Output",ExpressionUUID->"de71617e-5329-4b4c-90a5-a75119ee28f7", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9174, 197, 1123, 21, 105, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10300, 220, 1641, 29, 86, "Input",ExpressionUUID->"84b1787a-183b-4920-a69d-4df94c20bba2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11944, 251, 487, 11, 67, "Input",ExpressionUUID->"0c74128b-2532-4223-a2a4-740b1043b57b", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12434, 264, 601, 12, 86, "Input",ExpressionUUID->"e5511e4a-3353-4719-a540-40dff57756df", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13038, 278, 2872, 54, 181, "Input",ExpressionUUID->"3cfb1a01-c132-42a5-9718-0d816c76266d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15913, 334, 259, 4, 28, "Input",ExpressionUUID->"2ac98d27-7834-4af5-8633-0d47fd58d28b", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16175, 340, 1021, 15, 52, "Output",ExpressionUUID->"b052cbd8-eb76-426e-934e-f2f7007b974a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[17199, 357, 241, 4, 28, "Input",ExpressionUUID->"15f971df-cb2f-4ac0-8bbd-ca375d983568", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[17443, 363, 6648, 98, 148, "Message",ExpressionUUID->"76ff43ed-3ee0-4554-a868-23fe63b7c7b4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[24094, 463, 1356, 22, 21, "Message",ExpressionUUID->"dfa857ec-dcfe-42a8-9bec-6439f25007b7", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[25453, 487, 1498, 24, 21, "Message",ExpressionUUID->"09d2bd23-7376-46e8-9475-096e75678d98", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26954, 513, 1356, 22, 21, "Message",ExpressionUUID->"6a5823bc-facd-4a54-bcfd-26e0fa38e28d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[28313, 537, 1496, 25, 21, "Message",ExpressionUUID->"ac828d08-81de-41ce-ada3-e69cfc0a22cf", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29812, 564, 1356, 22, 21, "Message",ExpressionUUID->"007fff6f-42a3-4aca-b643-f8f2aca075c0", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[31171, 588, 1428, 23, 21, "Message",ExpressionUUID->"c519699f-3054-42fd-b694-3a18e2e4fcff", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[32602, 613, 1498, 24, 21, "Message",ExpressionUUID->"38d286a5-2bd2-4211-92d5-4572295974f6", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[34103, 639, 1431, 23, 21, "Message",ExpressionUUID->"2e2c0e96-81cd-4686-a8fb-6e8f22e38def", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.svg new file mode 100644 index 0000000..18ccd87 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.svg @@ -0,0 +1,162 @@ + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.xml new file mode 100644 index 0000000..a0393ff --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision0.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision0.hpp new file mode 100644 index 0000000..7d939f7 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramDecision0.hpp @@ -0,0 +1,242 @@ +#ifndef ACTIVITYDIAGRAMDECISION_HPP_INCLUDED +#define ACTIVITYDIAGRAMDECISION_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" +su +//! +//! @file ActivityDiagramDecision.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Tue 20 Aug 2019 21:23:44 +//! @brief If selection for state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramDecision.nb*/ + +using namespace hopsan; + +class ActivityDiagramDecision : public ComponentQ +{ +private: + double diffevent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event2; + double event3; + //outputVariables + //InitialExpressions variables + double oldEvent2; + double oldEvent3; + //Expressions variables + double dEvent2; + double dEvent3; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent2; + double *mpevent3; + //inputParameters pointers + double *mpdiffevent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramDecision(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event2","trigger on positive \ +flank","",0.,&mpevent2); + addInputVariable("event3","trigger on positive \ +flank","",0.,&mpevent3); + + //Add inputParammeters to the component + addInputVariable("diffevent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffevent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event2 = (*mpevent2); + event3 = (*mpevent3); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent2 = event2; + oldEvent3 = event3; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event2 = (*mpevent2); + event3 = (*mpevent3); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //LocalExpressions + + //Expressions + dEvent2 = onPositive(-0.5 + event2 - diffevent*oldEvent2); + dEvent3 = onPositive(-0.5 + event3 - diffevent*oldEvent3); + + //Preventing creation of extra token + double qpn20 = dEvent2*onPositive(spn1 - spn2); + double qpn30 = dEvent3*onPositive(spn1 - spn3); + + qpn2 = 0; + qpn3 = 0; + qpn1 = 0; + + if(qpn20 > 0 || qpn30 > 0) { + bool successP1 = true; + //Try to lock P1 + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP1 = component->tryAndLockToken(); + } + } + } + //Try to lock P2 + if(qpn20 > 0) { + bool successP2 = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP2 = component->tryAndLockToken(); + } + } + } + //Try to lock P3 + if(qpn30 > 0) { + bool successP3 = true; + for(auto pPort : mpPpn3->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successP3 = component->tryAndLockToken(); + } + } + } + if(qpn20 > 0 || qpn30 > 0) { + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successP1 && successP2) { + addDebugMessage("Locked tokens!"); + qpn2 = dEvent2*onPositive(spn1 - spn2); + } + if(successP1 && successP3) { + qpn3 = dEvent3*(1 - qpn2)*onPositive(spn1 - spn3); + } + } + qpn1 = -onPositive(-0.5 + qpn2 + qpn3); + oldEvent2 = event2; + oldEvent3 = event3; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMDECISION_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.hpp new file mode 100644 index 0000000..5317f42 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.hpp @@ -0,0 +1,198 @@ +#ifndef ACTIVITYDIAGRAMEDGE_HPP_INCLUDED +#define ACTIVITYDIAGRAMEDGE_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" +#include "ActivityDiagramActionN.hpp" + +//! +//! @file ActivityDiagramEdge.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Tue 20 Aug 2019 21:24:55 +//! @brief Edge for an activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramEdge.nb*/ + +using namespace hopsan; + +class ActivityDiagramEdge : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //InitialExpressions variables + double oldEvent; + //Expressions variables + double dEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramEdge(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event ","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent = event; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + + qpn1 = 0; + qpn2 = 0; + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + double drop = onPositive(-0.5 + spn1 - spn2); + if(dEvent > 0 && drop > 0) { + bool successUpstream = true; + + //Try to lock upstream component + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successUpstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + bool successDownstream = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successUpstream && successDownstream) { + addDebugMessage("Locked tokens!"); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2); + qpn1 = -qpn2; + oldEvent = event; + } + } + /*dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2); + qpn1 = -qpn2; + oldEvent = event; + */ + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMEDGE_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.nb new file mode 100644 index 0000000..6008888 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.nb @@ -0,0 +1,738 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 36438, 730] +NotebookOptionsPosition[ 31015, 645] +NotebookOutlinePosition[ 31464, 662] +CellTagsIndexPosition[ 31421, 659] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel-> + "In[173]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + CellLabel-> + "In[174]:=",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774783255827202*^9, 3.77478337001744*^9, 3.7747834405341005`*^9, + 3.7747836576080275`*^9, 3.774861331994948*^9, 3.7748618822356014`*^9, + 3.7748621289924507`*^9, 3.774862177272443*^9, 3.774862425181608*^9, + 3.774862534726026*^9, 3.7749719114527235`*^9, 3.7753178949346876`*^9, + 3.7801333266116037`*^9, 3.7801333972788267`*^9, 3.780133535984686*^9, + 3.780138923762919*^9}, + CellLabel-> + "Out[174]=",ExpressionUUID->"41b6d10f-eb1f-42fc-b6bb-31ec244a24c1"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774862167050089*^9, + 3.7748621744482594`*^9}, {3.78013338480538*^9, 3.7801333924801435`*^9}}, + CellLabel-> + "In[175]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.780133536031561*^9, {3.7801389238738537`*^9, 3.780138935305006*^9}}, + CellLabel-> + "Out[175]=",ExpressionUUID->"a1b9bb32-6195-476c-b7f3-fb1c02975d8f"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774862167050089*^9, + 3.7748621744482594`*^9}, {3.78013338480538*^9, 3.7801333924801435`*^9}, { + 3.7801334766887417`*^9, 3.7801335198101406`*^9}}, + CellLabel-> + "In[176]:=",ExpressionUUID->"905ab55a-157b-4a3f-b596-c07eca02fa80"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.77478325586716*^9, 3.7747833700573997`*^9, 3.7747834405750585`*^9, + 3.7747836576489954`*^9, 3.774861332027913*^9, 3.77486188227656*^9, + 3.774862129112327*^9, 3.774862177338374*^9, 3.774862425247543*^9, + 3.7748625347922373`*^9, 3.774971911554619*^9, 3.775317894973647*^9, + 3.7801333266584554`*^9, 3.7801333973413134`*^9, 3.780133536078429*^9, + 3.7801336300384307`*^9, 3.7801389239780316`*^9}, + CellLabel-> + "Out[176]=",ExpressionUUID->"09d1c84f-fdf0-48f5-a63e-fdfae7ab79c7"] +}, Open ]], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input",ExpressionUUID->\ +"1c2c481e-8769-41af-8c25-4f851ecbcfa6"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel-> + "In[196]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Edge", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, {3.7552810847024717`*^9, + 3.755281085195962*^9}, 3.7627280783257494`*^9, {3.774780997626498*^9, + 3.774781001216793*^9}, {3.774861337479744*^9, + 3.774861338502689*^9}},ExpressionUUID->"4d153d9c-7b28-4465-9655-\ +a48708ad9847"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1 and qpn2, are either 0 or \ +1 in one time step. The state variables spn1 and spn2 are either 0 or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940389271574`*^9}, + 3.774861328529005*^9},ExpressionUUID->"bdc3e281-aa00-44be-ae84-\ +967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, 3.755104234091298*^9, { + 3.7552809979509115`*^9, 3.755281001260498*^9}, 3.7627280783277693`*^9, { + 3.765539427990275*^9, 3.7655394340028424`*^9}, {3.774781006008152*^9, + 3.77478102110835*^9}, 3.7749717143792067`*^9}, + CellLabel-> + "In[197]:=",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.755102980704762*^9, 3.755103206917535*^9, + 3.755103467021369*^9, 3.755103744959814*^9, 3.755104180451824*^9, + 3.755104239812397*^9, 3.755104643157222*^9, 3.7551048029644623`*^9, + 3.7551050670431967`*^9, 3.7552831734030194`*^9, 3.755283206272132*^9, + 3.755325283129212*^9, 3.755333721998741*^9, {3.7626812975948114`*^9, + 3.7626813135454216`*^9}, 3.7626839962814198`*^9, 3.7626948109174385`*^9, + 3.762727532339548*^9, 3.76272799501862*^9, {3.762728078328746*^9, + 3.7627280824895782`*^9}, 3.7627282320170755`*^9, 3.7747824644163404`*^9, { + 3.774782702399314*^9, 3.774782723832418*^9}, 3.7747832559450808`*^9, + 3.7747833701363187`*^9, 3.774783440656974*^9, 3.7747836577249107`*^9, + 3.7748613320898495`*^9, 3.774861882352481*^9, 3.774862129236199*^9, + 3.774862177464244*^9, 3.7748624253883953`*^9, 3.774862534921103*^9, + 3.774971911774392*^9, 3.775317895053565*^9, 3.7801333267053275`*^9, + 3.7801333974350605`*^9, 3.7801335361721935`*^9, 3.7801336301790466`*^9, + 3.780138924161188*^9, 3.7801983350044546`*^9}, + CellLabel-> + "Out[202]=",ExpressionUUID->"33131d1b-ab8a-4cac-a44d-bf18ed4611b5"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "10", ",", "16", ",", "9", ",", "5", ",", + "34.9215023`9.29566781492157"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.755102980704762*^9, 3.755103206917535*^9, + 3.755103467021369*^9, 3.755103744959814*^9, 3.755104180451824*^9, + 3.755104239812397*^9, 3.755104643157222*^9, 3.7551048029644623`*^9, + 3.7551050670431967`*^9, 3.7552831734030194`*^9, 3.755283206272132*^9, + 3.755325283129212*^9, 3.755333721998741*^9, {3.7626812975948114`*^9, + 3.7626813135454216`*^9}, 3.7626839962814198`*^9, 3.7626948109174385`*^9, + 3.762727532339548*^9, 3.76272799501862*^9, {3.762728078328746*^9, + 3.7627280824895782`*^9}, 3.7627282320170755`*^9, 3.7747824644163404`*^9, { + 3.774782702399314*^9, 3.774782723832418*^9}, 3.7747832559450808`*^9, + 3.7747833701363187`*^9, 3.774783440656974*^9, 3.7747836577249107`*^9, + 3.7748613320898495`*^9, 3.774861882352481*^9, 3.774862129236199*^9, + 3.774862177464244*^9, 3.7748624253883953`*^9, 3.774862534921103*^9, + 3.774971911774392*^9, 3.775317895053565*^9, 3.7801333267053275`*^9, + 3.7801333974350605`*^9, 3.7801335361721935`*^9, 3.7801336301790466`*^9, + 3.780138924161188*^9, 3.7801983350214443`*^9}, + CellLabel-> + "Out[206]=",ExpressionUUID->"6fe22629-0e4a-4ca6-9b93-b47959b6108d"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774862525590169*^9, 3.774862531989335*^9}}, + CellLabel-> + "In[207]:=",ExpressionUUID->"5a00746f-0f22-470a-9d0a-8fed6680bf1a"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}}, + CellLabel-> + "In[208]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272249647017`*^9, + 3.7627272292986608`*^9}, {3.762727490874993*^9, 3.7627274959520893`*^9}, + 3.762728078328746*^9, 3.7749719792395124`*^9, 3.7749721713009176`*^9}, + CellLabel-> + "In[209]:=",ExpressionUUID->"4c62bcfb-2008-4beb-8d2e-de8e629ef869"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffEvent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9}, + CellLabel-> + "In[210]:=",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell["\<\ +outputVariables = { + {dEvent, 0., double, \"\", \"state\"} + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7551047565263386`*^9, 3.755104782637418*^9}, + 3.7627280783297443`*^9, 3.7749718981811323`*^9, + 3.7749722246227536`*^9},ExpressionUUID->"5cd89914-7e59-4f48-aa45-\ +f858f9817189"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", + RowBox[{"oldEvent", "\[Equal]", "event"}], "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.774783253698371*^9, 3.774971906112005*^9}, + CellLabel-> + "In[211]:=",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "-", + RowBox[{"diffEvent", "*", "oldEvent"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn2", "\[Equal]", + RowBox[{"dEvent", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn2", "-", "0.5"}], "]"}]}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{"-", "qpn2"}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent", "==", "event"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.755102685300324*^9, 3.755102766693407*^9}, { + 3.755102825716555*^9, 3.7551028290051646`*^9}, {3.755103181905323*^9, + 3.7551031851929345`*^9}, 3.7551032435287895`*^9, {3.755103273801578*^9, + 3.755103299120475*^9}, {3.755103426839797*^9, 3.7551034356007643`*^9}, + 3.7551046204816017`*^9, {3.755105052892784*^9, 3.755105055124485*^9}, { + 3.7553336858300333`*^9, 3.755333687215604*^9}, {3.7626839650251155`*^9, + 3.7626839663531804`*^9}, {3.762694751924573*^9, 3.762694784726457*^9}, { + 3.7627273054720736`*^9, 3.762727306901246*^9}, 3.7627280783307447`*^9, { + 3.765539448591514*^9, 3.765539455630495*^9}, {3.765539601496279*^9, + 3.7655396192698975`*^9}, {3.774782361437813*^9, 3.7747824158143415`*^9}, { + 3.7749717974514837`*^9, 3.7749718286721725`*^9}, {3.774971859745027*^9, + 3.774971861376067*^9}, {3.7749719534754014`*^9, 3.7749719690395927`*^9}, { + 3.7749721374450293`*^9, 3.7749721396166024`*^9}, 3.774972219213808*^9}, + CellLabel-> + "In[212]:=",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7627280783307447`*^9}, + CellLabel-> + "In[213]:=",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\"}\ +\\\"}], \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramEdge.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramEdge.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.3333333333333333`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,213, + 57,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"8732e0a2-659b-454b-bff4-2030224e2a79"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,213,58,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356926794`*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"02debe8f-7004-4b0d-ba2b-2d634a94fa1c"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.3333333333333333`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.3333333333333333`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,213,59, + 18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.780198335706673*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"01d612bd-1b5e-40c3-9e7f-1018d5ccda57"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,213,60,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983358348913`*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"b6754e3e-9a07-4d19-99d7-5d70fb2d6d47"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.6666666666666666`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.6666666666666666`\\\"}]\\) is not a valid value for an attribute in an \ +XMLElement. The value of the attribute must be a string.\"",2,213,61, + 18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983358528805`*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"cbad5e3b-f413-4255-ade7-74705d0fcdd4"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,213,62,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.78019833587187*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"90d0c9b6-6da3-43be-b93f-04f4fb02ab14"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,213,63,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.780198335993745*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"35702088-2e28-41b0-8b9c-9fe87b2cce5a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,213,64,18988733202671857145, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.780198336013734*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"e4cd8ac0-3768-4278-9fe8-02599fa885be"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,213,65,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983360287256`*^9}, + CellLabel-> + "During evaluation of \ +In[213]:=",ExpressionUUID->"f260d863-f1f2-429b-90e4-70a29b891958"], + +Cell[BoxData["file"], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7747825883063197`*^9, 3.7747825891164837`*^9}, + 3.774783253702371*^9}, + CellLabel-> + "In[214]:=",ExpressionUUID->"770bb82f-29c3-4ec0-a654-9470b7b070e9"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\ActivityDiagramEdge.\ +hpp\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7747825901683993`*^9, 3.774782739100483*^9, {3.7747832537033706`*^9, + 3.7747832566588507`*^9}, 3.774861883267045*^9, 3.774862130263647*^9, + 3.7748621784503984`*^9, 3.774862426377384*^9, 3.7748625360815115`*^9, + 3.774971913145977*^9, 3.775317895668929*^9, 3.780133327361533*^9, + 3.780133398013132*^9, 3.7801335371869555`*^9, 3.7801336308257523`*^9, + 3.780138926395756*^9, 3.780198336277796*^9}, + CellLabel-> + "Out[214]=",ExpressionUUID->"a4ab34ec-1c38-4f88-a70f-f0ebdba78222"] +}, Open ]] +}, +WindowSize->{932, 632}, +WindowMargins->{{0, Automatic}, {Automatic, 22}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +Magnification:>1.1 Inherited, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 107, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 379, 7, 32, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1235, 38, 1235, 22, 55, "Input",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2473, 62, 899, 14, 36, "Output",ExpressionUUID->"41b6d10f-eb1f-42fc-b6bb-31ec244a24c1", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3375, 78, 766, 15, 55, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4144, 95, 378, 6, 36, "Output",ExpressionUUID->"a1b9bb32-6195-476c-b7f3-fb1c02975d8f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4525, 103, 837, 16, 55, "Input",ExpressionUUID->"905ab55a-157b-4a3f-b596-c07eca02fa80", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5365, 121, 938, 14, 36, "Output",ExpressionUUID->"09d1c84f-fdf0-48f5-a63e-fdfae7ab79c7", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[6318, 138, 414, 9, 55, "Input",ExpressionUUID->"1c2c481e-8769-41af-8c25-4f851ecbcfa6"], +Cell[CellGroupData[{ +Cell[6757, 151, 303, 7, 32, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7063, 160, 483, 8, 73, "Section",ExpressionUUID->"4d153d9c-7b28-4465-9655-a48708ad9847", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7549, 170, 565, 10, 65, "Text",ExpressionUUID->"bdc3e281-aa00-44be-ae84-967524ca58f1", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8117, 182, 1787, 39, 231, "Input",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9907, 223, 1370, 20, 36, "Output",ExpressionUUID->"33131d1b-ab8a-4cac-a44d-bf18ed4611b5", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11280, 245, 1434, 23, 36, "Output",ExpressionUUID->"6fe22629-0e4a-4ca6-9b93-b47959b6108d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12717, 270, 271, 6, 32, "Input",ExpressionUUID->"5a00746f-0f22-470a-9d0a-8fed6680bf1a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12991, 278, 875, 18, 99, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13869, 298, 908, 18, 77, "Input",ExpressionUUID->"4c62bcfb-2008-4beb-8d2e-de8e629ef869", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14780, 318, 887, 17, 77, "Input",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15670, 337, 350, 9, 90, "Text",ExpressionUUID->"5cd89914-7e59-4f48-aa45-f858f9817189", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16023, 348, 353, 8, 32, "Input",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16379, 358, 2239, 40, 143, "Input",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[18621, 400, 245, 5, 32, "Input",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[18869, 407, 3291, 51, 81, "Message",ExpressionUUID->"8732e0a2-659b-454b-bff4-2030224e2a79", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[22163, 460, 897, 17, 23, "Message",ExpressionUUID->"02debe8f-7004-4b0d-ba2b-2d634a94fa1c", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[23063, 479, 1067, 20, 23, "Message",ExpressionUUID->"01d612bd-1b5e-40c3-9e7f-1018d5ccda57", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[24133, 501, 897, 17, 23, "Message",ExpressionUUID->"b6754e3e-9a07-4d19-99d7-5d70fb2d6d47", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[25033, 520, 1069, 20, 23, "Message",ExpressionUUID->"cbad5e3b-f413-4255-ade7-74705d0fcdd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26105, 542, 894, 17, 23, "Message",ExpressionUUID->"90d0c9b6-6da3-43be-b93f-04f4fb02ab14", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27002, 561, 967, 18, 23, "Message",ExpressionUUID->"35702088-2e28-41b0-8b9c-9fe87b2cce5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27972, 581, 1037, 20, 23, "Message",ExpressionUUID->"e4cd8ac0-3768-4278-9fe8-02599fa885be", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29012, 603, 972, 18, 23, "Message",ExpressionUUID->"f260d863-f1f2-429b-90e4-70a29b891958", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29987, 623, 264, 5, 32, "Input",ExpressionUUID->"770bb82f-29c3-4ec0-a654-9470b7b070e9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[30254, 630, 745, 12, 59, "Output",ExpressionUUID->"a4ab34ec-1c38-4f88-a70f-f0ebdba78222", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.svg new file mode 100644 index 0000000..3e55820 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.svg @@ -0,0 +1,136 @@ + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.xml new file mode 100644 index 0000000..847a25e --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge01.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge01.hpp new file mode 100644 index 0000000..01f3c4e --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge01.hpp @@ -0,0 +1,164 @@ +#ifndef ACTIVITYDIAGRAMEDGE_HPP_INCLUDED +#define ACTIVITYDIAGRAMEDGE_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramEdge.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Tue 20 Aug 2019 21:24:55 +//! @brief Edge for an activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramEdge.nb*/ + +using namespace hopsan; + +class ActivityDiagramEdge : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //InitialExpressions variables + double oldEvent; + //Expressions variables + double dEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramEdge(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event ","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent = event; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2); + qpn1 = -qpn2; + oldEvent = event; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMEDGE_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge1.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge1.hpp new file mode 100644 index 0000000..5317f42 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramEdge1.hpp @@ -0,0 +1,198 @@ +#ifndef ACTIVITYDIAGRAMEDGE_HPP_INCLUDED +#define ACTIVITYDIAGRAMEDGE_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" +#include "ActivityDiagramActionN.hpp" + +//! +//! @file ActivityDiagramEdge.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Tue 20 Aug 2019 21:24:55 +//! @brief Edge for an activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramEdge.nb*/ + +using namespace hopsan; + +class ActivityDiagramEdge : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //InitialExpressions variables + double oldEvent; + //Expressions variables + double dEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramEdge(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event ","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent = event; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + + qpn1 = 0; + qpn2 = 0; + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + double drop = onPositive(-0.5 + spn1 - spn2); + if(dEvent > 0 && drop > 0) { + bool successUpstream = true; + + //Try to lock upstream component + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successUpstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + bool successDownstream = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successUpstream && successDownstream) { + addDebugMessage("Locked tokens!"); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2); + qpn1 = -qpn2; + oldEvent = event; + } + } + /*dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2); + qpn1 = -qpn2; + oldEvent = event; + */ + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMEDGE_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.hpp new file mode 100644 index 0000000..d4a61dd --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.hpp @@ -0,0 +1,145 @@ +#ifndef ACTIVITYDIAGRAMFINAL_HPP_INCLUDED +#define ACTIVITYDIAGRAMFINAL_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramFinal.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Wed 27 Nov 2019 13:11:18 +//! @brief Edge for an activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramFinal.nb*/ + +using namespace hopsan; + +class ActivityDiagramFinal : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //InitialExpressions variables + double oldEvent; + //Expressions variables + double dEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramFinal(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event ","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent = event; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + qpn1 = -(dEvent*onPositive(-0.5 + spn1)); + oldEvent = event; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMFINAL_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.nb new file mode 100644 index 0000000..f799bdc --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.nb @@ -0,0 +1,720 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 37398, 712] +NotebookOptionsPosition[ 32152, 628] +NotebookOutlinePosition[ 32601, 645] +CellTagsIndexPosition[ 32558, 642] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel->"In[40]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + CellLabel->"In[41]:=",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774783255827202*^9, 3.77478337001744*^9, 3.7747834405341005`*^9, + 3.7747836576080275`*^9, 3.774861331994948*^9, 3.7748618822356014`*^9, + 3.7748621289924507`*^9, 3.774862177272443*^9, 3.774862425181608*^9, + 3.774862534726026*^9, 3.7749719114527235`*^9, 3.7753178949346876`*^9, + 3.7801333266116037`*^9, 3.7801333972788267`*^9, 3.780133535984686*^9, + 3.780138923762919*^9, 3.7838454778730965`*^9}, + CellLabel->"Out[41]=",ExpressionUUID->"9481c4a3-b720-4420-9178-375a5b5b9d77"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774862167050089*^9, + 3.7748621744482594`*^9}, {3.78013338480538*^9, 3.7801333924801435`*^9}}, + CellLabel->"In[42]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.780133536031561*^9, {3.7801389238738537`*^9, 3.780138935305006*^9}, + 3.7838454779706993`*^9}, + CellLabel->"Out[42]=",ExpressionUUID->"79cf065a-53f8-4561-84fd-8552a12c3e0b"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774862167050089*^9, + 3.7748621744482594`*^9}, {3.78013338480538*^9, 3.7801333924801435`*^9}, { + 3.7801334766887417`*^9, 3.7801335198101406`*^9}}, + CellLabel->"In[43]:=",ExpressionUUID->"905ab55a-157b-4a3f-b596-c07eca02fa80"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.77478325586716*^9, 3.7747833700573997`*^9, 3.7747834405750585`*^9, + 3.7747836576489954`*^9, 3.774861332027913*^9, 3.77486188227656*^9, + 3.774862129112327*^9, 3.774862177338374*^9, 3.774862425247543*^9, + 3.7748625347922373`*^9, 3.774971911554619*^9, 3.775317894973647*^9, + 3.7801333266584554`*^9, 3.7801333973413134`*^9, 3.780133536078429*^9, + 3.7801336300384307`*^9, 3.7801389239780316`*^9, 3.7838454780727134`*^9}, + CellLabel->"Out[43]=",ExpressionUUID->"655686d1-447e-420b-96c9-7c10296eef74"] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellLabel->"In[44]:=",ExpressionUUID->"1c2c481e-8769-41af-8c25-4f851ecbcfa6"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellChangeTimes->{3.7838454781824636`*^9}, + CellLabel->"Out[44]=",ExpressionUUID->"9c93e848-e40a-4650-be87-7c26eed711c6"] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel->"In[45]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Final", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, {3.7552810847024717`*^9, + 3.755281085195962*^9}, 3.7627280783257494`*^9, {3.774780997626498*^9, + 3.774781001216793*^9}, {3.774861337479744*^9, 3.774861338502689*^9}, { + 3.7838454562700553`*^9, + 3.78384545691061*^9}},ExpressionUUID->"4d153d9c-7b28-4465-9655-\ +a48708ad9847"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1 and qpn2, are either 0 or \ +1 in one time step. The state variables spn1 and spn2 are either 0 or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940389271574`*^9}, + 3.774861328529005*^9},ExpressionUUID->"bdc3e281-aa00-44be-ae84-\ +967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, 3.755104234091298*^9, { + 3.7552809979509115`*^9, 3.755281001260498*^9}, 3.7627280783277693`*^9, { + 3.765539427990275*^9, 3.7655394340028424`*^9}, {3.774781006008152*^9, + 3.77478102110835*^9}, 3.7749717143792067`*^9, {3.783845452706601*^9, + 3.7838454535346675`*^9}}, + CellLabel->"In[46]:=",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.755102980704762*^9, 3.755103206917535*^9, + 3.755103467021369*^9, 3.755103744959814*^9, 3.755104180451824*^9, + 3.755104239812397*^9, 3.755104643157222*^9, 3.7551048029644623`*^9, + 3.7551050670431967`*^9, 3.7552831734030194`*^9, 3.755283206272132*^9, + 3.755325283129212*^9, 3.755333721998741*^9, {3.7626812975948114`*^9, + 3.7626813135454216`*^9}, 3.7626839962814198`*^9, 3.7626948109174385`*^9, + 3.762727532339548*^9, 3.76272799501862*^9, {3.762728078328746*^9, + 3.7627280824895782`*^9}, 3.7627282320170755`*^9, 3.7747824644163404`*^9, { + 3.774782702399314*^9, 3.774782723832418*^9}, 3.7747832559450808`*^9, + 3.7747833701363187`*^9, 3.774783440656974*^9, 3.7747836577249107`*^9, + 3.7748613320898495`*^9, 3.774861882352481*^9, 3.774862129236199*^9, + 3.774862177464244*^9, 3.7748624253883953`*^9, 3.774862534921103*^9, + 3.774971911774392*^9, 3.775317895053565*^9, 3.7801333267053275`*^9, + 3.7801333974350605`*^9, 3.7801335361721935`*^9, 3.7801336301790466`*^9, + 3.780138924161188*^9, 3.7801983350044546`*^9, 3.783845478355116*^9}, + CellLabel->"Out[51]=",ExpressionUUID->"6ab0dc44-d9d9-4bf2-8dec-b26398bff11d"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "11", ",", "27", ",", "13", ",", "11", ",", + "18.2740075`9.014408738882913"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.755102980704762*^9, 3.755103206917535*^9, + 3.755103467021369*^9, 3.755103744959814*^9, 3.755104180451824*^9, + 3.755104239812397*^9, 3.755104643157222*^9, 3.7551048029644623`*^9, + 3.7551050670431967`*^9, 3.7552831734030194`*^9, 3.755283206272132*^9, + 3.755325283129212*^9, 3.755333721998741*^9, {3.7626812975948114`*^9, + 3.7626813135454216`*^9}, 3.7626839962814198`*^9, 3.7626948109174385`*^9, + 3.762727532339548*^9, 3.76272799501862*^9, {3.762728078328746*^9, + 3.7627280824895782`*^9}, 3.7627282320170755`*^9, 3.7747824644163404`*^9, { + 3.774782702399314*^9, 3.774782723832418*^9}, 3.7747832559450808`*^9, + 3.7747833701363187`*^9, 3.774783440656974*^9, 3.7747836577249107`*^9, + 3.7748613320898495`*^9, 3.774861882352481*^9, 3.774862129236199*^9, + 3.774862177464244*^9, 3.7748624253883953`*^9, 3.774862534921103*^9, + 3.774971911774392*^9, 3.775317895053565*^9, 3.7801333267053275`*^9, + 3.7801333974350605`*^9, 3.7801335361721935`*^9, 3.7801336301790466`*^9, + 3.780138924161188*^9, 3.7801983350044546`*^9, 3.783845478360263*^9}, + CellLabel->"Out[55]=",ExpressionUUID->"467ab447-a7e9-486f-a74f-7c09f677e688"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.774862525590169*^9, 3.774862531989335*^9}}, + CellLabel->"In[56]:=",ExpressionUUID->"5a00746f-0f22-470a-9d0a-8fed6680bf1a"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, 3.783845382014352*^9}, + CellLabel->"In[57]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272249647017`*^9, + 3.7627272292986608`*^9}, {3.762727490874993*^9, 3.7627274959520893`*^9}, + 3.762728078328746*^9, 3.7749719792395124`*^9, 3.7749721713009176`*^9}, + CellLabel->"In[58]:=",ExpressionUUID->"4c62bcfb-2008-4beb-8d2e-de8e629ef869"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffEvent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9}, + CellLabel->"In[59]:=",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell["\<\ +outputVariables = { + {dEvent, 0., double, \"\", \"state\"} + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7551047565263386`*^9, 3.755104782637418*^9}, + 3.7627280783297443`*^9, 3.7749718981811323`*^9, + 3.7749722246227536`*^9},ExpressionUUID->"5cd89914-7e59-4f48-aa45-\ +f858f9817189"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", + RowBox[{"oldEvent", "\[Equal]", "event"}], "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.774783253698371*^9, 3.774971906112005*^9}, + CellLabel->"In[60]:=",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "-", + RowBox[{"diffEvent", "*", "oldEvent"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn1", "\[Equal]", + RowBox[{ + RowBox[{"-", "dEvent"}], " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "0.5"}], "]"}]}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent", "==", "event"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.755102685300324*^9, 3.755102766693407*^9}, { + 3.755102825716555*^9, 3.7551028290051646`*^9}, {3.755103181905323*^9, + 3.7551031851929345`*^9}, 3.7551032435287895`*^9, {3.755103273801578*^9, + 3.755103299120475*^9}, {3.755103426839797*^9, 3.7551034356007643`*^9}, + 3.7551046204816017`*^9, {3.755105052892784*^9, 3.755105055124485*^9}, { + 3.7553336858300333`*^9, 3.755333687215604*^9}, {3.7626839650251155`*^9, + 3.7626839663531804`*^9}, {3.762694751924573*^9, 3.762694784726457*^9}, { + 3.7627273054720736`*^9, 3.762727306901246*^9}, 3.7627280783307447`*^9, { + 3.765539448591514*^9, 3.765539455630495*^9}, {3.765539601496279*^9, + 3.7655396192698975`*^9}, {3.774782361437813*^9, 3.7747824158143415`*^9}, { + 3.7749717974514837`*^9, 3.7749718286721725`*^9}, {3.774971859745027*^9, + 3.774971861376067*^9}, {3.7749719534754014`*^9, 3.7749719690395927`*^9}, { + 3.7749721374450293`*^9, 3.7749721396166024`*^9}, 3.774972219213808*^9, { + 3.783845393127009*^9, 3.7838454104907365`*^9}}, + CellLabel->"In[61]:=",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7627280783307447`*^9}, + CellLabel->"In[62]:=",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramFinal\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramFinal\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramFinal.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramFinal.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"\\\\\\\"\\\"}], \\\"\[Rule]\\\", \ +RowBox[{\\\"\\\\\\\"\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"\\\\\\\"\\\ +\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramFinal\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +RowBox[{\\\"\\\\\\\"A\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"l\\\\\\\"\ +\\\"}]}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramFinal.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramFinal.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,62, + 24,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.783845478774294*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"6c1119dc-e6bb-40f8-a20f-ccfcfb83f0d3"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,62,25,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.783845478833149*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"0eaa707d-26f0-4a7c-96b1-89a31d97e6a7"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,62,26,19014042857157888424, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.7838454789400873`*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"5af0e64f-7c85-478b-a17f-c62c9b266900"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,62,27,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.78384547895208*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"6921ccfe-9bcf-434a-b351-8a2b31c78d8a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,62,28,19014042857157888424, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.7838454789620743`*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"d9dbb1bc-113d-4df6-9760-86f3cc30cc20"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,62,29,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.7838454789750695`*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"8ed11c0e-d59b-43a0-9c0b-039b625147d9"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,62,30,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.762728082979766*^9, 3.7627282323828444`*^9, 3.774782724576651*^9, { + 3.774783253698371*^9, 3.774783256363648*^9}, 3.7747834410225973`*^9, + 3.7748613323535776`*^9, 3.774861882718104*^9, 3.774862129745673*^9, + 3.7748621780067387`*^9, 3.774862425975794*^9, 3.774862535638364*^9, + 3.774971912811322*^9, 3.7753178953872194`*^9, 3.7801333269240627`*^9, + 3.7801333976069274`*^9, 3.780133536495208*^9, 3.7801336304354353`*^9, + 3.780138924911724*^9, 3.7801983356507044`*^9, 3.783845478995056*^9}, + CellLabel-> + "During evaluation of \ +In[62]:=",ExpressionUUID->"fddeb781-05f2-42e4-b52b-eaa3452b750f"], + +Cell[BoxData["file"], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7747825883063197`*^9, 3.7747825891164837`*^9}, + 3.774783253702371*^9}, + CellLabel->"In[63]:=",ExpressionUUID->"770bb82f-29c3-4ec0-a654-9470b7b070e9"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\ActivityDiagramFinal.\ +hpp\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7747825901683993`*^9, 3.774782739100483*^9, {3.7747832537033706`*^9, + 3.7747832566588507`*^9}, 3.774861883267045*^9, 3.774862130263647*^9, + 3.7748621784503984`*^9, 3.774862426377384*^9, 3.7748625360815115`*^9, + 3.774971913145977*^9, 3.775317895668929*^9, 3.780133327361533*^9, + 3.780133398013132*^9, 3.7801335371869555`*^9, 3.7801336308257523`*^9, + 3.780138926395756*^9, 3.780198336277796*^9, 3.783845479208876*^9}, + CellLabel->"Out[63]=",ExpressionUUID->"9396a593-309c-4be1-ac56-09d14badbbdd"] +}, Open ]] +}, +WindowSize->{1008, 709}, +WindowMargins->{{0, Automatic}, {Automatic, 0}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +Magnification:>1.1 Inherited, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 107, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 375, 6, 32, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1231, 37, 1231, 21, 32, "Input",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2465, 60, 919, 13, 36, "Output",ExpressionUUID->"9481c4a3-b720-4420-9178-375a5b5b9d77", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3387, 75, 762, 14, 55, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4152, 91, 402, 6, 36, "Output",ExpressionUUID->"79cf065a-53f8-4561-84fd-8552a12c3e0b", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4557, 99, 833, 15, 55, "Input",ExpressionUUID->"905ab55a-157b-4a3f-b596-c07eca02fa80", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5393, 116, 958, 13, 36, "Output",ExpressionUUID->"655686d1-447e-420b-96c9-7c10296eef74", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[CellGroupData[{ +Cell[6388, 134, 436, 9, 55, "Input",ExpressionUUID->"1c2c481e-8769-41af-8c25-4f851ecbcfa6"], +Cell[6827, 145, 272, 3, 36, "Output",ExpressionUUID->"9c93e848-e40a-4650-be87-7c26eed711c6"] +}, Open ]], +Cell[CellGroupData[{ +Cell[7136, 153, 299, 6, 32, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7438, 161, 535, 9, 73, "Section",ExpressionUUID->"4d153d9c-7b28-4465-9655-a48708ad9847", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7976, 172, 565, 10, 65, "Text",ExpressionUUID->"bdc3e281-aa00-44be-ae84-967524ca58f1", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8544, 184, 1836, 39, 231, "Input",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10383, 225, 1388, 19, 36, "Output",ExpressionUUID->"6ab0dc44-d9d9-4bf2-8dec-b26398bff11d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11774, 246, 1455, 22, 36, "Output",ExpressionUUID->"467ab447-a7e9-486f-a74f-7c09f677e688", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13232, 270, 267, 5, 32, "Input",ExpressionUUID->"5a00746f-0f22-470a-9d0a-8fed6680bf1a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13502, 277, 726, 13, 77, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14231, 292, 904, 17, 77, "Input",ExpressionUUID->"4c62bcfb-2008-4beb-8d2e-de8e629ef869", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15138, 311, 883, 16, 77, "Input",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16024, 329, 350, 9, 90, "Text",ExpressionUUID->"5cd89914-7e59-4f48-aa45-f858f9817189", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16377, 340, 349, 7, 32, "Input",ExpressionUUID->"6c284b1c-2e66-492e-90e5-21e73aaf28a9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16729, 349, 2203, 38, 121, "Input",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[18935, 389, 241, 4, 32, "Input",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[19179, 395, 6046, 90, 119, "Message",ExpressionUUID->"6c1119dc-e6bb-40f8-a20f-ccfcfb83f0d3", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[25228, 487, 917, 17, 23, "Message",ExpressionUUID->"0eaa707d-26f0-4a7c-96b1-89a31d97e6a7", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26148, 506, 1061, 20, 23, "Message",ExpressionUUID->"5af0e64f-7c85-478b-a17f-c62c9b266900", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27212, 528, 916, 17, 23, "Message",ExpressionUUID->"6921ccfe-9bcf-434a-b351-8a2b31c78d8a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[28131, 547, 1061, 20, 23, "Message",ExpressionUUID->"d9dbb1bc-113d-4df6-9760-86f3cc30cc20", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29195, 569, 919, 17, 23, "Message",ExpressionUUID->"8ed11c0e-d59b-43a0-9c0b-039b625147d9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[30117, 588, 989, 18, 23, "Message",ExpressionUUID->"fddeb781-05f2-42e4-b52b-eaa3452b750f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[31109, 608, 260, 4, 32, "Input",ExpressionUUID->"770bb82f-29c3-4ec0-a654-9470b7b070e9", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[31372, 614, 764, 11, 36, "Output",ExpressionUUID->"9396a593-309c-4be1-ac56-09d14badbbdd", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.svg new file mode 100644 index 0000000..c498595 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.svg @@ -0,0 +1,218 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.xml new file mode 100644 index 0000000..0fe7488 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal.xml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal0.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal0.hpp new file mode 100644 index 0000000..71bbcb1 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinal0.hpp @@ -0,0 +1,127 @@ +/*----------------------------------------------------------------------------- + This source file is a part of Hopsan + + Copyright (c) 2009 to present year, Hopsan Group + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramFinal.hpp +//! @author Petter Krus +//! @date 2018-12-31 +//! based on ElectricCapacitanceMultiPort.hpp by Björn Eriksson +//! @brief Contains a Electric Volume Component +//! + +#ifndef ACTIVITYDIAGRAMFINAL_HPP_INCLUDED +#define ACTIVITYDIAGRAMFINAL_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A ActivityDiagram final state component + //! @ingroup ActivityDiagram + //! + class ActivityDiagramFinal : public ComponentC + { + + private: + double state; + double *mpAlpha; + double *mpstate; +// double capacitance; + + std::vector mvpN_s; + std::vector mvp_S0; + size_t mNumPorts; + Port *mpPpn1; + + public: + static Component *Creator() + { + return new ActivityDiagramFinal(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); + addInputVariable("alpha", "Low pass coeficient to dampen standing delayline waves", "-", 0.3, &mpAlpha); + addOutputVariable("state","State activated","",0.,&mpstate); + } + + + void initialize() + { + double alpha; + double state; + alpha = (*mpAlpha); + + mNumPorts = mpPpn1->getNumPorts(); + mvpN_s.resize(mNumPorts); + mvp_S0.resize(mNumPorts); + + for (size_t i=0; i. + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramFinalNode.hpp +//! @author Petter Krus +// co-author/auditor Robert Braun, Emilia Villani +//! @date 2019-08-15 +//! based on ElectricCapacitanceMultiPort.hpp and Volume component by Björn Eriksson +//! @brief Contains a Electric Volume Component +//! + +#ifndef ACTIVITYDIAGRAMFINALNODE_HPP_INCLUDED +#define ACTIVITYDIAGRAMFINALNODE_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A StateMachine state component + //! @ingroup StateMachine + //! + class ActivityDiagramFinalNode : public ComponentC + { + + private: + double state; + double *mpAlpha; + double *mpstate; +// double capacitance; + + std::vector mvpN_s, mvpN_q; + std::vector mvp_S0; + size_t mNumPorts; + Port *mpPpn1; + + public: + static Component *Creator() + { + return new ActivityDiagramFinalNode(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); +// addConstant("Capacitance", "Capacitance", "Fa", 0.0001, capacitance); + addInputVariable("alpha", "Low pass coeficient to dampen standing delayline waves", "-", 0.3, &mpAlpha); + addOutputVariable("state","State activated","",0.,&mpstate); + } + + + void initialize() + { + double alpha; + double state; + alpha = (*mpAlpha); + + mNumPorts = mpPpn1->getNumPorts(); + mvpN_s.resize(mNumPorts); + mvpN_q.resize(mNumPorts); + mvp_S0.resize(mNumPorts); + + for (size_t i=0; i + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinalNode.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinalNode.xml new file mode 100644 index 0000000..acf0bde --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFinalNode.xml @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.hpp new file mode 100644 index 0000000..d71d81d --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.hpp @@ -0,0 +1,228 @@ +#ifndef ACTIVITYDIAGRAMFORK_HPP_INCLUDED +#define ACTIVITYDIAGRAMFORK_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramFork.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Wed 13 Nov 2019 16:14:51 +//! @brief Fork for a state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramFork.nb*/ + +using namespace hopsan; + +class ActivityDiagramFork : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + double qpn10; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //Expressions variables + double dEvent; + double oldEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramFork(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event (trigg on positive \ +flank)","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + //Preventing creation of extra token + double drop = onPositive(-0.5 + spn1 - spn2 - spn3); + qpn2 = 0; + qpn3 = 0; + qpn1 = 0; + qpn10 = -dEvent*onPositive(-0.5 + spn1 - spn2 - spn3); + //if(dEvent > 0 && drop > 0) { + if(qpn10 < 0) { + bool successUpstream = true; + + //Try to lock upstream component + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successUpstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + bool successDownstream = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + successDownstream = true; + for(auto pPort : mpPpn3->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successUpstream && successDownstream) { + addDebugMessage("Locked tokens!"); + qpn2 = -qpn10; + qpn3 = -qpn10; + qpn1 = qpn10; + } + } + oldEvent = event; + /*qpn2 = dEvent*onPositive(spn1 - spn2 - spn3); + qpn3 = dEvent*onPositive(spn1 - spn2 - spn3); + qpn1 = -qpn2; + oldEvent = event; + */ + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMFORK_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.nb new file mode 100644 index 0000000..4781bb4 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.nb @@ -0,0 +1,599 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 30428, 591] +NotebookOptionsPosition[ 26705, 533] +NotebookOutlinePosition[ 27124, 549] +CellTagsIndexPosition[ 27081, 546] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel->"In[61]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9, 3.7627287106739197`*^9, {3.7653655281709204`*^9, + 3.7653655397771883`*^9}, {3.774863771563929*^9, 3.7748637782681117`*^9}, + 3.774863822282749*^9, 3.7826467657097054`*^9}, + CellLabel->"In[63]:=",ExpressionUUID->"7b028932-d1cb-4aec-8cb9-26c0d7fab47d"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7653656647449336`*^9, 3.7653658264367056`*^9, 3.7653658794497952`*^9, + 3.7654310624811687`*^9, 3.7654312190637693`*^9, 3.774863782789399*^9, { + 3.774863822282749*^9, 3.7748638255252094`*^9}, 3.774863903001707*^9, + 3.774863987619404*^9, 3.7753178495516796`*^9, 3.782646735725585*^9, + 3.7826467716284*^9, 3.782646889210889*^9, 3.7826523908287973`*^9}, + CellLabel->"Out[63]=",ExpressionUUID->"662ac5f0-c22d-48cf-8c84-9142e7ffb8bb"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.783933562698448*^9},ExpressionUUID->"d4124b2a-ea86-4434-bcf9-\ +b213164ffac7"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel->"In[64]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Fork", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.7552829602158165`*^9, 3.7552829636462793`*^9}, {3.7653652937303224`*^9, + 3.7653652948741436`*^9}, 3.7747951051283193`*^9, + 3.774861352550853*^9},ExpressionUUID->"e530ed89-c702-4a63-ba9a-\ +2addaa99d206"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1,qpn2 and qpn3, are either \ +0 or 1 in one time step. The state variables spn1, spn2 and spn3 are either 0 \ +or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940079196377`*^9}, + 3.774794209791312*^9},ExpressionUUID->"bdc3e281-aa00-44be-ae84-\ +967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.7552811322054944`*^9, 3.755281141404011*^9}, { + 3.76536529882735*^9, 3.7653653147948*^9}, 3.7747951068994923`*^9, + 3.774861352550853*^9, 3.77531784181115*^9, 3.783842808838291*^9, + 3.783843119461669*^9},ExpressionUUID->"66226cc4-c34c-490e-8628-\ +63aa4715d8a0"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214802554903`*^9, 3.7552831508242984`*^9, + 3.7643433133960524`*^9, 3.764343361374817*^9, 3.76434711494726*^9, + 3.7653653174990187`*^9, 3.7653653580217056`*^9, 3.765365613292461*^9, + 3.765365839367419*^9, 3.765365879559681*^9, 3.765431062614033*^9, + 3.765431219229105*^9, 3.774795673410385*^9, {3.774861352550853*^9, + 3.7748613557821894`*^9}, 3.7748618888201094`*^9, 3.7748638257000284`*^9, + 3.7748639031585436`*^9, 3.7748639877702484`*^9, 3.77531784964709*^9, + 3.782646736154687*^9, 3.7826467736137486`*^9, 3.7826468896606283`*^9, + 3.782652391913143*^9}, + CellLabel->"Out[70]=",ExpressionUUID->"d24a29c1-3322-468a-bab4-4d49ca5bee52"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "11", ",", "13", ",", "17", ",", "46", ",", + "31.7112596`9.25378839754705"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214802554903`*^9, 3.7552831508242984`*^9, + 3.7643433133960524`*^9, 3.764343361374817*^9, 3.76434711494726*^9, + 3.7653653174990187`*^9, 3.7653653580217056`*^9, 3.765365613292461*^9, + 3.765365839367419*^9, 3.765365879559681*^9, 3.765431062614033*^9, + 3.765431219229105*^9, 3.774795673410385*^9, {3.774861352550853*^9, + 3.7748613557821894`*^9}, 3.7748618888201094`*^9, 3.7748638257000284`*^9, + 3.7748639031585436`*^9, 3.7748639877702484`*^9, 3.77531784964709*^9, + 3.782646736154687*^9, 3.7826467736137486`*^9, 3.7826468896606283`*^9, + 3.7826523919391284`*^9}, + CellLabel->"Out[74]=",ExpressionUUID->"7c54834b-dcbe-4cff-abcf-62c04c276302"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7748639779539723`*^9, 3.774863984865543*^9}}, + CellLabel->"In[75]:=",ExpressionUUID->"29c4d638-a0a0-4ba4-b26c-26191c8e83de"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, { + 3.7748638812026606`*^9, 3.774863885385459*^9}, {3.7838431361781645`*^9, + 3.783843149997116*^9}},ExpressionUUID->"2096f5b3-005e-4e58-a8bb-\ +ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", " ", "=", " ", + RowBox[{"{", "\n", " ", + RowBox[{"{", + RowBox[{ + "event", ",", " ", "1.", ",", " ", "double", ",", " ", "\"\<\>\"", ",", + " ", "\"\\""}], "}"}], "\n", " ", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, 3.7550214607545958`*^9, {3.765431186087635*^9, + 3.765431200241627*^9}, 3.774861352550853*^9}, + CellLabel->"In[77]:=",ExpressionUUID->"9694c865-8c2e-48bf-b3af-2b54afb74cf0"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffEvent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.774861352550853*^9, 3.7826468701107273`*^9}, + CellLabel->"In[78]:=",ExpressionUUID->"d62d36ac-ee4a-4b20-bb28-db62fb401eed"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "-", + RowBox[{"diffEvent", "*", "oldEvent"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn2", "\[Equal]", + RowBox[{"dEvent", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn2", "-", "spn3"}], "]"}]}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn3", "\[Equal]", + RowBox[{"dEvent", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn2", "-", "spn3"}], "]"}]}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{"-", "qpn2"}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent", "==", "event"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7643433362447524`*^9, + 3.7643433574496603`*^9}, {3.7747951683414693`*^9, 3.774795202078376*^9}, + 3.7748613525528517`*^9, 3.774863901313697*^9, {3.7826466491704607`*^9, + 3.7826466742648764`*^9}}, + CellLabel->"In[79]:=",ExpressionUUID->"322217c0-2cf2-48db-81e6-1825242e2cb5"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.774861352553851*^9, 3.774863901313697*^9}, + CellLabel->"In[80]:=",ExpressionUUID->"a12717b8-fc5d-45c7-8f3c-fd66477eef9a"] +}, Open ]], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", RowBox[{\\\ +\"\\\\\\\"Act\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"Fork\\\\\\\"\\\"}]}], \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \ +\\\"1\\\", \\\"\[RightSkeleton]\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramFork.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramFork.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\"]\\\"}]\\) is \ +not a list of contents. The third item in an XMLElement must be a list of \ +contents, even if it is an empty list.\"",2,80,33,19006202694589510913, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.7826523976370525`*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"ac3e0a9d-fdae-498c-926e-4d4511b35419"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,80,34,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652398229714*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"f6c643ca-732c-495c-800d-6ce74013d3b7"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 80,35,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652398750414*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"bf4ca86d-83b0-4ccf-b524-aacd392bdb04"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,80,36,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652399246129*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"72fedd63-34c3-4909-aaaa-707cb805704d"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,80,37,19006202694589510913, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.78265239952297*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"d5d916ab-38eb-4d87-b1e7-c3de397095fd"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,80,38,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652399823799*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"045b9d58-92e5-4ef0-a8db-d0366e7d56d5"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,80,39,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652400312519*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"818b3652-f885-49eb-b1ea-c217b2b3ed05"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 80,40,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652400580365*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"44018029-759f-49d2-a661-ecb1335d2dc5"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,80,41,19006202694589510913,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755021480415325*^9, 3.755283151067049*^9, + 3.7643433136136475`*^9, 3.764343361606886*^9, 3.764347115245705*^9, + 3.765365317590925*^9, 3.765365358113617*^9, 3.765365613432819*^9, + 3.765365839508272*^9, 3.765365879724511*^9, 3.7654310628088317`*^9, + 3.765431219497828*^9, 3.774795673926897*^9, {3.774861352559843*^9, + 3.774861355972993*^9}, 3.774863903582732*^9, 3.7748639882587442`*^9, + 3.775317849994731*^9, 3.7826467385878634`*^9, 3.7826467765539117`*^9, + 3.782646891922616*^9, 3.782652400856207*^9}, + CellLabel-> + "During evaluation of \ +In[80]:=",ExpressionUUID->"89a08b05-f307-4af9-a1c8-353b61423e8d"] +}, +WindowSize->{1008, 709}, +WindowMargins->{{0, Automatic}, {Automatic, 0}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 96, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 375, 6, 28, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1231, 37, 1443, 23, 48, "Input",ExpressionUUID->"7b028932-d1cb-4aec-8cb9-26c0d7fab47d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2677, 62, 668, 9, 32, "Output",ExpressionUUID->"662ac5f0-c22d-48cf-8c84-9142e7ffb8bb", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3348, 73, 514, 12, 48, "Input",ExpressionUUID->"d4124b2a-ea86-4434-bcf9-b213164ffac7", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3865, 87, 299, 6, 28, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4167, 95, 487, 8, 67, "Section",ExpressionUUID->"e530ed89-c702-4a63-ba9a-2addaa99d206", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4657, 105, 578, 11, 56, "Text",ExpressionUUID->"bdc3e281-aa00-44be-ae84-967524ca58f1", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5238, 118, 1802, 39, 200, "Input",ExpressionUUID->"66226cc4-c34c-490e-8628-63aa4715d8a0", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7043, 159, 903, 13, 32, "Output",ExpressionUUID->"d24a29c1-3322-468a-bab4-4d49ca5bee52", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7949, 174, 971, 16, 32, "Output",ExpressionUUID->"7c54834b-dcbe-4cff-abcf-62c04c276302", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8923, 192, 269, 5, 28, "Input",ExpressionUUID->"29c4d638-a0a0-4ba4-b26c-26191c8e83de", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9195, 199, 1151, 22, 105, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10349, 223, 932, 17, 67, "Input",ExpressionUUID->"9694c865-8c2e-48bf-b3af-2b54afb74cf0", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11284, 242, 509, 11, 67, "Input",ExpressionUUID->"d62d36ac-ee4a-4b20-bb28-db62fb401eed", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11796, 255, 1785, 36, 143, "Input",ExpressionUUID->"322217c0-2cf2-48db-81e6-1825242e2cb5", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13584, 293, 261, 4, 28, "Input",ExpressionUUID->"a12717b8-fc5d-45c7-8f3c-fd66477eef9a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[13860, 300, 4621, 70, 77, "Message",ExpressionUUID->"ac3e0a9d-fdae-498c-926e-4d4511b35419"], +Cell[18484, 372, 953, 17, 21, "Message",ExpressionUUID->"f6c643ca-732c-495c-800d-6ce74013d3b7"], +Cell[19440, 391, 1095, 19, 21, "Message",ExpressionUUID->"bf4ca86d-83b0-4ccf-b524-aacd392bdb04"], +Cell[20538, 412, 953, 17, 21, "Message",ExpressionUUID->"72fedd63-34c3-4909-aaaa-707cb805704d"], +Cell[21494, 431, 1094, 20, 21, "Message",ExpressionUUID->"d5d916ab-38eb-4d87-b1e7-c3de397095fd"], +Cell[22591, 453, 953, 17, 21, "Message",ExpressionUUID->"045b9d58-92e5-4ef0-a8db-d0366e7d56d5"], +Cell[23547, 472, 1025, 18, 21, "Message",ExpressionUUID->"818b3652-f885-49eb-b1ea-c217b2b3ed05"], +Cell[24575, 492, 1095, 19, 21, "Message",ExpressionUUID->"44018029-759f-49d2-a661-ecb1335d2dc5"], +Cell[25673, 513, 1028, 18, 21, "Message",ExpressionUUID->"89a08b05-f307-4af9-a1c8-353b61423e8d"] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.svg new file mode 100644 index 0000000..5694951 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.svg @@ -0,0 +1,111 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.xml new file mode 100644 index 0000000..7d77610 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork0.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork0.hpp new file mode 100644 index 0000000..ee6a5f6 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramFork0.hpp @@ -0,0 +1,228 @@ +#ifndef ACTIVITYDIAGRAMFORK_HPP_INCLUDED +#define ACTIVITYDIAGRAMFORK_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramFork.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Wed 13 Nov 2019 16:14:51 +//! @brief Fork for a state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramFork.nb*/ + +using namespace hopsan; + +class ActivityDiagramFork : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + double qpn10; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //Expressions variables + double dEvent; + double oldEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramFork(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event (trigg on positive \ +flank)","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + dEvent = onPositive(-0.5 + event - diffEvent*oldEvent); + //Preventing creation of extra token + double drop = onPositive(-0.5 + spn1 - spn2 - spn3); + qpn2 = 0; + qpn3 = 0; + qpn1 = 0; + qpn10 = -dEvent*onPositive(-0.5 + spn1 - spn2 - spn3); + //if(dEvent > 0 && drop > 0) { + if(qpn10 < 0) { + bool successUpstream = true; + + //Try to lock upstream component + for(auto pPort : mpPpn1->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successUpstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + bool successDownstream = true; + for(auto pPort : mpPpn2->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Try to lock downstream component + successDownstream = true; + for(auto pPort : mpPpn3->getConnectedPorts()) { + if(pPort->getComponent()->getTypeName() == "ActivityDiagramActionN") { + auto component = dynamic_cast(pPort->getComponent()); + successDownstream = component->tryAndLockToken(); + } + } + + //Locked both upstream and downstream (or not ActionN-components), compute flow + if(successUpstream && successDownstream) { + addDebugMessage("Locked tokens!"); + qpn2 = dEvent*onPositive(-0.5 + spn1 - spn2 - spn3); + qpn3 = dEvent*onPositive(-0.5 + spn1 - spn2 - spn3); + qpn1 = -qpn2; + oldEvent = event; + } + } + /*qpn2 = dEvent*onPositive(spn1 - spn2 - spn3); + qpn3 = dEvent*onPositive(spn1 - spn2 - spn3); + qpn1 = -qpn2; + oldEvent = event; + */ + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMFORK_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramForkN.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramForkN.hpp new file mode 100644 index 0000000..9281c86 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramForkN.hpp @@ -0,0 +1,178 @@ +/*----------------------------------------------------------------------------- + This source file is a part of Hopsan + + Copyright (c) 2009 to present year, Hopsan Group + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramForkN.hpp +//! @author Petter Krus +//! @date 2018-12-31 +//! based on ElectricCapacitanceMultiPort.hpp by Björn Eriksson +//! @brief Contains a multi in join Component +//! + +#ifndef ACTIVITYDIAGRAMFORKN_HPP_INCLUDED +#define ACTIVITYDIAGRAMFORKN_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A ActivityDiagram FORK multi port component + //! @ingroup ActivityDiagram + //! + class ActivityDiagramForkN : public ComponentQ + { + + private: + double diffevent; + double event; + double state; + double oldState; + double oldEvent; + + std::vector mvpN_s, mvpN_q; + std::vector mvp_S0; + size_t mNumPorts; + Port *mpPpn1; + Port *mpPpn2; + + //Port Ppn2 variable + double s2; + double q2; + + //Port Ppn2 pointer + double *mpP_s2; + double *mpP_q2; + + //inputVariables pointers + double *mpevent; + + //inputParameters pointers + double *mpdiffevent; + + //outputVariables pointers + double *mpstate; + + public: + static Component *Creator() + { + return new ActivityDiagramForkN(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + + //Add inputVariables to the component + addInputVariable("event","event ","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffevent", "Trigg on level (0) or flank (1)", "", 0.,&mpdiffevent); + + //Add outputVariables to the component + addOutputVariable("state","state","",0.,&mpstate); + + } + + void initialize() + { + //Port Ppn1 + mNumPorts = mpPpn1->getNumPorts(); + mvpN_s.resize(mNumPorts); + mvpN_q.resize(mNumPorts); + mvp_S0.resize(mNumPorts); + + for (size_t i=0; i + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.hpp new file mode 100644 index 0000000..ae48d32 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.hpp @@ -0,0 +1,144 @@ +#ifndef ACTIVITYDIAGRAMINITIATESTATE_HPP_INCLUDED +#define ACTIVITYDIAGRAMINITIATESTATE_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramInitiateState.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 17 Oct 2019 19:22:27 +//! @brief Initialization for a Activity Diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramInitiateState.nb*/ + +using namespace hopsan; + +class ActivityDiagramInitiateState : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //InitialExpressions variables + double oldEvent; + //Expressions variables + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramInitiateState(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event (trigg on positive \ +flank)","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "event (trigg on positive flank)", \ +"", 1.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent = 0.; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + qpn1 = onPositive(-0.5 + event - diffEvent*oldEvent - spn1); + oldEvent = event; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMINITIATESTATE_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.nb new file mode 100644 index 0000000..2f81dcf --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.nb @@ -0,0 +1,568 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 28067, 560] +NotebookOptionsPosition[ 24247, 500] +NotebookOutlinePosition[ 24668, 516] +CellTagsIndexPosition[ 24625, 513] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel-> + "In[289]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, 3.7748679214756083`*^9}, + CellLabel-> + "In[290]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.77479556374086*^9, + 3.7748613834299583`*^9, 3.7748619371199417`*^9, 3.7748642131804657`*^9, + 3.7748645633975315`*^9, {3.7748645970573945`*^9, 3.774864607918788*^9}, + 3.774867703652725*^9, 3.774867926791222*^9, 3.774892832598035*^9, + 3.775317869629486*^9, 3.7803136766181493`*^9}, + CellLabel-> + "Out[290]=",ExpressionUUID->"1242d9d9-afc6-43a3-a28c-3bb0031bdc41"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.780313242636645*^9}, + CellLabel-> + "In[291]:=",ExpressionUUID->"0903a469-10cd-4b2d-aa4c-70ce77ff970d"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.780313676730456*^9, 3.780322390417487*^9}, + CellLabel-> + "Out[291]=",ExpressionUUID->"d8204922-e834-4a17-b6ea-d9627d8a5a34"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel-> + "In[310]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Initiate", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, {3.754047538282405*^9, + 3.754047549959265*^9}, {3.7552832968927016`*^9, 3.7552832972033815`*^9}, { + 3.7554173810299163`*^9, 3.755417381886033*^9}, 3.7747954639963675`*^9, + 3.774861381726017*^9, 3.77486191225311*^9, + 3.7803133814542294`*^9},ExpressionUUID->"4d153d9c-7b28-4465-9655-\ +a48708ad9847"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or -1). The flow is either 0 or one in one time \ +step. The vawe variables cel1 and cel2 are either 0 or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, + 3.7554173947018223`*^9, + 3.774861381726017*^9},ExpressionUUID->"5a36ba0e-8e98-445a-9ec2-\ +50747d0f7dcb"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7540475704265985`*^9, + 3.754047583132675*^9}, {3.755283262173503*^9, 3.755283264773819*^9}, { + 3.755417376704378*^9, 3.75541737766938*^9}, {3.755417462599818*^9, + 3.755417466808478*^9}, 3.774795466549244*^9, 3.7748613817270155`*^9, { + 3.774861919274185*^9, 3.7748619298823028`*^9}, {3.774892217455916*^9, + 3.7748922180483685`*^9}}, + CellLabel-> + "In[311]:=",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.75528330099747*^9, 3.7553242249759817`*^9, + 3.755324260834011*^9, 3.755463629330747*^9, 3.7554639167334347`*^9, + 3.774795563892702*^9, {3.7748613817270155`*^9, 3.7748613835148697`*^9}, + 3.774861937213806*^9, 3.774864213342299*^9, 3.774864563555369*^9, { + 3.7748645972112355`*^9, 3.77486460807063*^9}, 3.774867703803563*^9, + 3.77486792694706*^9, 3.7748928327908363`*^9, 3.7753178697183957`*^9, + 3.780313676948842*^9, 3.780321747089079*^9}, + CellLabel-> + "Out[316]=",ExpressionUUID->"8c05a766-4870-42e3-8962-0267e54c5333"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "10", ",", "17", ",", "19", ",", "22", ",", + "27.0890793`9.185369160057958"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.75528330099747*^9, 3.7553242249759817`*^9, + 3.755324260834011*^9, 3.755463629330747*^9, 3.7554639167334347`*^9, + 3.774795563892702*^9, {3.7748613817270155`*^9, 3.7748613835148697`*^9}, + 3.774861937213806*^9, 3.774864213342299*^9, 3.774864563555369*^9, { + 3.7748645972112355`*^9, 3.77486460807063*^9}, 3.774867703803563*^9, + 3.77486792694706*^9, 3.7748928327908363`*^9, 3.7753178697183957`*^9, + 3.780313676948842*^9, 3.7803217471047015`*^9}, + CellLabel-> + "Out[320]=",ExpressionUUID->"d6ab8112-8cd6-4dcb-906c-f2e46c873b65"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"state", "=."}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7748642032354603`*^9, 3.7748642103278923`*^9}}, + CellLabel-> + "In[321]:=",ExpressionUUID->"b80f8bb0-04de-4ff6-8453-f128bf415b6b"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "1.", ",", "\"\\""}], "]"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.75404759400323*^9, + 3.7540477190914407`*^9, 3.7553242534686055`*^9, 3.7748613817270155`*^9, + 3.77486769495127*^9, 3.7748928260322795`*^9, {3.7803134756519003`*^9, + 3.7803134759010286`*^9}}, + CellLabel-> + "In[322]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.780313538092991*^9, 3.7803135406627865`*^9}, { + 3.780313660202917*^9, 3.780313667247159*^9}}, + CellLabel-> + "In[323]:=",ExpressionUUID->"9c24bf64-7f0f-471e-80fb-017e0b6971b2"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffEvent", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7803136602039175`*^9, 3.780313667247159*^9}}, + CellLabel-> + "In[324]:=",ExpressionUUID->"1eef8e95-54f5-4096-b690-1ee8c645500c"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "oldEvent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7554635581691155`*^9, 3.7554636200383286`*^9}, + 3.7748613817270155`*^9, {3.7803136602039175`*^9, 3.7803136672481318`*^9}}, + CellLabel-> + "In[325]:=",ExpressionUUID->"45a7267b-102e-4994-82f3-17fd694e5654"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"qpn1", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "-", + RowBox[{"diffEvent", " ", "oldEvent"}], "-", "spn1", "-", "0.5"}], + "]"}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent", "\[Equal]", "event"}]}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.7540475984872904`*^9, 3.7540476129458995`*^9}, { + 3.7540476910155144`*^9, 3.754047691685115*^9}, 3.7554173893183746`*^9, + 3.7554174592942257`*^9, {3.7554635125221767`*^9, 3.755463526263009*^9}, + 3.7747954957200775`*^9, {3.774795527795559*^9, 3.7747955286187067`*^9}, + 3.7748613817270155`*^9, {3.774864588216931*^9, 3.774864591940977*^9}, { + 3.78031356706925*^9, 3.780313572399868*^9}, {3.7803136602059264`*^9, + 3.7803136672481318`*^9}, {3.780321712750452*^9, 3.780321722472545*^9}}, + CellLabel-> + "In[326]:=",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7748613817290125`*^9, 3.7748646059877806`*^9, {3.7803136602059264`*^9, + 3.7803136672481318`*^9}}, + CellLabel-> + "In[327]:=",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2"] +}, Open ]], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramInitiateState\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramInitiateState\\\\\\\"\\\"}]}], \\\"}\\\"}], \ +\\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramInitiateState.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramInitiateState.svg\\\\\\\"\\\"}]}], \\\ +\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{\\\"\\\\\\\"version\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"0.1\\\\\\\"\\\"}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramInitiateState\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramInitiateState\\\\\\\"\\\"}]}], \\\"}\\\"}], \ +\\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramInitiateState.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramInitiateState.svg\\\\\\\"\\\"}]}], \\\ +\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \\\",\\\", RowBox[{\\\ +\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,327, + 105,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.7803217478282585`*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"1af8fadd-fa4f-4845-8f75-6a3815d12642"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,327,106,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.780321748046993*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"8434ce92-990c-4026-8885-da975ec2b806"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,327,107,18988733202671857145, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.7803217480626173`*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"6601a59e-f9d9-4bc5-8e96-d904010a510f"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,327,108,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.7803217480938644`*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"fb76e24e-7769-4fdd-8ca6-373ec76c4036"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,327,109,18988733202671857145, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.780321748265729*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"a4235cb2-a562-400a-bebb-da624e550132"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,327,110,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.780321748281352*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"2d5e2e7a-28ad-4030-bce6-20f701608176"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,327,111,18988733202671857145,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.755283301345112*^9, 3.7553242251498013`*^9, + 3.755324261470355*^9, 3.755463629467605*^9, 3.7554639168642983`*^9, + 3.774795564446212*^9, {3.7748613817330103`*^9, 3.7748613837246532`*^9}, + 3.7748646085341535`*^9, 3.7748677043684864`*^9, 3.774867927526462*^9, + 3.7748928336179914`*^9, 3.775317870056046*^9, 3.780313678053779*^9, + 3.7803217482969747`*^9}, + CellLabel-> + "During evaluation of \ +In[327]:=",ExpressionUUID->"1a7cb48f-4fc3-40a6-8a7c-96f2b0b792aa"] +}, +WindowSize->{1191, 801}, +WindowMargins->{{Automatic, 50}, {Automatic, 18}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 96, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 379, 7, 28, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1235, 38, 657, 13, 28, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1895, 53, 928, 14, 32, "Output",ExpressionUUID->"1242d9d9-afc6-43a3-a28c-3bb0031bdc41", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2826, 69, 537, 12, 28, "Input",ExpressionUUID->"0903a469-10cd-4b2d-aa4c-70ce77ff970d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3366, 83, 351, 5, 32, "Output",ExpressionUUID->"d8204922-e834-4a17-b6ea-d9627d8a5a34", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3720, 90, 303, 7, 28, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4026, 99, 562, 9, 67, "Section",ExpressionUUID->"4d153d9c-7b28-4465-9655-a48708ad9847", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4591, 110, 473, 9, 56, "Text",ExpressionUUID->"5a36ba0e-8e98-445a-9ec2-50747d0f7dcb", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5067, 121, 1932, 42, 200, "Input",ExpressionUUID->"0c12bced-a0c3-4902-8101-a0eeacaebe47", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7002, 165, 780, 12, 32, "Output",ExpressionUUID->"8c05a766-4870-42e3-8962-0267e54c5333", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7785, 179, 849, 15, 32, "Output",ExpressionUUID->"d6ab8112-8cd6-4dcb-906c-f2e46c873b65", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8637, 196, 275, 6, 28, "Input",ExpressionUUID->"b80f8bb0-04de-4ff6-8453-f128bf415b6b", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8915, 204, 776, 15, 67, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9694, 221, 559, 13, 67, "Input",ExpressionUUID->"9c24bf64-7f0f-471e-80fb-017e0b6971b2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10256, 236, 515, 12, 67, "Input",ExpressionUUID->"1eef8e95-54f5-4096-b690-1ee8c645500c", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10774, 250, 587, 13, 67, "Input",ExpressionUUID->"45a7267b-102e-4994-82f3-17fd694e5654", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11364, 265, 1523, 27, 86, "Input",ExpressionUUID->"2316194c-ef64-4d0a-9217-862d722a09ba", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12890, 294, 326, 7, 28, "Input",ExpressionUUID->"4f62450d-7e66-411b-91fd-6f6fd94578a2", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[13231, 304, 5844, 85, 112, "Message",ExpressionUUID->"1af8fadd-fa4f-4845-8f75-6a3815d12642"], +Cell[19078, 391, 798, 15, 21, "Message",ExpressionUUID->"8434ce92-990c-4026-8885-da975ec2b806"], +Cell[19879, 408, 942, 18, 21, "Message",ExpressionUUID->"6601a59e-f9d9-4bc5-8e96-d904010a510f"], +Cell[20824, 428, 800, 15, 21, "Message",ExpressionUUID->"fb76e24e-7769-4fdd-8ca6-373ec76c4036"], +Cell[21627, 445, 940, 18, 21, "Message",ExpressionUUID->"a4235cb2-a562-400a-bebb-da624e550132"], +Cell[22570, 465, 798, 15, 21, "Message",ExpressionUUID->"2d5e2e7a-28ad-4030-bce6-20f701608176"], +Cell[23371, 482, 872, 16, 21, "Message",ExpressionUUID->"1a7cb48f-4fc3-40a6-8a7c-96f2b0b792aa"] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.svg new file mode 100644 index 0000000..582bec6 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.svg @@ -0,0 +1,114 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.xml new file mode 100644 index 0000000..ceefccf --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramInitiateState.xml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.hpp new file mode 100644 index 0000000..310bfd2 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.hpp @@ -0,0 +1,181 @@ +#ifndef ACTIVITYDIAGRAMJOIN_HPP_INCLUDED +#define ACTIVITYDIAGRAMJOIN_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramJoin.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Wed 27 Nov 2019 12:38:02 +//! @brief And for a state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramJoin.nb*/ + +using namespace hopsan; + +class ActivityDiagramJoin : public ComponentQ +{ +private: + double diffEvent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event; + //outputVariables + //Expressions variables + double dEvent3; + double oldEvent; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent; + //inputParameters pointers + double *mpdiffEvent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramJoin(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event","event (trigg on \ +value)","",1.,&mpevent); + + //Add inputParammeters to the component + addInputVariable("diffEvent", "event3, trigg on level(0) or \ +flank(1)", "", 0.,&mpdiffEvent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event = (*mpevent); + + //Read inputParameters from nodes + diffEvent = (*mpdiffEvent); + + //LocalExpressions + + //Expressions + dEvent3 = onPositive(-0.5 + event - diffEvent*oldEvent); + qpn3 = onPositive(event)*onPositive(-0.5 + spn1*spn2 - spn3); + qpn1 = -qpn3; + qpn2 = -qpn3; + oldEvent = event; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMJOIN_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.nb new file mode 100644 index 0000000..6f6d853 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.nb @@ -0,0 +1,661 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 34515, 653] +NotebookOptionsPosition[ 30159, 583] +NotebookOutlinePosition[ 30580, 599] +CellTagsIndexPosition[ 30537, 596] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, + 3.774794098262859*^9}},ExpressionUUID->"5ee7c9b3-61b3-495d-947e-\ +36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + CellLabel->"In[20]:=",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + CellLabel->"In[21]:=",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795592346754*^9, + 3.774861398577976*^9, 3.7748619525444*^9, 3.7753177856576447`*^9, + 3.7760688056377096`*^9, 3.7760689017746077`*^9, 3.776070944721018*^9, + 3.7760710374873853`*^9, 3.776071235541223*^9, 3.783843343493267*^9, + 3.783843481153901*^9}, + CellLabel->"Out[21]=",ExpressionUUID->"0059a820-b9c3-4725-ad02-bd461e591c7f"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774797375685176*^9, + 3.7747973875893726`*^9}, {3.7760688172187753`*^9, + 3.7760688264662404`*^9}, {3.7760688832017593`*^9, 3.7760688836492944`*^9}}, + CellLabel->"In[22]:=",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a"] +}, Open ]], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellChangeTimes->{3.7838434814297028`*^9}, + CellLabel->"Out[22]=",ExpressionUUID->"f1a4295c-b58d-4f33-b3e5-12208bfdf7fe"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774797375685176*^9, + 3.7747973875893726`*^9}, {3.7760688172187753`*^9, + 3.7760688264662404`*^9}, {3.7760688832017593`*^9, 3.7760688836492944`*^9}, + 3.783843477517951*^9}, + CellLabel->"In[23]:=",ExpressionUUID->"a908591f-c3f3-4c9d-b1e2-c297b5aca660"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955924119816`*^9, + 3.7748613986319213`*^9, 3.774861952601342*^9, 3.775317785722578*^9, + 3.7760688056656814`*^9, 3.7760689018006496`*^9, 3.776070944758975*^9, + 3.7760710375243483`*^9, 3.776071235580185*^9, 3.783843343561288*^9, + 3.783843481583459*^9}, + CellLabel->"Out[23]=",ExpressionUUID->"e1f7b57e-4973-49a2-8b64-9f5727805f16"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + CellLabel->"In[24]:=",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Join", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.7550214968084235`*^9, 3.7550214976735325`*^9}, {3.7552807972398443`*^9, + 3.7552808064463525`*^9}, {3.7552808483581448`*^9, + 3.7552808485099845`*^9}, {3.765365251275384*^9, 3.7653652518263435`*^9}, { + 3.7747942042782946`*^9, + 3.774794220390111*^9}},ExpressionUUID->"088c7a70-e175-477e-9f3a-\ +655c7cd3370d"], + +Cell["\<\ +Join (AND) function. The flow is either 0 or one in one time step. The wave \ +variables spn1 and spn2 are either 0 or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, 3.7747942042782946`*^9, { + 3.7747942713572884`*^9, 3.774794273096493*^9}, {3.776068772753235*^9, + 3.776068777840438*^9}},ExpressionUUID->"6f15cb33-9e39-488c-92cb-\ +ee7ba955af67"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{ + RowBox[{ + "coauthor", "=", + "\"\, Emilia Villani\>\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.7550215020570135`*^9, + 3.7550215088340263`*^9}, {3.755280868192692*^9, 3.7552808942538214`*^9}, { + 3.76536525978136*^9, 3.7653652604361925`*^9}, {3.774794204279293*^9, + 3.77479422293149*^9}, 3.775317780594391*^9, 3.777541563880372*^9}, + CellLabel->"In[25]:=",ExpressionUUID->"9335b084-863b-47bb-bc84-c039b71d3a5b"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "11", ",", "27", ",", "12", ",", "38", ",", + "1.7487194`7.995295114488466"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550215143633256`*^9, 3.755031739579131*^9, + 3.755283201122441*^9, 3.7643432865421467`*^9, 3.764346904519914*^9, + 3.764347089430435*^9, 3.7653652772881794`*^9, 3.7653655961515565`*^9, { + 3.765366236453781*^9, 3.7653662585314226`*^9}, 3.765366761177063*^9, + 3.774794204279293*^9, 3.7747955925446033`*^9, 3.774861398721828*^9, + 3.774861952702238*^9, 3.775317785840455*^9, 3.776068805716628*^9, + 3.776068901851528*^9, 3.776070944831899*^9, 3.776071037595276*^9, + 3.7760712356561046`*^9, 3.7838433436544056`*^9, 3.783843481879754*^9}, + CellLabel->"Out[34]=",ExpressionUUID->"d0676b02-cbaa-496e-9a62-70f773763304"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, { + 3.7775415451696653`*^9, 3.777541546479336*^9}}, + CellLabel->"In[35]:=",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", " ", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event", ",", "1.", ",", " ", "double", ",", "\"\<\>\"", ",", " ", + "\"\\""}], "}"}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, 3.755031730677309*^9, 3.7747942042802925`*^9, { + 3.7760685513030233`*^9, 3.7760686784409633`*^9}, {3.7760703077523346`*^9, + 3.7760703432387514`*^9}, {3.7760708301710997`*^9, + 3.7760708408820567`*^9}, {3.777541777142488*^9, 3.777541778549036*^9}, { + 3.7775420129573493`*^9, 3.777542016173033*^9}, {3.7838431937936945`*^9, + 3.7838432010782948`*^9}, 3.78384324873831*^9, 3.783843325635455*^9}, + CellLabel->"In[36]:=",ExpressionUUID->"2cb343b4-4a02-4069-b70f-d2246ecff4f8"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffEvent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9, { + 3.7760708823393207`*^9, 3.776070932245875*^9}}, + CellLabel->"In[37]:=",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent3", "==", + RowBox[{"onPositive", "[", + RowBox[{"event", "-", + RowBox[{"diffEvent", "*", "oldEvent"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn3", "\[Equal]", " ", + RowBox[{ + RowBox[{"onPositive", "[", "event", "]"}], + RowBox[{"onPositive", "[", + RowBox[{ + RowBox[{"spn1", " ", "spn2"}], "-", "spn3", "-", "0.5"}], "]"}]}]}], + ",", "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{"-", "qpn3"}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn2", "==", + RowBox[{"-", "qpn3"}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent", "==", "event"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7550317093303185`*^9, + 3.7550317139985056`*^9}, {3.7643431906677704`*^9, + 3.7643431975270147`*^9}, {3.764343569262467*^9, 3.764343574978962*^9}, + 3.7747942042802925`*^9, {3.7747942627936115`*^9, 3.774794314605649*^9}, { + 3.7760686995462093`*^9, 3.7760687190331187`*^9}, {3.7760703616637583`*^9, + 3.7760703689012976`*^9}, {3.776070858269133*^9, 3.7760708754684024`*^9}, + 3.7760710313776875`*^9, {3.776071229952984*^9, 3.77607123253732*^9}, { + 3.7838432101168375`*^9, 3.78384323494664*^9}}, + CellLabel->"In[38]:=",ExpressionUUID->"5c2a5e25-e670-491c-933e-302886292168"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7747942042813015`*^9}, + CellLabel->"In[39]:=",ExpressionUUID->"91b365df-e70c-494b-bfc9-f2101325390a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", RowBox[{\\\ +\"\\\\\\\"\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"\\\\\\\"\\\"}]}], \\\ +\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \ +\\\"\[RightSkeleton]\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramJoin.svg\\\\\\\"\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramJoin.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \ +\\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\ +\"\[Rule]\\\", \\\"\\\\\\\"270\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"event\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]\\) in \\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{\\\"\\\\\\\"version\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"0.1\\\\\\\"\\\"}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramJoin\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramJoin\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramJoin.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramJoin.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\ +\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of \ +contents. The third item in an XMLElement must be a list of contents, even if \ +it is an empty list.\"",2,39,15,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434831797385`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"f2eabf97-69a8-4b77-9100-9962a22c4ada"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,39,16,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434832734795`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"4a887f2d-d27a-446c-be43-04621c2bff89"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 39,17,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434835859594`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"ff4bc5fc-854f-489b-afaf-45c565a008d3"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,39,18,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434836328306`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"3f63e068-e730-49a3-af67-b5a14e0d0c58"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,39,19,19014042857157888424, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434839296846`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"36a5b4e2-9064-444b-aa5e-94a86996c362"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,39,20,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434839765563`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"2fe89592-f874-4cfb-93fa-795c4544ca70"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,39,21,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.783843484007804*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"a2708204-1a49-4efc-8816-61aba56b18f8"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 39,22,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.7838434840390525`*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"d51747a1-9163-47bc-a6ea-4315ab6f2d88"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,39,23,19014042857157888424,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068805838503*^9, + 3.7760689019883876`*^9, 3.77607094509263*^9, 3.776071037862*^9, + 3.7760712358828707`*^9, 3.7838433438998966`*^9, 3.783843484398402*^9}, + CellLabel-> + "During evaluation of \ +In[39]:=",ExpressionUUID->"2c2f6dbb-5955-43f6-b7c8-ad520c501aa0"] +}, Open ]] +}, +WindowSize->{827, 636}, +WindowMargins->{{262, Automatic}, {Automatic, 47}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"12.0 for Microsoft Windows (64-bit) (April 8, 2019)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 271, 5, 96, "Title",ExpressionUUID->"5ee7c9b3-61b3-495d-947e-36f10d487fd4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[853, 29, 375, 6, 28, "Input",ExpressionUUID->"fb626f91-feab-4a07-b722-dbbcc151c4cc", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1231, 37, 1231, 21, 48, "Input",ExpressionUUID->"b61e84a1-9117-4d95-854e-6432998655f4", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2465, 60, 890, 13, 32, "Output",ExpressionUUID->"0059a820-b9c3-4725-ad02-bd461e591c7f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3358, 75, 819, 15, 48, "Input",ExpressionUUID->"f08428ac-a507-4dcf-b70e-fed094d55f5a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]], +Cell[4192, 93, 270, 3, 32, "Output",ExpressionUUID->"f1a4295c-b58d-4f33-b3e5-12208bfdf7fe"], +Cell[CellGroupData[{ +Cell[4487, 100, 862, 16, 48, "Input",ExpressionUUID->"a908591f-c3f3-4c9d-b1e2-c297b5aca660", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5352, 118, 918, 13, 32, "Output",ExpressionUUID->"e1f7b57e-4973-49a2-8b64-9f5727805f16", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6273, 133, 299, 6, 28, "Input",ExpressionUUID->"96c62941-67ee-4f41-b96b-bc238faf7f2f", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6575, 141, 595, 10, 67, "Section",ExpressionUUID->"088c7a70-e175-477e-9f3a-655c7cd3370d", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7173, 153, 504, 9, 34, "Text",ExpressionUUID->"6f15cb33-9e39-488c-92cb-ee7ba955af67", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[7680, 164, 1878, 41, 200, "Input",ExpressionUUID->"9335b084-863b-47bb-bc84-c039b71d3a5b", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9561, 207, 937, 15, 32, "Output",ExpressionUUID->"d0676b02-cbaa-496e-9a62-70f773763304", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10501, 224, 1121, 21, 105, "Input",ExpressionUUID->"2096f5b3-005e-4e58-a8bb-ee5cca97f503", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11625, 247, 1235, 21, 67, "Input",ExpressionUUID->"2cb343b4-4a02-4069-b70f-d2246ecff4f8", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12863, 270, 941, 17, 67, "Input",ExpressionUUID->"938657e9-f22d-4845-b3b8-9e4b7f5f1c06", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13807, 289, 2054, 39, 143, "Input",ExpressionUUID->"5c2a5e25-e670-491c-933e-302886292168", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15864, 330, 241, 4, 28, "Input",ExpressionUUID->"91b365df-e70c-494b-bfc9-f2101325390a", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[16108, 336, 5130, 75, 130, "Message",ExpressionUUID->"f2eabf97-69a8-4b77-9100-9962a22c4ada", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[21241, 413, 1039, 18, 21, "Message",ExpressionUUID->"4a887f2d-d27a-446c-be43-04621c2bff89", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[22283, 433, 1181, 20, 21, "Message",ExpressionUUID->"ff4bc5fc-854f-489b-afaf-45c565a008d3", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[23467, 455, 1039, 18, 21, "Message",ExpressionUUID->"3f63e068-e730-49a3-af67-b5a14e0d0c58", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[24509, 475, 1181, 21, 21, "Message",ExpressionUUID->"36a5b4e2-9064-444b-aa5e-94a86996c362", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[25693, 498, 1039, 18, 21, "Message",ExpressionUUID->"2fe89592-f874-4cfb-93fa-795c4544ca70", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26735, 518, 1109, 19, 21, "Message",ExpressionUUID->"a2708204-1a49-4efc-8816-61aba56b18f8", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27847, 539, 1181, 20, 21, "Message",ExpressionUUID->"d51747a1-9163-47bc-a6ea-4315ab6f2d88", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29031, 561, 1112, 19, 21, "Message",ExpressionUUID->"2c2f6dbb-5955-43f6-b7c8-ad520c501aa0", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.svg new file mode 100644 index 0000000..b28474c --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.svg @@ -0,0 +1,132 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.xml new file mode 100644 index 0000000..800e4d5 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.hpp new file mode 100644 index 0000000..8d18d3a --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.hpp @@ -0,0 +1,165 @@ +#ifndef ACTIVITYDIAGRAMJOIN0_HPP_INCLUDED +#define ACTIVITYDIAGRAMJOIN0_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramJoin0.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 29 Aug 2019 14:48:02 +//! @brief And for a state machine +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramJoin0.nb*/ + +using namespace hopsan; + +class ActivityDiagramJoin0 : public ComponentQ +{ +private: + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + //outputVariables + //Expressions variables + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + //inputParameters pointers + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramJoin0(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + + //Add inputParammeters to the component + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //LocalExpressions + + //Expressions + qpn3 = onPositive(-0.5 + spn1*spn2 - spn3); + qpn1 = -qpn3; + qpn2 = -qpn3; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMJOIN0_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.nb new file mode 100644 index 0000000..7d5fe3b --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.nb @@ -0,0 +1,726 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 37541, 718] +NotebookOptionsPosition[ 34350, 643] +NotebookOutlinePosition[ 34778, 659] +CellTagsIndexPosition[ 34735, 656] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, 3.774794098262859*^9}}, + ExpressionUUID -> "5ee7c9b3-61b3-495d-947e-36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + ExpressionUUID -> "b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795592346754*^9, + 3.774861398577976*^9, 3.7748619525444*^9, 3.7753177856576447`*^9, + 3.776068537628119*^9, 3.776068854606236*^9, 3.7760688870627756`*^9, + 3.7760712654763637`*^9, 3.776071318759997*^9}, + ExpressionUUID -> "f7eb2186-9cf7-4c72-8ea5-01c96564841a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774797375685176*^9, + 3.7747973875893726`*^9}, {3.7760688172187753`*^9, + 3.7760688264662404`*^9}, {3.7760688832017593`*^9, 3.7760688836492944`*^9}}, + ExpressionUUID -> "f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955924119816`*^9, + 3.7748613986319213`*^9, 3.774861952601342*^9, 3.775317785722578*^9, + 3.7760685376510963`*^9, 3.776068854630206*^9, 3.776068887090747*^9, + 3.7760712655133266`*^9, 3.7760713187989573`*^9}, + ExpressionUUID -> "b0628de8-4240-4cb9-a759-c769c3d3e251"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + ExpressionUUID -> "96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Join", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.7550214968084235`*^9, 3.7550214976735325`*^9}, {3.7552807972398443`*^9, + 3.7552808064463525`*^9}, {3.7552808483581448`*^9, + 3.7552808485099845`*^9}, {3.765365251275384*^9, 3.7653652518263435`*^9}, { + 3.7747942042782946`*^9, 3.774794220390111*^9}}, + ExpressionUUID -> "088c7a70-e175-477e-9f3a-655c7cd3370d"], + +Cell["\<\ +Join (AND) function. The flow is either 0 or one in one time step. The wave \ +variables spn1 and spn2 are either 0 or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, 3.7747942042782946`*^9, { + 3.7747942713572884`*^9, 3.774794273096493*^9}, {3.776068772753235*^9, + 3.776068777840438*^9}}, + ExpressionUUID -> "6f15cb33-9e39-488c-92cb-ee7ba955af67"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.7550215020570135`*^9, + 3.7550215088340263`*^9}, {3.755280868192692*^9, 3.7552808942538214`*^9}, { + 3.76536525978136*^9, 3.7653652604361925`*^9}, {3.774794204279293*^9, + 3.77479422293149*^9}, 3.775317780594391*^9, 3.7760685292677374`*^9}, + ExpressionUUID -> "9335b084-863b-47bb-bc84-c039b71d3a5b"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550215143633256`*^9, 3.755031739579131*^9, + 3.755283201122441*^9, 3.7643432865421467`*^9, 3.764346904519914*^9, + 3.764347089430435*^9, 3.7653652772881794`*^9, 3.7653655961515565`*^9, { + 3.765366236453781*^9, 3.7653662585314226`*^9}, 3.765366761177063*^9, + 3.774794204279293*^9, 3.7747955925446033`*^9, 3.774861398721828*^9, + 3.774861952702238*^9, 3.775317785840455*^9, 3.776068537688058*^9, + 3.776068854683153*^9, 3.7760688871406927`*^9, 3.7760712655842524`*^9, + 3.776071318870884*^9}, + ExpressionUUID -> "49690cc8-5c40-48b5-b358-97a5175e4746"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "8", ",", "29", ",", "14", ",", "41", ",", + "58.8419153`9.522261631502142"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550215143633256`*^9, 3.755031739579131*^9, + 3.755283201122441*^9, 3.7643432865421467`*^9, 3.764346904519914*^9, + 3.764347089430435*^9, 3.7653652772881794`*^9, 3.7653655961515565`*^9, { + 3.765366236453781*^9, 3.7653662585314226`*^9}, 3.765366761177063*^9, + 3.774794204279293*^9, 3.7747955925446033`*^9, 3.774861398721828*^9, + 3.774861952702238*^9, 3.775317785840455*^9, 3.776068537688058*^9, + 3.776068854683153*^9, 3.7760688871406927`*^9, 3.7760712655842524`*^9, + 3.776071318874879*^9}, + ExpressionUUID -> "49690cc8-5c40-48b5-b358-97a5175e4746"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}}, + ExpressionUUID -> "2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell["\<\ +inputVariables = { + {event3, 1., double, \"event3 (trigg on value )\"} + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, 3.755031730677309*^9, 3.7747942042802925`*^9, { + 3.7760685513030233`*^9, 3.7760686784409633`*^9}, {3.7760703077523346`*^9, + 3.7760703432387514`*^9}, {3.7760708301710997`*^9, 3.7760708408820567`*^9}, + 3.7760712575515366`*^9, 3.7760713073891582`*^9}, + ExpressionUUID -> "2cb343b4-4a02-4069-b70f-d2246ecff4f8"], + +Cell["\<\ +inputParameters = { + {diffEvent, 0., double, \"\", \"event3, trigg on level(0) or flank(1)\"} + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, {3.7627272500188117`*^9, 3.7627273460548697`*^9}, + 3.7627275033008842`*^9, 3.7627280783297443`*^9, 3.76553961741498*^9, { + 3.7760708823393207`*^9, 3.776070932245875*^9}, 3.7760713073891582`*^9}, + ExpressionUUID -> "938657e9-f22d-4845-b3b8-9e4b7f5f1c06"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"qpn3", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{ + RowBox[{"spn1", " ", "spn2"}], "-", "spn3", "-", "0.5"}], "]"}]}], + ",", "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{"-", "qpn3"}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn2", "==", + RowBox[{"-", "qpn3"}]}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7550317093303185`*^9, + 3.7550317139985056`*^9}, {3.7643431906677704`*^9, + 3.7643431975270147`*^9}, {3.764343569262467*^9, 3.764343574978962*^9}, + 3.7747942042802925`*^9, {3.7747942627936115`*^9, 3.774794314605649*^9}, { + 3.7760711621119175`*^9, 3.7760711710417137`*^9}, {3.7760713129034986`*^9, + 3.7760713150632772`*^9}, 3.7760716703887568`*^9}, + ExpressionUUID -> "5c2a5e25-e670-491c-933e-302886292168"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7747942042813015`*^9}, + ExpressionUUID -> "91b365df-e70c-494b-bfc9-f2101325390a"], + +Cell[BoxData[ + TemplateBox[{ + "Part","partd", + "\"Part specification \\!\\(\\*RowBox[{RowBox[{\\\"{\\\", RowBox[{RowBox[{\ +\\\"qpn3\\\", \\\"\[Equal]\\\", RowBox[{\\\"onPositive\\\", \\\"[\\\", \ +RowBox[{RowBox[{\\\"-\\\", \\\"0.5`\\\"}], \\\"+\\\", RowBox[{\\\"spn1\\\", \ +\\\" \\\", \\\"spn2\\\"}], \\\"-\\\", \\\"spn3\\\"}], \\\"]\\\"}]}], \ +\\\",\\\", RowBox[{\\\"qpn1\\\", \\\"\[Equal]\\\", RowBox[{\\\"-\\\", \ +\\\"qpn3\\\"}]}], \\\",\\\", RowBox[{\\\"qpn2\\\", \\\"\[Equal]\\\", RowBox[{\ +\\\"-\\\", \\\"qpn3\\\"}]}], \\\",\\\", \\\"Null\\\"}], \\\"}\\\"}], \\\"\ +\[LeftDoubleBracket]\\\", RowBox[{\\\"4\\\", \\\",\\\", \\\"1\\\"}], \\\"\ +\[RightDoubleBracket]\\\"}]\\) is longer than depth of object.\"",2,254,141, + 16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319029719*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "Part","partd", + "\"Part specification \\!\\(\\*RowBox[{RowBox[{\\\"{\\\", RowBox[{RowBox[{\ +\\\"qpn3\\\", \\\"\[Equal]\\\", RowBox[{\\\"onPositive\\\", \\\"[\\\", \ +RowBox[{RowBox[{\\\"-\\\", \\\"0.5`\\\"}], \\\"+\\\", RowBox[{\\\"spn1\\\", \ +\\\" \\\", \\\"spn2\\\"}], \\\"-\\\", \\\"spn3\\\"}], \\\"]\\\"}]}], \ +\\\",\\\", RowBox[{\\\"qpn1\\\", \\\"\[Equal]\\\", RowBox[{\\\"-\\\", \ +\\\"qpn3\\\"}]}], \\\",\\\", RowBox[{\\\"qpn2\\\", \\\"\[Equal]\\\", RowBox[{\ +\\\"-\\\", \\\"qpn3\\\"}]}], \\\",\\\", \\\"Null\\\"}], \\\"}\\\"}], \\\"\ +\[LeftDoubleBracket]\\\", RowBox[{\\\"4\\\", \\\",\\\", \\\"1\\\"}], \\\"\ +\[RightDoubleBracket]\\\"}]\\) is longer than depth of object.\"",2,254,142, + 16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713190656815`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "Part","partd", + "\"Part specification \\!\\(\\*RowBox[{RowBox[{\\\"{\\\", RowBox[{RowBox[{\ +\\\"qpn3\\\", \\\"\[Equal]\\\", RowBox[{\\\"onPositive\\\", \\\"[\\\", \ +RowBox[{RowBox[{\\\"-\\\", \\\"0.5`\\\"}], \\\"+\\\", RowBox[{\\\"spn1\\\", \ +\\\" \\\", \\\"spn2\\\"}], \\\"-\\\", \\\"spn3\\\"}], \\\"]\\\"}]}], \ +\\\",\\\", RowBox[{\\\"qpn1\\\", \\\"\[Equal]\\\", RowBox[{\\\"-\\\", \ +\\\"qpn3\\\"}]}], \\\",\\\", RowBox[{\\\"qpn2\\\", \\\"\[Equal]\\\", RowBox[{\ +\\\"-\\\", \\\"qpn3\\\"}]}], \\\",\\\", \\\"Null\\\"}], \\\"}\\\"}], \\\"\ +\[LeftDoubleBracket]\\\", RowBox[{\\\"4\\\", \\\",\\\", \\\"1\\\"}], \\\"\ +\[RightDoubleBracket]\\\"}]\\) is longer than depth of object.\"",2,254,143, + 16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713190946517`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Part\\\", \\\"::\\\", \ +\\\"partd\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,254,144,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319123622*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramJoin0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramJoin0.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramJoin0.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\ +\[RightSkeleton]\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \ +\\\"]\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\ +\\\\\"portpose\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\ +\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\ +\"0.75`\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{RowBox[{\\\"\\\\\\\"t\\\\\\\"\\\", \\\"\[Ellipsis]\\\", \ +\\\"\\\\\\\"me\\\\\\\"\\\"}], \\\"\[Rule]\\\", RowBox[{\\\"\\\\\\\"\\\\\\\"\\\ +\", \\\"\[Ellipsis]\\\", \\\"\\\\\\\"\\\\\\\"\\\"}]}], \\\",\\\", \ +RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"icon\\\\\\\ +\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\ +\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramJoin0.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramJoin0.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\[LeftSkeleton]\\\", \\\"1\ +\\\", \\\"\[RightSkeleton]\\\"}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of \ +contents. The third item in an XMLElement must be a list of contents, even if \ +it is an empty list.\"",2,254,145,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319149595*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,254,146,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713191805625`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 254,147,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319207535*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,254,148,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319233508*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,254,149,16172176550883650673, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713192584825`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,254,150,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713192844553`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,254,151,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319310429*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 254,152,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.7760713193374023`*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,254,153,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.75502151456112*^9, 3.755031739742962*^9, + 3.7552832013172407`*^9, 3.7643432867375507`*^9, 3.764346904818359*^9, + 3.764347089689954*^9, 3.7653652773581076`*^9, 3.765365596257448*^9, { + 3.7653662365546765`*^9, 3.765366258654296*^9}, 3.7653667612969403`*^9, + 3.774794204282284*^9, 3.7747955928822556`*^9, 3.7748613988926506`*^9, + 3.7748619529329996`*^9, 3.775317786104183*^9, 3.776068537783958*^9, + 3.7760688548100224`*^9, 3.7760688872645655`*^9, 3.77607126582001*^9, + 3.776071319361377*^9}, + ExpressionUUID -> "c63178eb-ad74-47e1-aa06-c863621487a0"] +}, Open ]] +}, +WindowSize->{1224, 632}, +WindowMargins->{{Automatic, 236}, {Automatic, 138}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 270, 4, 101, "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[852, 28, 355, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1210, 36, 1211, 21, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2424, 59, 820, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3247, 73, 799, 15, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4049, 90, 848, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4900, 104, 279, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5182, 112, 593, 9, 70, "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5778, 123, 506, 9, 30, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6287, 134, 1838, 39, 202, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8128, 175, 807, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8938, 189, 873, 15, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9814, 206, 1049, 20, 107, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10866, 228, 866, 15, 68, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11735, 245, 755, 13, 68, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[12493, 260, 1543, 29, 107, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14039, 291, 221, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14263, 297, 1520, 24, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15786, 323, 1522, 24, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[17311, 349, 1522, 24, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[18836, 375, 1018, 17, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[19857, 394, 6272, 93, 95, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26132, 489, 952, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27087, 507, 1092, 18, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[28182, 527, 950, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29135, 545, 1094, 19, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[30232, 566, 952, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[31187, 584, 1022, 17, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[32212, 603, 1094, 18, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[33309, 623, 1025, 17, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.svg new file mode 100644 index 0000000..2d2e778 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.svg @@ -0,0 +1,113 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.xml new file mode 100644 index 0000000..07b0a3c --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin0.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin1.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin1.svg new file mode 100644 index 0000000..12dbb87 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoin1.svg @@ -0,0 +1,143 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoinN.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoinN.hpp new file mode 100644 index 0000000..2aa05fc --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramJoinN.hpp @@ -0,0 +1,129 @@ +/*----------------------------------------------------------------------------- + This source file is a part of Hopsan + + Copyright (c) 2009 to present year, Hopsan Group + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramANDmulti.hpp +//! @author Petter Krus +//! @date 2018-12-31 +//! based on ElectricCapacitanceMultiPort.hpp by Björn Eriksson +//! @brief Contains a multi in join Component +//! + +#ifndef ACTIVITYDIAGRAMJOINN_HPP_INCLUDED +#define ACTIVITYDIAGRAMJOINN_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A ActivityDiagram AND multi port component + //! @ingroup ActivityDiagram + //! + class ActivityDiagramJoinN : public ComponentQ + { + + private: + std::vector mvpN_s, mvpN_q; + size_t mNumPorts; + Port *mpPpn1; + Port *mpPpn2; + + //Port Ppn2 variable + double s2; + double q2; + //inputVariables + double event3; + //Expressions variables + double dEvent3; + double oldEvent3; + + //Port Ppn2 pointer + double *mpP_s2; + double *mpP_q2; + //inputVariables pointers + double *mpevent3; + //inputParameters pointers + double *mpdiffEvent; + + + public: + static Component *Creator() + { + return new ActivityDiagramJoinN(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + } + + void initialize() + { + //Port Ppn1 + mNumPorts = mpPpn1->getNumPorts(); + mvpN_s.resize(mNumPorts); + mvpN_q.resize(mNumPorts); + + for (size_t i=0; i + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.cc b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.cc new file mode 100644 index 0000000..1486b25 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.cc @@ -0,0 +1,51 @@ +#include +#include "ComponentEssentials.h" +#include "ActivityDiagramInitiateState.hpp" +#include "ActivityDiagramEdge.hpp" +#include "ActivityDiagramAction.hpp" +#include "ActivityDiagramActionN.hpp" +#include "ActivityDiagramDecision.hpp" +#include "ActivityDiagramForkN.hpp" +#include "ActivityDiagramJoinN.hpp" +#include "ActivityDiagramMergeN.hpp" +#include "ActivityDiagramFork.hpp" +#include "ActivityDiagramJoin0.hpp" +#include "ActivityDiagramJoin.hpp" +#include "ActivityDiagramMerge0.hpp" +#include "ActivityDiagramMerge.hpp" +#include "ActivityDiagramMergeN.hpp" +#include "ActivityDiagramFinal.hpp" +#include "ActivityDiagramFinalNode.hpp" + +using namespace hopsan; + +extern "C" DLLEXPORT void register_contents(ComponentFactory* pComponentFactory, NodeFactory* pNodeFactory) +{ + //Register Components + pComponentFactory->registerCreatorFunction("ActivityDiagramInitiateState", ActivityDiagramInitiateState::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramEdge", ActivityDiagramEdge::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramAction", ActivityDiagramAction::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramActionN", ActivityDiagramActionN::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramDecision", ActivityDiagramDecision::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramForkN", ActivityDiagramForkN::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramJoinN", ActivityDiagramJoinN::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramMergeN", ActivityDiagramMergeN::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramFork", ActivityDiagramFork::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramJoin0", ActivityDiagramJoin0::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramJoin", ActivityDiagramJoin::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramMerge0", ActivityDiagramMerge0::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramMerge", ActivityDiagramMerge::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramMergeN", ActivityDiagramMergeN::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramFinal", ActivityDiagramFinal::Creator); + pComponentFactory->registerCreatorFunction("ActivityDiagramFinalNode", ActivityDiagramFinalNode::Creator); + + //Register custom nodes (if any) + HOPSAN_UNUSED(pNodeFactory); +} + +extern "C" DLLEXPORT void get_hopsan_info(HopsanExternalLibInfoT *pHopsanExternalLibInfo) +{ + pHopsanExternalLibInfo->hopsanCoreVersion = (char*)HOPSANCOREVERSION; + pHopsanExternalLibInfo->libCompiledDebugRelease = (char*)DEBUGRELEASECOMPILED; + pHopsanExternalLibInfo->libName = (char*)"ActivityDiagramLibrary"; +} diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.dll b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.dll new file mode 100644 index 0000000..336048d Binary files /dev/null and b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.dll differ diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.pro b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.pro new file mode 100644 index 0000000..7ed85d8 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.pro @@ -0,0 +1,50 @@ +# QT -= core gui, means that we should not link the default qt libs into the component +# Template = lib, means that we want to build a library (.dll or .so) +QT -= core gui +TEMPLATE = lib + +# TARGET is the name of the compiled lib, (.dll or .so will be added automatically) +# Change this to the name of YOUR lib +TARGET = devTestLib + +# Destination for the compiled dll. $${PWD}/ means the same directory as this .pro file, even if you use shadow build +DESTDIR = $${PWD}/ + +# The location to search for the Hopsan include files, by specifying the path here, you dont need to do this everywhere in all of your component .hpp files +# You can also add additional paths for eg. your own Utility functions, just add additional INCLUDEPATH *= ... lines. +# *= Means append unique +INCLUDEPATH *= $${PWD}/../../../HopsanCore/include/ + +# The location of the HopsanCore .dll or .so file, needed to link against when compiling your library +LIBS *= -L$${PWD}/../../../bin + +# Special options for deug and release mode. This will link the correct HopsanCore .dll or .so +# In debug mode HopsanCore has the debug extension _d +include(hopsanDebugReleaseCompile.prf) + +# ------------------------------------------------- +# Project files +# ------------------------------------------------- +SOURCES += \ + TestLib.cc + +HEADERS += \ + ActivityDiagramInitiateState.hpp + ActivityDiagramEdge.hpp + ActivityDiagramActionN.hpp + ActivityDiagramAction.hpp + ActivityDiagramDecision.hpp + ActivityDiagramJoinN.hpp + ActivityDiagramForkN.hpp + ActivityDiagramJoin0.hpp + ActivityDiagramJoin.hpp + ActivityDiagramFork.hpp + ActivityDiagramMerge0.hpp + ActivityDiagramMerge.hpp + ActivityDiagramMergeN.hpp + ActivityDiagramFinal.hpp + ActivityDiagramFinalNode.hpp + + +OTHER_FILES += \ + hopsanDebugReleaseCompile.prf diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.xml new file mode 100644 index 0000000..be04e13 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLib.xml @@ -0,0 +1,42 @@ + + + afd1b9b5-0b66-4d17-9e90-1da59a2be242 + ActivityDiagramLib + + -std=c++11 + + ActivityDiagramLib + ActivityDiagramLib.cc + + ActivityDiagramInitiateState.hpp + ActivityDiagramEdge.hpp + ActivityDiagramAction.hpp + ActivityDiagramActionN.hpp + ActivityDiagramDecision.hpp + ActivityDiagramForkN.hpp + ActivityDiagramJoinN.hpp + ActivityDiagramMergeN.hpp + ActivityDiagramFork.hpp + ActivityDiagramJoin0.hpp + ActivityDiagramJoin.hpp + ActivityDiagramMerge0.hpp + ActivityDiagramMerge.hpp + ActivityDiagramFinal.hpp + ActivityDiagramFinalNode.hpp + + ActivityDiagramInitiateState.xml + ActivityDiagramActionN.xml + ActivityDiagramAction.xml + ActivityDiagramDecision.xml + ActivityDiagramEdge.xml + ActivityDiagramFinalNode.xml + ActivityDiagramFinal.xml + ActivityDiagramForkN.xml + ActivityDiagramFork.xml + ActivityDiagramJoin0.xml + ActivityDiagramJoinN.xml + ActivityDiagramJoin.xml + ActivityDiagramMerge0.xml + ActivityDiagramMergeN.xml + ActivityDiagramMerge.xml + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLibrary.dll b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLibrary.dll new file mode 100644 index 0000000..d69ff5b Binary files /dev/null and b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramLibrary.dll differ diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.hpp new file mode 100644 index 0000000..71829ee --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.hpp @@ -0,0 +1,195 @@ +#ifndef ACTIVITYDIAGRAMMERGE_HPP_INCLUDED +#define ACTIVITYDIAGRAMMERGE_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramMerge.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 29 Aug 2019 14:30:46 +//! @brief Merge with triggers for activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, StateMachine0, \ +ActivityDiagram, ActivityDiagram}/ActivityDiagramMerge.nb*/ + +using namespace hopsan; + +class ActivityDiagramMerge : public ComponentQ +{ +private: + double diffevent; + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + double event1; + double event2; + //outputVariables + //InitialExpressions variables + double oldEvent1; + double oldEvent2; + //Expressions variables + double dEvent1; + double dEvent2; + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpevent1; + double *mpevent2; + //inputParameters pointers + double *mpdiffevent; + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramMerge(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + addInputVariable("event1","event 1 ","",1.,&mpevent1); + addInputVariable("event2","event 2 ","",1.,&mpevent2); + + //Add inputParammeters to the component + addInputVariable("diffevent", "Trigg on level (0) or flank (1)", \ +"", 0.,&mpdiffevent); + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + event1 = (*mpevent1); + event2 = (*mpevent2); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + //InitialExpressions + oldEvent1 = event1; + oldEvent2 = event2; + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + event1 = (*mpevent1); + event2 = (*mpevent2); + + //Read inputParameters from nodes + diffevent = (*mpdiffevent); + + //LocalExpressions + + //Expressions + dEvent1 = onPositive(-0.5 + event1 - diffevent*oldEvent1); + dEvent2 = onPositive(-0.5 + event2 - diffevent*oldEvent2); + qpn1 = -(dEvent1*onPositive(-0.5 + spn1 - spn3)); + qpn2 = -(dEvent2*onPositive(0.5 + qpn1)*onPositive(-0.5 + spn2 - \ +spn3)); + qpn3 = onPositive(-0.5 + onPositive(-0.5 - qpn1) + onPositive(-0.5 - \ +qpn2)); + oldEvent1 = event1; + oldEvent2 = event2; + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMMERGE_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.nb new file mode 100644 index 0000000..6a5895e --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.nb @@ -0,0 +1,821 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 42264, 813] +NotebookOptionsPosition[ 39039, 737] +NotebookOutlinePosition[ 39496, 754] +CellTagsIndexPosition[ 39453, 751] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, 3.774794098262859*^9}}, + ExpressionUUID -> "5ee7c9b3-61b3-495d-947e-36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + ExpressionUUID -> "b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795581896713*^9, + 3.7747986777531595`*^9, 3.774798837507168*^9, 3.7748614276997967`*^9, + 3.7748619672501326`*^9, {3.7748622394111714`*^9, 3.774862251182107*^9}, + 3.7748623403373017`*^9, 3.7754917893881674`*^9, 3.776070646525416*^9}, + ExpressionUUID -> "f7eb2186-9cf7-4c72-8ea5-01c96564841a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774797375685176*^9, + 3.7747973875893726`*^9}, {3.7760688172187753`*^9, + 3.7760688264662404`*^9}, {3.7760688832017593`*^9, 3.7760688836492944`*^9}}, + ExpressionUUID -> "f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine0\\\\ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955819626927`*^9, + 3.7747986777851257`*^9, 3.774798837541133*^9, 3.7748614277577357`*^9, + 3.7748619673110695`*^9, {3.774862239477104*^9, 3.774862251248041*^9}, + 3.774862340403417*^9, 3.7754917894141517`*^9, 3.7760706465633698`*^9}, + ExpressionUUID -> "b0628de8-4240-4cb9-a759-c769c3d3e251"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + ExpressionUUID -> "96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Merge", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.7549932967387524`*^9, 3.754993297147331*^9}, {3.754993452569092*^9, + 3.7549934529137363`*^9}, {3.7552829494329333`*^9, 3.7552829554537253`*^9}, + 3.755372579530821*^9, {3.765365387482224*^9, 3.7653653881771164`*^9}, + 3.7747983306164637`*^9, 3.7747986736373167`*^9, 3.7754917486163588`*^9}, + ExpressionUUID -> "9d4f453e-9c72-4000-9122-ecf47f5aa6af"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1,qpn2 and qpn3, are either \ +0 or 1 in one time step. The state variables spn1, spn2 and spn3 are either 0 \ +or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940079196377`*^9}, 3.774794209791312*^9}, + ExpressionUUID -> "bdc3e281-aa00-44be-ae84-967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"brief", "=", "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.7550214271472473`*^9, + 3.7550214275618167`*^9}, {3.755282886208119*^9, 3.755282894223857*^9}, { + 3.7552829304305267`*^9, 3.7552829350098047`*^9}, 3.755372577184243*^9, + 3.76536539267952*^9, {3.774798658558407*^9, 3.7747986736373167`*^9}, + 3.7753177220186896`*^9, {3.7754917480639286`*^9, 3.775491774528488*^9}}, + ExpressionUUID -> "d8e297df-a6c2-45e1-bbf9-562a2f6f4d24"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214432906017`*^9, 3.7551057445882325`*^9, + 3.7551059975064726`*^9, 3.75537250361609*^9, {3.755372572239339*^9, + 3.755372584719471*^9}, 3.762728722318306*^9, 3.762728941413127*^9, + 3.762728995980014*^9, 3.7627294861694837`*^9, 3.762729629909155*^9, + 3.7632029998745313`*^9, 3.7653654080479727`*^9, 3.7653656648558197`*^9, + 3.7653658265475893`*^9, 3.7653667369086075`*^9, 3.7655559512014737`*^9, + 3.765556093964796*^9, 3.7659543655311265`*^9, 3.765954400179384*^9, + 3.7659545128990993`*^9, 3.765954576818159*^9, 3.765954945408914*^9, + 3.7659551762607627`*^9, 3.765979013014917*^9, 3.7659791492154098`*^9, + 3.765979290752405*^9, {3.7747986736373167`*^9, 3.7747986778500595`*^9}, + 3.7747988376050696`*^9, 3.7748614278638554`*^9, 3.774861967432947*^9, { + 3.7748622395999775`*^9, 3.7748622513769073`*^9}, 3.7748623405347652`*^9, + 3.7754917894640894`*^9, 3.7760706466322966`*^9}, + ExpressionUUID -> "bb530fb1-b66b-4cbc-9f7e-1462efedf857"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "8", ",", "29", ",", "14", ",", "30", ",", + "46.6033273`9.420991788461784"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214432906017`*^9, 3.7551057445882325`*^9, + 3.7551059975064726`*^9, 3.75537250361609*^9, {3.755372572239339*^9, + 3.755372584719471*^9}, 3.762728722318306*^9, 3.762728941413127*^9, + 3.762728995980014*^9, 3.7627294861694837`*^9, 3.762729629909155*^9, + 3.7632029998745313`*^9, 3.7653654080479727`*^9, 3.7653656648558197`*^9, + 3.7653658265475893`*^9, 3.7653667369086075`*^9, 3.7655559512014737`*^9, + 3.765556093964796*^9, 3.7659543655311265`*^9, 3.765954400179384*^9, + 3.7659545128990993`*^9, 3.765954576818159*^9, 3.765954945408914*^9, + 3.7659551762607627`*^9, 3.765979013014917*^9, 3.7659791492154098`*^9, + 3.765979290752405*^9, {3.7747986736373167`*^9, 3.7747986778500595`*^9}, + 3.7747988376050696`*^9, 3.7748614278638554`*^9, 3.774861967432947*^9, { + 3.7748622395999775`*^9, 3.7748622513769073`*^9}, 3.7748623405347652`*^9, + 3.7754917894640894`*^9, 3.776070646638291*^9}, + ExpressionUUID -> "bb530fb1-b66b-4cbc-9f7e-1462efedf857"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}}, + ExpressionUUID -> "2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", " ", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"{", + RowBox[{ + "event1", ",", " ", "1.", ",", " ", "double", ",", " ", "\"\<\>\"", ",", + " ", "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "event2", ",", " ", "1.", ",", " ", "double", ",", " ", "\"\<\>\"", ",", + " ", "\"\\""}], "}"}]}], "\n", " ", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, 3.7549933065196686`*^9, {3.7553334050165496`*^9, + 3.7553334446716647`*^9}, {3.7627026686193905`*^9, 3.762702670838029*^9}, { + 3.7627027196525707`*^9, 3.7627027226382403`*^9}, {3.762728482505171*^9, + 3.7627284849986467`*^9}, 3.774798673638316*^9}, + ExpressionUUID -> "f073027b-0651-4a76-8093-b13b81390d0b"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "diffevent", ",", "0.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.762728501412943*^9, 3.7627285128314185`*^9}, { + 3.7627285870617857`*^9, 3.762728591136469*^9}, 3.7747986736393175`*^9}, + ExpressionUUID -> "526a0e78-dfa9-4844-8861-722896780dba"], + +Cell[BoxData[ + RowBox[{"initialExpressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"oldEvent1", "\[Equal]", "event1"}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent2", "\[Equal]", "event2"}]}], "\[IndentingNewLine]", + "}"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7655533786392612`*^9, 3.765553382135273*^9}, + 3.765553549418847*^9, {3.765555534690852*^9, 3.765555545228863*^9}, { + 3.7655560740431547`*^9, 3.7655560873095894`*^9}}, + ExpressionUUID -> "c21e7961-5a84-45f3-af61-b43c2481c92c"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + RowBox[{"oldEvent1", "\[Equal]", "event1"}], ",", + RowBox[{"oldEvent2", "\[Equal]", "event2"}]}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7655559532852836`*^9, 3.7655560954859285`*^9, 3.765954365574082*^9, + 3.765954400227334*^9, 3.7659545129450517`*^9, 3.76595457686611*^9, + 3.765954945457864*^9, 3.765955176309712*^9, 3.765979013076853*^9, + 3.7659791492833395`*^9, 3.7659792908183327`*^9, {3.7747986736393175`*^9, + 3.774798677972932*^9}, 3.7747988377319365`*^9, 3.7748614280806327`*^9, + 3.774861967682685*^9, {3.774862239871213*^9, 3.774862251628648*^9}, + 3.774862340780019*^9, 3.7754917895629864`*^9, 3.7760706467781477`*^9}, + ExpressionUUID -> "01c870b8-aaba-4716-af93-eff1bce22607"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent1", "==", + RowBox[{"onPositive", "[", + RowBox[{"event1", "-", + RowBox[{"diffevent", " ", "oldEvent1"}], "-", "0.5"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"dEvent2", "==", + RowBox[{"onPositive", "[", + RowBox[{"event2", "-", + RowBox[{"diffevent", " ", "oldEvent2"}], " ", "-", "0.5"}], "]"}]}], + ",", "\[IndentingNewLine]", + RowBox[{"qpn3", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{ + RowBox[{"dEvent1", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "spn3", "-", "0.5"}], "]"}]}], "+", " ", + RowBox[{"dEvent2", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn2", "-", "spn3", "-", "0.5"}], "]"}]}], "-", "0.5"}], + "]"}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{ + RowBox[{"-", "qpn3"}], " ", "dEvent1"}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn2", "==", + RowBox[{ + RowBox[{"-", "qpn3"}], " ", "dEvent2", " ", + RowBox[{"onPositive", "[", + RowBox[{"1", "+", "qpn1", "-", "0.5"}], "]"}]}]}], ",", + "\[IndentingNewLine]", + RowBox[{"oldEvent1", "==", "event1"}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent2", "==", "event2"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7549933379472666`*^9, + 3.7549934278415847`*^9}, 3.7549934587237473`*^9, {3.755105685321338*^9, + 3.755105691343128*^9}, {3.7551058806949067`*^9, 3.7551059297583227`*^9}, { + 3.7553333550001173`*^9, 3.7553333899580746`*^9}, {3.755333477216114*^9, + 3.755333571207209*^9}, {3.755333612470665*^9, 3.7553336471189427`*^9}, { + 3.7627026868999696`*^9, 3.762702690040387*^9}, {3.7627285307005577`*^9, + 3.762728598724123*^9}, {3.762728891838689*^9, 3.762728927807674*^9}, { + 3.7627294714118166`*^9, 3.7627294758742723`*^9}, {3.7632029790894814`*^9, + 3.7632029908427324`*^9}, {3.7655560484177923`*^9, + 3.7655560675078773`*^9}, {3.774798378062895*^9, 3.774798386262143*^9}, + 3.7747984458280263`*^9, {3.7747985315413647`*^9, 3.774798534616194*^9}, + 3.7747986736393175`*^9, {3.7760704479443293`*^9, 3.7760704713202305`*^9}}, + ExpressionUUID -> "add8a19a-4b57-4e4f-b179-d378f696ba99"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{ + RowBox[{"gez", "[", "x_", "]"}], ":=", + RowBox[{"onPositive", "[", + RowBox[{"x", "-", "0.5"}], "]"}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{ + RowBox[{"not", "[", "x_", "]"}], ":=", + RowBox[{"gez", "[", + RowBox[{"1", "-", "x"}], "]"}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{ + RowBox[{"or", "[", + RowBox[{"x1_", ",", "x2_"}], "]"}], ":=", " ", + RowBox[{"gez", "[", " ", + RowBox[{ + RowBox[{"gez", "[", "x1", "]"}], "+", " ", + RowBox[{"gez", "[", "x2", "]"}]}], "]"}]}], ";"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7659535016962757`*^9, 3.765953537227621*^9}, { + 3.765953591698428*^9, 3.765953633491314*^9}, {3.7659537776016474`*^9, + 3.7659539171926427`*^9}, {3.7659541480864477`*^9, 3.765954159366811*^9}, { + 3.765954190309889*^9, 3.7659541911090636`*^9}, {3.765954243895609*^9, + 3.765954287252881*^9}, {3.7659543284363947`*^9, 3.765954333668998*^9}, + 3.765955249245471*^9, {3.7659788223116503`*^9, 3.7659788600786896`*^9}, { + 3.7659789102459354`*^9, 3.7659789340304003`*^9}, {3.7659792402524962`*^9, + 3.7659792413014126`*^9}, {3.7747984022434483`*^9, 3.774798423106389*^9}, { + 3.774798465435588*^9, 3.7747984916353693`*^9}, {3.7747985356591177`*^9, + 3.774798567507405*^9}, {3.774798608475299*^9, 3.774798613738011*^9}, + 3.774798673640315*^9}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dEvent1", "==", + RowBox[{"gez", "[", + RowBox[{"event1", "-", + RowBox[{"diffevent", " ", "oldEvent1"}]}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"dEvent2", "==", + RowBox[{"gez", "[", + RowBox[{"event2", "-", + RowBox[{"diffevent", " ", "oldEvent2"}]}], " ", "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn1", "\[Equal]", + RowBox[{ + RowBox[{"-", "dEvent1"}], " ", + RowBox[{"gez", "[", + RowBox[{"spn1", "-", "spn3"}], "]"}]}]}], " ", ",", + "\[IndentingNewLine]", + RowBox[{"qpn2", "\[Equal]", + RowBox[{ + RowBox[{"-", "dEvent2"}], " ", + RowBox[{"gez", "[", + RowBox[{"spn2", "-", "spn3"}], "]"}], " ", + RowBox[{"not", "[", + RowBox[{"-", "qpn1"}], "]"}]}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn3", "\[Equal]", + RowBox[{"or", "[", + RowBox[{ + RowBox[{"-", "qpn1"}], ",", + RowBox[{"-", "qpn2"}]}], "]"}]}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent1", "==", "event1"}], ",", "\[IndentingNewLine]", + RowBox[{"oldEvent2", "==", "event2"}]}], "\[IndentingNewLine]", "}"}]}], + ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7549933379472666`*^9, + 3.7549934278415847`*^9}, 3.7549934587237473`*^9, {3.755105685321338*^9, + 3.755105691343128*^9}, {3.7551058806949067`*^9, 3.7551059297583227`*^9}, { + 3.7553333550001173`*^9, 3.7553333899580746`*^9}, {3.755333477216114*^9, + 3.755333571207209*^9}, {3.755333612470665*^9, 3.7553336471189427`*^9}, { + 3.7627026868999696`*^9, 3.762702690040387*^9}, {3.7627285307005577`*^9, + 3.762728598724123*^9}, {3.762728891838689*^9, 3.762728927807674*^9}, { + 3.7627294714118166`*^9, 3.7627294758742723`*^9}, {3.7632029790894814`*^9, + 3.7632029908427324`*^9}, {3.7655560484177923`*^9, + 3.7655560675078773`*^9}, {3.7659539527299805`*^9, + 3.7659539580474944`*^9}, {3.765953990560954*^9, 3.7659541210473413`*^9}, { + 3.765954203223567*^9, 3.765954204038726*^9}, {3.7659543947419925`*^9, + 3.7659543959437532`*^9}, {3.765954499150284*^9, 3.765954508435705*^9}, { + 3.7659545709552073`*^9, 3.765954573578501*^9}, 3.7659551706705313`*^9, { + 3.765978868000518*^9, 3.765978893848853*^9}, {3.765978938256042*^9, + 3.765978977975065*^9}, {3.7659791387911654`*^9, 3.76597914548526*^9}, { + 3.7659792427329383`*^9, 3.76597925615609*^9}, {3.774798467247336*^9, + 3.774798502673746*^9}, {3.774798579462903*^9, 3.774798600630599*^9}, + 3.774798638403225*^9, 3.774798673640315*^9, {3.7760705201826525`*^9, + 3.7760705288696933`*^9}}, + ExpressionUUID -> "add8a19a-4b57-4e4f-b179-d378f696ba99"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.774798673640315*^9}, + ExpressionUUID -> "c36604a9-382b-4358-abaf-68df6f6c8e9a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramMerge\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramMerge.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", RowBox[{\\\"\ +\[LeftSkeleton]\\\", \\\"4\\\", \\\"\[RightSkeleton]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{\\\"\\\\\\\"version\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"0.1\\\\\\\"\\\"}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\ +\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge.svg\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\ +\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ON\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\ +\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramMerge.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\[LeftSkeleton]\ +\\\", \\\"1\\\", \\\"\[RightSkeleton]\\\"}], \\\"]\\\"}]}], \\\"}\\\"}]}], \\\ +\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of contents. The third item in an \ +XMLElement must be a list of contents, even if it is an empty list.\"",2,161, + 83,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706469609585`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,161,84,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706469969215`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 161,85,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706470238934`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,161,86,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706470488677`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,161,87,16172176550883650673, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706470748405`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,161,88,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706470998144`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,161,89,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706471257877`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 161,90,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.7760706471517615`*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,161,91,16172176550883650673,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725041065826`*^9, {3.7553725725680017`*^9, + 3.7553725849122725`*^9}, 3.762728722625156*^9, 3.7627289418258924`*^9, + 3.762728996274845*^9, 3.7627294867951202`*^9, 3.762729630210981*^9, + 3.7653654082008142`*^9, 3.7653656650765905`*^9, 3.7653658267593718`*^9, + 3.765366737111397*^9, 3.765555954814411*^9, 3.7655560971309924`*^9, + 3.765954366034607*^9, 3.7659544003462114`*^9, 3.765954513068924*^9, + 3.7659545769829893`*^9, 3.7659549456007166`*^9, 3.7659551764485693`*^9, + 3.76597901324568*^9, 3.765979149423196*^9, 3.7659792909611835`*^9, { + 3.7747986736413155`*^9, 3.7747986784614277`*^9}, 3.774798837905756*^9, + 3.7748614283653383`*^9, 3.774861968070548*^9, {3.7748622402757936`*^9, + 3.7748622519223447`*^9}, 3.7748623411256633`*^9, 3.7754917897228217`*^9, + 3.776070647181732*^9}, + ExpressionUUID -> "06d34eee-160d-4e53-9f1d-4c505a1da00a"] +}, Open ]] +}, +WindowSize->{912, 700}, +WindowMargins->{{452, Automatic}, {122, Automatic}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +Magnification:>1.1 Inherited, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 270, 4, 111, "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[852, 28, 355, 6, 33, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1210, 36, 1211, 21, 56, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2424, 59, 852, 12, 33, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3279, 73, 799, 15, 56, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4081, 90, 874, 12, 33, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4958, 104, 279, 6, 33, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5240, 112, 636, 9, 78, "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5879, 123, 576, 10, 53, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6458, 135, 1935, 41, 232, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8396, 178, 1212, 17, 33, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9611, 197, 1276, 20, 33, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10890, 219, 1049, 20, 122, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11942, 241, 1257, 24, 100, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13202, 267, 567, 12, 78, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13772, 281, 584, 11, 100, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14359, 294, 807, 14, 33, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[15169, 310, 2975, 57, 232, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[18147, 369, 1425, 30, 78, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[19575, 401, 3349, 64, 210, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[22927, 467, 219, 4, 33, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[23149, 473, 4623, 68, 138, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27775, 543, 1332, 21, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[29110, 566, 1474, 23, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[30587, 591, 1332, 21, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[31922, 614, 1474, 24, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[33399, 640, 1332, 21, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[34734, 663, 1404, 22, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[36141, 687, 1474, 23, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[37618, 712, 1405, 22, 23, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.svg new file mode 100644 index 0000000..5616b90 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.svg @@ -0,0 +1,133 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.xml new file mode 100644 index 0000000..550c31d --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.hpp new file mode 100644 index 0000000..0f03429 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.hpp @@ -0,0 +1,165 @@ +#ifndef ACTIVITYDIAGRAMMERGE0_HPP_INCLUDED +#define ACTIVITYDIAGRAMMERGE0_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ActivityDiagramMerge0.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Thu 22 Aug 2019 21:43:02 +//! @brief Merge without triggers for activity diagram +//! @ingroup ActivityDiagramComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, H:, PettersDropbox, Dropbox, HopsanComponents, ActivityDiagram, \ +ActivityDiagram}/ActivityDiagramMerge0.nb*/ + +using namespace hopsan; + +class ActivityDiagramMerge0 : public ComponentQ +{ +private: + Port *mpPpn1; + Port *mpPpn2; + Port *mpPpn3; + int mNstep; + //Port Ppn1 variable + double spn1; + double qpn1; + //Port Ppn2 variable + double spn2; + double qpn2; + //Port Ppn3 variable + double spn3; + double qpn3; +//==This code has been autogenerated using Compgen== + //inputVariables + //outputVariables + //Expressions variables + //Port Ppn1 pointer + double *mpP_spn1; + double *mpP_qpn1; + //Port Ppn2 pointer + double *mpP_spn2; + double *mpP_qpn2; + //Port Ppn3 pointer + double *mpP_spn3; + double *mpP_qpn3; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + //inputParameters pointers + //outputVariables pointers + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ActivityDiagramMerge0(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + + //Add ports to the component + mpPpn1=addPowerPort("Ppn1","NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + mpPpn3=addPowerPort("Ppn3","NodePetriNet"); + //Add inputVariables to the component + + //Add inputParammeters to the component + //Add outputVariables to the component + +//==This code has been autogenerated using Compgen== + //Add constantParameters + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Ppn1 + mpP_spn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::State); + mpP_qpn1=getSafeNodeDataPtr(mpPpn1, NodePetriNet::Flow); + //Port Ppn2 + mpP_spn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::State); + mpP_qpn2=getSafeNodeDataPtr(mpPpn2, NodePetriNet::Flow); + //Port Ppn3 + mpP_spn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::State); + mpP_qpn3=getSafeNodeDataPtr(mpPpn3, NodePetriNet::Flow); + + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + qpn1 = (*mpP_qpn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + qpn2 = (*mpP_qpn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + qpn3 = (*mpP_qpn3); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //Read outputVariables from nodes + +//==This code has been autogenerated using Compgen== + + + //Initialize delays + + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + //Read variables from nodes + //Port Ppn1 + spn1 = (*mpP_spn1); + //Port Ppn2 + spn2 = (*mpP_spn2); + //Port Ppn3 + spn3 = (*mpP_spn3); + + //Read inputVariables from nodes + + //Read inputParameters from nodes + + //LocalExpressions + + //Expressions + qpn3 = onPositive(spn1 + spn2 - spn3); + qpn1 = -(qpn3*onPositive(-0.5 + spn1)); + qpn2 = -(qpn3*onPositive(0.5 + qpn1)*onPositive(-0.5 + spn2)); + + //Calculate the delayed parts + + + //Write new values to nodes + //Port Ppn1 + (*mpP_qpn1)=qpn1; + //Port Ppn2 + (*mpP_qpn2)=qpn2; + //Port Ppn3 + (*mpP_qpn3)=qpn3; + //outputVariables + + //Update the delayed variabels + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ACTIVITYDIAGRAMMERGE0_HPP_INCLUDED diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.nb b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.nb new file mode 100644 index 0000000..45adabc --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.nb @@ -0,0 +1,624 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 32492, 616] +NotebookOptionsPosition[ 29781, 551] +NotebookOutlinePosition[ 30208, 567] +CellTagsIndexPosition[ 30165, 564] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Component Generation", "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7627280721197987`*^9, 3.762728097973707*^9}, { + 3.7747940713991594`*^9, 3.774794098262859*^9}}, + ExpressionUUID -> "5ee7c9b3-61b3-495d-947e-36f10d487fd4"], + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], + "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.5757727777685804`*^9, 3.575772792541806*^9}, { + 3.5757728423954945`*^9, 3.5757728498367076`*^9}, {3.57577333888545*^9, + 3.5757733706315055`*^9}, 3.5757734316206255`*^9, {3.575776746610216*^9, + 3.57577674854722*^9}, {3.5758034373456383`*^9, 3.5758034687537785`*^9}, { + 3.576215299790524*^9, 3.576215340163597*^9}, {3.5762155444425898`*^9, + 3.576215547684914*^9}, 3.5762159940865498`*^9, 3.5762161254666862`*^9, { + 3.576244738757578*^9, 3.5762447467603917`*^9}, {3.5764733859773207`*^9, + 3.576473408313554*^9}, {3.7535327446515784`*^9, 3.753532801407033*^9}, { + 3.753533115099475*^9, 3.7535331229782906`*^9}, {3.7549775904983587`*^9, + 3.754977604666751*^9}, 3.754977679553543*^9, 3.7627280783237514`*^9, + 3.7627282130049376`*^9}, + ExpressionUUID -> "b61e84a1-9117-4d95-854e-6432998655f4"], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +StateMachine\\\\StateMachineEl\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.755325282964382*^9, 3.7626813134204435`*^9, 3.7626839961876745`*^9, { + 3.7627280783237514`*^9, 3.762728082244718*^9}, 3.762728231909116*^9, + 3.77478246431944*^9, {3.7747827023014145`*^9, 3.7747827237305226`*^9}, + 3.774782958441588*^9, {3.774783279023978*^9, 3.774783307379316*^9}, + 3.774783356326459*^9, 3.7747834532823944`*^9, 3.774795572931881*^9, + 3.774795612385293*^9, 3.774861408366062*^9, 3.7748619624159155`*^9, + 3.7748622245843167`*^9, 3.7748640394382243`*^9, 3.7753177662699428`*^9, + 3.775491732568901*^9, 3.775491782033749*^9}, + ExpressionUUID -> "f7eb2186-9cf7-4c72-8ea5-01c96564841a"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774862167050089*^9, + 3.7748621744482594`*^9}}, + ExpressionUUID -> "f08428ac-a507-4dcf-b70e-fed094d55f5a"], + +Cell[BoxData["\<\"H:\\\\PettersDropbox\\\\Dropbox\\\\HopsanComponents\\\\\ +ActivityDiagram\\\\ActivityDiagram\\\\\"\>"], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{ + 3.7553252830013437`*^9, 3.762681313451692*^9, 3.7626839962189417`*^9, { + 3.76272807832475*^9, 3.76272808233467*^9}, 3.7627282318551483`*^9, + 3.774782464352406*^9, {3.774782702334381*^9, 3.7747827237674847`*^9}, + 3.7747829584815454`*^9, {3.7747832790659356`*^9, 3.7747833074202747`*^9}, + 3.774783356371421*^9, 3.7747834533243513`*^9, 3.7747955729948483`*^9, + 3.774795612450227*^9, 3.7748614084190083`*^9, 3.7748619624768515`*^9, + 3.7748622246482515`*^9, 3.7748640395161448`*^9, 3.7753177663398657`*^9, + 3.7754917325888805`*^9, 3.7754917820577235`*^9}, + ExpressionUUID -> "b0628de8-4240-4cb9-a759-c769c3d3e251"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.76272807832475*^9}, + ExpressionUUID -> "96c62941-67ee-4f41-b96b-bc238faf7f2f"], + +Cell["ActivityDiagram Merge", "Section", + PageWidth->WindowWidth, + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.516086509*^9, 3.51608651040625*^9}, 3.52240314025*^9, { + 3.7535317970818443`*^9, 3.7535318239181423`*^9}, 3.754991191627206*^9, { + 3.7549932967387524`*^9, 3.754993297147331*^9}, {3.754993452569092*^9, + 3.7549934529137363`*^9}, {3.7552829494329333`*^9, + 3.7552829554537253`*^9}, {3.7653654200584526`*^9, 3.765365420761336*^9}, + 3.7747952519978476`*^9, 3.7747955692027297`*^9}, + ExpressionUUID -> "8e539398-d59d-4346-99c7-62ce8cde8c74"], + +Cell["\<\ +Event trigger for state machines. The flow is triggered on a positive flank \ +in event (should be a value 0 or 1). The flow qpn1,qpn2 and qpn3, are either \ +0 or 1 in one time step. The state variables spn1, spn2 and spn3 are either 0 \ +or 1.\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535320908646555`*^9, 3.753532282365305*^9}, { + 3.7549912370203238`*^9, 3.7549912440350904`*^9}, {3.774793947624714*^9, + 3.7747940079196377`*^9}, 3.774794209791312*^9}, + ExpressionUUID -> "bdc3e281-aa00-44be-ae84-967524ca58f1"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{ + "brief", "=", "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{"coauthor", "=", + "\"\, Emilia Villani\>\""}], "\ +\[IndentingNewLine]", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}], "\[IndentingNewLine]", + RowBox[{"Date", "[", "]"}]}], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.513785360140625*^9, 3.513785397734375*^9}, + 3.5137854683125*^9, 3.5153945210188417`*^9, {3.51608651940625*^9, + 3.516086528875*^9}, {3.522403083546875*^9, 3.52240310159375*^9}, { + 3.575772870974745*^9, 3.5757728916915812`*^9}, {3.60584801018426*^9, + 3.60584801687926*^9}, {3.753531830402015*^9, 3.7535318497890887`*^9}, { + 3.7535329032428656`*^9, 3.7535329063911552`*^9}, {3.7549912128203564`*^9, + 3.7549912207072244`*^9}, {3.7550214271472473`*^9, + 3.7550214275618167`*^9}, {3.755282886208119*^9, 3.755282894223857*^9}, { + 3.7552829304305267`*^9, 3.7552829350098047`*^9}, {3.765365424137388*^9, + 3.7653654247616515`*^9}, 3.7747952541435413`*^9, 3.7747955692037344`*^9, { + 3.7753177325159492`*^9, 3.7753177417951164`*^9}, {3.77549167539384*^9, + 3.7754917209458838`*^9}, {3.7754917778650465`*^9, 3.775491778104801*^9}}, + ExpressionUUID -> "63192a21-eff5-4a32-ab06-93bd62a509b1"], + +Cell[BoxData["\<\"Robert Braun , Emilia Villani\"\>"], \ +"Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214432906017`*^9, 3.7551057445882325`*^9, + 3.7551059975064726`*^9, 3.7553725928850546`*^9, 3.762695351804636*^9, + 3.762696195964285*^9, 3.76276652057736*^9, 3.7627667602008085`*^9, + 3.762766811596943*^9, 3.765365436776595*^9, 3.765365561124067*^9, + 3.7653661511844335`*^9, 3.765366742938574*^9, {3.7747955692037344`*^9, + 3.7747955731426945`*^9}, 3.7747956125780983`*^9, 3.774861408531891*^9, + 3.774861962612712*^9, 3.7748622247711287`*^9, 3.7748640396719847`*^9, + 3.7753177664827185`*^9, 3.7754917326288385`*^9, 3.775491782103677*^9}, + ExpressionUUID -> "45c2d659-7658-4459-abb3-c5d976bfef86"], + +Cell[BoxData[ + RowBox[{"{", + RowBox[{ + "2019", ",", "8", ",", "22", ",", "21", ",", "43", ",", + "2.0866932`8.07203358449933"}], "}"}]], "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.7535328848148966`*^9, 3.7535329121154985`*^9}, + 3.7535331327717113`*^9, 3.7550214432906017`*^9, 3.7551057445882325`*^9, + 3.7551059975064726`*^9, 3.7553725928850546`*^9, 3.762695351804636*^9, + 3.762696195964285*^9, 3.76276652057736*^9, 3.7627667602008085`*^9, + 3.762766811596943*^9, 3.765365436776595*^9, 3.765365561124067*^9, + 3.7653661511844335`*^9, 3.765366742938574*^9, {3.7747955692037344`*^9, + 3.7747955731426945`*^9}, 3.7747956125780983`*^9, 3.774861408531891*^9, + 3.774861962612712*^9, 3.7748622247711287`*^9, 3.7748640396719847`*^9, + 3.7753177664827185`*^9, 3.7754917326288385`*^9, 3.775491782108671*^9}, + ExpressionUUID -> "45c2d659-7658-4459-abb3-c5d976bfef86"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"nodeConnections", "=", + RowBox[{"{", "\[IndentingNewLine]", "\t", + RowBox[{ + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn1", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn2", ",", "0.", ",", "\"\\""}], "]"}], ",", + "\[IndentingNewLine]", "\t", + RowBox[{"PetriNetQnode", "[", + RowBox[{"pn3", ",", "0.", ",", "\"\\""}], "]"}]}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.515774261203125*^9, 3.515774262703125*^9}, { + 3.51603387128125*^9, 3.51603387178125*^9}, {3.522403633375*^9, + 3.522403641375*^9}, 3.53224891889497*^9, 3.762728078328746*^9, { + 3.7747810345452485`*^9, 3.774781058090841*^9}, {3.7747823489520864`*^9, + 3.774782356258823*^9}, {3.7747938144278283`*^9, 3.774793819809081*^9}, { + 3.7748638812026606`*^9, 3.774863885385459*^9}}, + ExpressionUUID -> "2096f5b3-005e-4e58-a8bb-ee5cca97f503"], + +Cell["\<\ +inputParameters = { + {event, 0.1, double, \"\", \"event (trigg on positive flank)\"} + };\ +\>", "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.51862830415625*^9, 3.51862836625*^9}, + 3.522403352671875*^9, 3.522403646703125*^9, {3.5320892483732347`*^9, + 3.5320892502013865`*^9}, {3.532248903689953*^9, 3.5322489076082892`*^9}, { + 3.7535310770227385`*^9, 3.7535310789444804`*^9}, {3.753531860881981*^9, + 3.7535318903088574`*^9}, 3.754993159322428*^9, {3.75499320303636*^9, + 3.754993203039356*^9}, 3.7549933065196686`*^9, 3.7747955692037344`*^9}, + ExpressionUUID -> "6004a690-5f87-4437-a4d9-05a7963088b8"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"expressions", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"qpn3", "\[Equal]", " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "+", "spn2", "-", "spn3"}], "]"}]}], ",", + "\[IndentingNewLine]", + RowBox[{"qpn1", "==", + RowBox[{ + RowBox[{"-", "qpn3"}], " ", + RowBox[{"onPositive", "[", + RowBox[{"spn1", "-", "0.5"}], "]"}]}]}], ",", "\[IndentingNewLine]", + RowBox[{"qpn2", "==", + RowBox[{ + RowBox[{"-", "qpn3"}], " ", + RowBox[{"onPositive", "[", + RowBox[{"1", "+", "qpn1", "-", "0.5"}], "]"}], + RowBox[{"onPositive", "[", + RowBox[{"spn2", "-", "0.5"}], "]"}]}]}]}], "\[IndentingNewLine]", + "}"}]}], ";"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.532248478932937*^9, 3.532248638440628*^9}, { + 3.571914197748662*^9, 3.5719142149866924`*^9}, {3.7535310915842247`*^9, + 3.7535311473072805`*^9}, {3.7535315340759363`*^9, 3.753531580504115*^9}, { + 3.7535316152480335`*^9, 3.7535316172745495`*^9}, {3.7535316889611306`*^9, + 3.7535317847886696`*^9}, {3.7535320068457546`*^9, + 3.7535320299450684`*^9}, {3.7535324291297054`*^9, 3.7535324760913725`*^9}, + 3.7535329786896353`*^9, {3.754991269059291*^9, 3.7549913100180607`*^9}, { + 3.7549930139652925`*^9, 3.754993017798341*^9}, {3.7549933379472666`*^9, + 3.7549934278415847`*^9}, 3.7549934587237473`*^9, {3.755105685321338*^9, + 3.755105691343128*^9}, {3.7551058806949067`*^9, 3.7551059297583227`*^9}, { + 3.76269520463138*^9, 3.7626952378702517`*^9}, {3.7626953144143944`*^9, + 3.762695317976671*^9}, {3.7626961113142395`*^9, 3.762696124434898*^9}, { + 3.76276650333788*^9, 3.762766514206193*^9}, 3.762766805898405*^9, { + 3.7747952829010906`*^9, 3.7747952918124933`*^9}, {3.7747953437341003`*^9, + 3.7747953526869335`*^9}, 3.7747955692047253`*^9}, + ExpressionUUID -> "9bddbe6b-0b0f-498d-854c-260e582893fd"], + +Cell[BoxData[ + RowBox[{"Compgen", "[", "file", "]"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{3.7747955692047253`*^9}, + ExpressionUUID -> "1bf4c767-539e-4196-9557-c11f2e50fda5"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","cntsList", + "\"\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"ActivityDiagramMerge0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge0\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge0.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramMerge0.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"hopsanobjectappearance\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{\\\"\\\\\\\"version\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\ +\"0.1\\\\\\\"\\\"}], \\\"}\\\"}], \\\",\\\", RowBox[{\\\"XMLElement\\\", \ +\\\"[\\\", RowBox[{\\\"\\\\\\\"modelobject\\\\\\\"\\\", \\\",\\\", RowBox[{\\\ +\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"typename\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"displayname\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge0\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"icon\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"\\\\\\\"isopath\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"ActivityDiagramMerge0.svg\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"iconrotation\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"ON\ +\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"userpath\\\\\\\"\\\", \\\"\ +\[Rule]\\\", \\\"\\\\\\\"ActivityDiagramMerge0.svg\\\\\\\"\\\"}]}], \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \ +\\\",\\\", RowBox[{\\\"XMLElement\\\", \\\"[\\\", \ +RowBox[{\\\"\\\\\\\"portpositions\\\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", \ +\\\"}\\\"}], \\\",\\\", RowBox[{\\\"{\\\", \ +RowBox[{RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\ +\\\\\"\\\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\ +\"\\\", \\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\ +\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn1\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.5`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn2\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}], \\\",\\\", \ +RowBox[{\\\"XMLElement\\\", \\\"[\\\", RowBox[{\\\"\\\\\\\"portpose\\\\\\\"\\\ +\", \\\",\\\", RowBox[{\\\"{\\\", RowBox[{RowBox[{\\\"\\\\\\\"x\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", \ +RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}], \ +\\\",\\\", RowBox[{\\\"\\\\\\\"a\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"\\\\\\\"0\\\\\\\"\\\"}], \\\",\\\", RowBox[{\\\"\\\\\\\"name\\\\\\\"\\\", \ +\\\"\[Rule]\\\", \\\"\\\\\\\"Ppn3\\\\\\\"\\\"}]}], \\\"}\\\"}], \\\",\\\", \ +RowBox[{\\\"{\\\", \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"}\\\"}]}], \ +\\\"]\\\"}]}], \\\"}\\\"}]}], \\\"]\\\"}]}], \\\"]\\\"}]\\) is not a list of \ +contents. The third item in an XMLElement must be a list of contents, even if \ +it is an empty list.\"",2,34,10,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.7754917822165594`*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,34,11,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.775491782257517*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.25`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.25`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 34,12,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.77549178228449*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,34,13,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.7754917823094635`*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.5`\\\"}]\\) in \ +\\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\\\\\"\\\", \\\"\[Rule]\\\", \ +\\\"0.5`\\\"}]\\) is not a valid value for an attribute in an XMLElement. The \ +value of the attribute must be a string.\"",2,34,14,16171631835219174289, + "Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.7754917823354373`*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "Export","autofix", + "\"Malformed symbolic XML expression encountered. This may result in \ +unexpected XML data.\"",2,34,15,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.775491782363408*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"Export\\\", \\\"::\\\", \ +\\\"autofix\\\"}], \\\"MessageName\\\"]\\) will be suppressed during this \ +calculation.\"",2,34,16,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.7754917823893814`*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "XMLElement","attrhs", + "\"\\!\\(\\*RowBox[{\\\"0.75`\\\"}]\\) in \\!\\(\\*RowBox[{\\\"\\\\\\\"y\\\ +\\\\\"\\\", \\\"\[Rule]\\\", \\\"0.75`\\\"}]\\) is not a valid value for an \ +attribute in an XMLElement. The value of the attribute must be a string.\"",2, + 34,17,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.775491782416353*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"], + +Cell[BoxData[ + TemplateBox[{ + "General","stop", + "\"Further output of \\!\\(\\*StyleBox[RowBox[{\\\"XMLElement\\\", \ +\\\"::\\\", \\\"attrhs\\\"}], \\\"MessageName\\\"]\\) will be suppressed \ +during this calculation.\"",2,34,18,16171631835219174289,"Local"}, + "MessageTemplate"]], "Message", "MSG", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.753532885828144*^9, 3.7535329140382867`*^9}, + 3.7535331349449224`*^9, 3.7550214434164715`*^9, 3.7551057448010125`*^9, + 3.755105997747225*^9, 3.7553725931417885`*^9, 3.7626953519921227`*^9, + 3.7626961960892572`*^9, 3.7627665207574773`*^9, 3.7627667604327507`*^9, + 3.762766811820899*^9, 3.7653654368784895`*^9, 3.765365561259926*^9, + 3.7653661513033113`*^9, 3.7653667430584497`*^9, {3.7747955692047253`*^9, + 3.7747955735093164`*^9}, 3.7747956128478203`*^9, 3.774861408704713*^9, + 3.774861962853463*^9, 3.774862225021869*^9, 3.774864039939707*^9, + 3.7753177668393507`*^9, 3.775491732998458*^9, 3.7754917824433255`*^9}, + ExpressionUUID -> "2e4655f9-1cd2-44ac-826f-a5b5e006b3e1"] +}, Open ]] +}, +WindowSize->{1234, 716}, +WindowMargins->{{193, Automatic}, {56, Automatic}}, +PrivateNotebookOptions->{"VersionedStylesheet"->{"Default.nb"[8.] -> False}}, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[579, 22, 270, 4, 101, "Title", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[852, 28, 355, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[1210, 36, 1211, 21, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[2424, 59, 824, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3251, 73, 661, 13, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[3915, 88, 837, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[4755, 102, 279, 6, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5037, 110, 590, 9, 70, "Section", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[5630, 121, 576, 10, 49, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[6209, 133, 2024, 43, 202, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[8236, 178, 860, 12, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[9099, 192, 924, 15, 30, "Output", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[10026, 209, 1101, 21, 107, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11130, 232, 672, 12, 68, "Text", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[11805, 246, 1985, 38, 107, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[13793, 286, 221, 4, 30, "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[14017, 292, 7128, 103, 113, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[21148, 397, 1002, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[22153, 415, 1143, 18, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[23299, 435, 1004, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[24306, 453, 1146, 19, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[25455, 474, 1002, 16, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[26460, 492, 1076, 17, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[27539, 511, 1144, 18, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}], +Cell[28686, 531, 1079, 17, 21, "Message", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}] +}, Open ]] +} +] +*) + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.svg b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.svg new file mode 100644 index 0000000..53e9506 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.svg @@ -0,0 +1,100 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.xml new file mode 100644 index 0000000..8946aa0 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMerge0.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.hpp b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.hpp new file mode 100644 index 0000000..4b5ba16 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.hpp @@ -0,0 +1,130 @@ +/*----------------------------------------------------------------------------- + This source file is a part of Hopsan + + Copyright (c) 2009 to present year, Hopsan Group + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + For license details and information about the Hopsan Group see the files + GPLv3 and HOPSANGROUP in the Hopsan source code root directory + + For author and contributor information see the AUTHORS file +-----------------------------------------------------------------------------*/ + +//! +//! @file ActivityDiagramMergeN.hpp +//! @author Petter Krus +//! @date 2018-12-31 +//! based on ElectricCapacitanceMultiPort.hpp by Björn Eriksson +//! @brief Contains a multi in join Component +//! + +#ifndef ACTIVITYDIAGRAMMERGEN_HPP_INCLUDED +#define ACTIVITYDIAGRAMMERGEN_HPP_INCLUDED + +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include +#include +#include + +namespace hopsan { + + //! + //! @brief A StateMchine AND multi port component + //! @ingroup StateMachine + //! + class ActivityDiagramMergeN : public ComponentQ + { + + private: + std::vector mvpN_q, mvpN_s; + size_t mNumPorts; + Port *mpPpn1; + Port *mpPpn2; + + //Port Ppn2 variable + double q2; + double s2; + + //Port Ppn2 pointer + double *mpP_q2; + double *mpP_s2; + + public: + static Component *Creator() + { + return new ActivityDiagramMergeN(); + } + + void configure() + { + mpPpn1 = addPowerMultiPort("Ppn1", "NodePetriNet"); + mpPpn2=addPowerPort("Ppn2","NodePetriNet"); + } + + + void initialize() + { + //Port Ppn1 + mNumPorts = mpPpn1->getNumPorts(); + mvpN_q.resize(mNumPorts); + mvpN_s.resize(mNumPorts); + + for (size_t i=0; i + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.xml b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.xml new file mode 100644 index 0000000..f31aa8f --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/ActivityDiagramMergeN.xml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramAction.svg b/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramAction.svg new file mode 100644 index 0000000..7fd70f1 --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramAction.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramActionN.svg b/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramActionN.svg new file mode 100644 index 0000000..539ad0c --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/AvtivityDiagramActionN.svg @@ -0,0 +1,199 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + diff --git a/ActivityDiagramLib/ActivityDiagram/compile.bat b/ActivityDiagramLib/ActivityDiagram/compile.bat new file mode 100644 index 0000000..2599c0b --- /dev/null +++ b/ActivityDiagramLib/ActivityDiagram/compile.bat @@ -0,0 +1,7 @@ +@echo off +set PATH=C:/Program Files/Hopsan/mingw64/bin;%PATH% +@echo on +if exist ActivityDiagramLib.dll ( + del ActivityDiagramLib.dll +) +g++ -I"C:/Program Files/Hopsan/HopsanCore/include" -fPIC -w -Wl,--rpath,"C:/Users/petkr14/Git/development-libraries/ActivityDiagramLib/ActivityDiagram" -DHOPSAN_BUILD_TYPE_RELEASE -DHOPSANCORE_DLLIMPORT -std=c++11 ActivityDiagramLib.cc -L"C:/Program Files/Hopsan/bin" -L"C:/Program Files/Hopsan/lib" -lhopsancore -shared -o ActivityDiagramLib.dll diff --git a/ActivityDiagramLib/Exempel/ADcylinder.hmf b/ActivityDiagramLib/Exempel/ADcylinder.hmf new file mode 100644 index 0000000..88d6b84 --- /dev/null +++ b/ActivityDiagramLib/Exempel/ADcylinder.hmf @@ -0,0 +1,5292 @@ + + + + + ActivityDiagramLibrary + ActivityDiagramLibrary + + + 59c07d33-554f-49d3-a163-a928823d4380 + HopsanDefaultComponentLibrary + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + diff --git a/ActivityDiagramLib/Exempel/ActivityDiagramTest.hmf b/ActivityDiagramLib/Exempel/ActivityDiagramTest.hmf new file mode 100644 index 0000000..53769b4 --- /dev/null +++ b/ActivityDiagramLib/Exempel/ActivityDiagramTest.hmf @@ -0,0 +1,8397 @@ + + + + + 59c07d33-554f-49d3-a163-a928823d4380 + HopsanDefaultComponentLibrary + + + ActivityDiagramLibrary + ActivityDiagramLibrary + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + diff --git a/FuelCellLib/Documentation/ElectricFuelcellL1.pdf b/FuelCellLib/Documentation/ElectricFuelcellL1.pdf new file mode 100644 index 0000000..883758c Binary files /dev/null and b/FuelCellLib/Documentation/ElectricFuelcellL1.pdf differ diff --git a/FuelCellLib/Documentation/FuelCellEquations.nb b/FuelCellLib/Documentation/FuelCellEquations.nb new file mode 100644 index 0000000..1ce4d57 --- /dev/null +++ b/FuelCellLib/Documentation/FuelCellEquations.nb @@ -0,0 +1,1504 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 11.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 158, 7] +NotebookDataLength[ 69234, 1496] +NotebookOptionsPosition[ 66857, 1416] +NotebookOutlinePosition[ 67263, 1432] +CellTagsIndexPosition[ 67220, 1429] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["Investigation of the Fuel Cell Equations", "Section", + CellChangeTimes->{{3.8029350390365705`*^9, 3.802935043126354*^9}, { + 3.8140024212036805`*^9, 3.8140024554051685`*^9}}, + ExpressionUUID -> "4f36eba9-0573-4e34-ad6d-9666b618a71b"], + +Cell["\<\ +In the literature cm is usually used as the length scale. Here SI units are \ +used which means that a factor 10^2 is sometimes used to compensate for this.\ +\>", "Text", + CellChangeTimes->{{3.8139996015276814`*^9, 3.8139999157836046`*^9}, { + 3.814002338310876*^9, 3.814002378715205*^9}}], + +Cell[BoxData[ + RowBox[{"ucell", ":=", + RowBox[{"Enernst", "-", "uact", "-", "uOhmic", "-", "ucon"}]}]], "Input", + CellChangeTimes->{{3.8029349691546545`*^9, 3.802935032734073*^9}, + 3.802938275565213*^9, {3.807512268170862*^9, 3.807512271517701*^9}, { + 3.8075227027282476`*^9, 3.8075227038791385`*^9}, {3.8075251893433814`*^9, + 3.8075251926326895`*^9}, 3.8140018669232607`*^9}, + ExpressionUUID -> "4e234c76-516e-47f3-b5ef-343fcf570de6"], + +Cell["Nernst equation", "Text", + CellChangeTimes->{{3.8029352421460624`*^9, + 3.802935247289757*^9}},ExpressionUUID->"95fef111-5b42-46c8-b21b-\ +c809779c997b"], + +Cell[BoxData[ + RowBox[{"Enernst", ":=", + RowBox[{ + FractionBox["dG", + RowBox[{"2", " ", "F"}]], "+", + RowBox[{ + FractionBox["dS", + RowBox[{"2", " ", "F"}]], + RowBox[{"(", + RowBox[{"T", "-", "Tref"}], ")"}]}], "+", + RowBox[{ + FractionBox[ + RowBox[{"R", " ", "T"}], + RowBox[{"2", " ", "F"}]], + RowBox[{"Log", "[", + FractionBox[ + RowBox[{"Ph2", " ", + SqrtBox["Po2"]}], + RowBox[{" ", "P0"}]], "]"}]}]}]}]], "Input", + CellChangeTimes->{{3.8075122937613444`*^9, 3.8075124607845902`*^9}, + 3.8075218983016095`*^9}, + ExpressionUUID -> "8d7d5e04-69cf-41a3-ab06-7d45e237ba12"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"uact", "=", + RowBox[{"-", + RowBox[{"(", + RowBox[{"ksi1", "+", + RowBox[{"ksi2", " ", "T"}], " ", "+", " ", + RowBox[{"ksi3", " ", "T", " ", + RowBox[{"Log", "[", "Co2", "]"}]}], "+", + RowBox[{"ksi4", " ", "T", " ", + RowBox[{"Log", "[", "ifc", "]"}]}]}], ")"}]}]}], ";"}]], "Input", + CellChangeTimes->{{3.8075132455239105`*^9, 3.807513309164328*^9}, + 3.8076041555559654`*^9, 3.8076046742966757`*^9, 3.8076048164224653`*^9, { + 3.812810807142397*^9, 3.812810813868497*^9}, {3.8140014155893655`*^9, + 3.8140014204414496`*^9}, 3.8140017287334538`*^9, 3.8140018834199424`*^9}, + ExpressionUUID -> "9b25d803-74cd-4065-a985-26367cd4de39"], + +Cell[BoxData[ + RowBox[{"uOhmic", ":=", + RowBox[{ + FractionBox[ + RowBox[{"rhoM", " ", "l", " ", + SuperscriptBox["10", "2"]}], + RowBox[{"A", " ", + SuperscriptBox["10", "4"]}]], "ifc"}]}]], "Input", + CellChangeTimes->{{3.807513370852277*^9, 3.807513392384618*^9}, { + 3.8075137594178853`*^9, 3.807513760609709*^9}, 3.8140004639605203`*^9, { + 3.8140014665033584`*^9, 3.8140014949026885`*^9}, {3.8140017692706947`*^9, + 3.814001773738082*^9}, {3.8140018075640726`*^9, 3.814001820987155*^9}, { + 3.8140018668833017`*^9, 3.8140018834313526`*^9}}, + ExpressionUUID -> "162a4d50-d22a-420e-be47-8ea0f03f276d"], + +Cell[BoxData[ + RowBox[{"rhoM", ":=", + FractionBox[ + RowBox[{"181.6", " ", + RowBox[{"(", + RowBox[{"1", "+", + RowBox[{"0.03", + RowBox[{"(", + FractionBox["ifc", + RowBox[{"A", " ", + SuperscriptBox["10", "4"]}]], ")"}]}], "+", + RowBox[{"0.062", + SuperscriptBox[ + RowBox[{"(", + FractionBox["T", "303"], ")"}], "2"], + SuperscriptBox[ + RowBox[{"(", + FractionBox["ifc", + RowBox[{"A", " ", + SuperscriptBox["10", "4"]}]], ")"}], "2.5"]}]}], ")"}]}], + RowBox[{"(", + RowBox[{"psi", "-", "0.634", "-", + RowBox[{"3", + RowBox[{"(", + FractionBox["ifc", + RowBox[{"A", " ", + SuperscriptBox["10", "4"]}]], ")"}], + SuperscriptBox["E", + RowBox[{"4.18", + RowBox[{"(", + FractionBox[ + RowBox[{"T", "-", "303"}], "T"], ")"}]}]]}]}], ")"}]]}]], "Input", + CellChangeTimes->{{3.807513438903061*^9, 3.807513634705281*^9}, { + 3.807603186062112*^9, 3.8076032340493603`*^9}, {3.8076033842215204`*^9, + 3.807603391561664*^9}, 3.8140004668519945`*^9, {3.814000595534025*^9, + 3.8140006002792687`*^9}, {3.814001883442341*^9, 3.8140018834523306`*^9}, + 3.8140021803777924`*^9}, + ExpressionUUID -> "4e6a9e14-d41b-42ca-ad75-634984a34f69"], + +Cell[BoxData[ + RowBox[{"Co2", ":=", + FractionBox["Po2", + RowBox[{"5.08", " ", + SuperscriptBox["10", "6"], + SuperscriptBox["E", + FractionBox[ + RowBox[{"-", "498"}], "T"]]}]]}]], "Input", + CellChangeTimes->{{3.80752276790214*^9, 3.8075228027580643`*^9}, + 3.8140004820556855`*^9, {3.8140006285429707`*^9, 3.8140006304461904`*^9}}, + ExpressionUUID -> "d1e9f246-1a4c-4470-a7a4-4d00683212bb"], + +Cell[BoxData[ + RowBox[{"ucon", ":=", + RowBox[{ + RowBox[{"-", "B"}], " ", + RowBox[{"Log", "[", + RowBox[{"1", "-", + FractionBox["J", "Jmax"]}], "]"}]}]}]], "Input", + CellChangeTimes->{{3.8075139638978267`*^9, 3.8075139871413584`*^9}, + 3.814000485094858*^9}, + ExpressionUUID -> "38954789-c639-4d2a-bd90-a66eef5be30c"], + +Cell["\<\ +Approximate expression for Log[1-x] to avoid infinite derivative.\ +\>", "Text", + CellChangeTimes->{{3.814000495713896*^9, 3.814000538277777*^9}, + 3.814002433945778*^9}], + +Cell[BoxData[ + RowBox[{ + RowBox[{"LogA1", "[", "x_", "]"}], ":=", + RowBox[{"-", + FractionBox[ + RowBox[{"1.3", " ", "x"}], + RowBox[{"1", "-", + SuperscriptBox[ + RowBox[{"(", + RowBox[{"0.93", "x"}], ")"}], "4"]}]]}]}]], "Input", + CellChangeTimes->{3.8126319801097*^9, 3.814000771150879*^9}, + ExpressionUUID -> "6c5eb4b1-ac64-4d2d-b1dd-b3f172d6017f"], + +Cell[BoxData[ + RowBox[{"uconA", ":=", + RowBox[{ + RowBox[{"-", "B"}], " ", + RowBox[{"LogA1", "[", + FractionBox["J", "Jmax"], "]"}]}]}]], "Input", + CellChangeTimes->{{3.8075139638978267`*^9, 3.8075139871413584`*^9}, + 3.8122019545460567`*^9, {3.8122027877134895`*^9, 3.812202806353181*^9}, + 3.8128109537436686`*^9, 3.81400055432629*^9, {3.8140007738635592`*^9, + 3.8140007771256742`*^9}, 3.814002492015295*^9}, + ExpressionUUID -> "38954789-c639-4d2a-bd90-a66eef5be30c"], + +Cell["Here is is tested without", "Text", + CellChangeTimes->{{3.8140024686754494`*^9, 3.814002479361373*^9}}], + +Cell[BoxData[ + RowBox[{"ucon", ":=", + RowBox[{ + RowBox[{"-", "B"}], " ", + RowBox[{"Log", "[", + RowBox[{"1", "-", + FractionBox["J", "Jmax"]}], "]"}]}]}]], "Input", + CellChangeTimes->{{3.8075139638978267`*^9, 3.8075139871413584`*^9}, + 3.8122019545460567`*^9, {3.8122027877134895`*^9, 3.812202806353181*^9}, + 3.8128109537436686`*^9, 3.81400055432629*^9, {3.8140007738635592`*^9, + 3.8140007771256742`*^9}, {3.814001538798457*^9, 3.8140015427331004`*^9}}, + ExpressionUUID -> "38954789-c639-4d2a-bd90-a66eef5be30c"], + +Cell[BoxData[ + RowBox[{"ksi2", ":=", + RowBox[{"0.00286", "+", + RowBox[{"0.0002", " ", + RowBox[{"Log", "[", + RowBox[{"A", " ", + SuperscriptBox["10", "4"]}], "]"}]}], "+", + RowBox[{"4.3", " ", + SuperscriptBox["10", + RowBox[{"-", "5"}]], + RowBox[{"Log", "[", "Ch2", "]"}]}]}]}]], "Input", + CellChangeTimes->{{3.807521136948608*^9, 3.807521204889324*^9}, { + 3.8075214178325996`*^9, 3.807521420569214*^9}}, + ExpressionUUID -> "4d87b107-ae01-4aca-a048-8037e19bf0aa"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"dS", "=", + RowBox[{".85", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], "2", "F"}]}]], "Input", + CellChangeTimes->{{3.8075130315046706`*^9, 3.80751305257767*^9}}, + ExpressionUUID -> "9335be56-42d8-474d-83af-64b378135919"], + +Cell[BoxData["164.025064604`"], "Output", + CellChangeTimes->{ + 3.807513053591527*^9, 3.807521643099425*^9, 3.8075218536984625`*^9, + 3.80752191770035*^9, 3.807522893539935*^9, 3.807603247387182*^9, + 3.807603322730194*^9, 3.807603397121693*^9, 3.807603511233593*^9, + 3.807603576655254*^9, 3.807604159446865*^9, 3.8076046780547523`*^9, + 3.8076048199599295`*^9, 3.807901776829618*^9, 3.809691695536545*^9, + 3.8096928320950303`*^9, 3.810007903067587*^9, 3.810879858697279*^9, + 3.8108799377763877`*^9, {3.8121985557061663`*^9, 3.8121985688243237`*^9}, + 3.812202828649744*^9, 3.8122862659462824`*^9, 3.812631994889812*^9, + 3.812809578256631*^9, 3.8128096228091364`*^9, 3.812810866732405*^9, { + 3.8133903804648647`*^9, 3.813390406126706*^9}, 3.814000354311224*^9, { + 3.814000424313463*^9, 3.8140004404909897`*^9}, {3.8140006077373533`*^9, + 3.8140006345501785`*^9}, 3.814000782368597*^9, 3.8140011385356503`*^9, + 3.8140013475353155`*^9, 3.814001385949638*^9, 3.814001430225088*^9, + 3.8140015018627253`*^9, 3.814001546955969*^9, 3.8140017375309415`*^9, + 3.8140017772890973`*^9, {3.814001824332512*^9, 3.8140018330924187`*^9}, + 3.8140018891548157`*^9, 3.814001927399007*^9, 3.8140021235274773`*^9, + 3.814002185416247*^9, 3.8140025137865276`*^9}, + ExpressionUUID -> "7cc10823-aeab-4bcc-b915-48142c5d1458"] +}, Open ]], + +Cell[BoxData[ + RowBox[{ + RowBox[{"psi", "=", "23."}], ";", + RowBox[{"T", "=", "300"}], ";"}]], "Input", + CellChangeTimes->{{3.8075136990827837`*^9, 3.8075137003355756`*^9}, { + 3.807513808361994*^9, 3.8075138188864746`*^9}}, + ExpressionUUID -> "e58a9b40-f490-456e-9ee0-8de9ffc1c570"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"F", "=", "96485.33212"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"R", "=", "8.314"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Tref", "=", "298.15"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"dG", "=", "228000.6"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{ + RowBox[{"P0", "=", "1"}], ";"}], " "}]}], "Input", + CellChangeTimes->{{3.8075124743152857`*^9, 3.807512509747173*^9}, + 3.807512689525942*^9, {3.8075129091870856`*^9, 3.807512933171692*^9}, { + 3.8075216274893866`*^9, 3.80752163293712*^9}, {3.8096928148069544`*^9, + 3.8096928214391484`*^9}}, + ExpressionUUID -> "33b139e2-b839-44cb-a449-d49c476c604c"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"n", "=", "48"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"T", "=", "323"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"A", "=", + RowBox[{"62.5", " ", + SuperscriptBox["10", + RowBox[{"-", "4"}]]}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"l", "=", + RowBox[{"25", " ", + SuperscriptBox["10", + RowBox[{"-", "6"}]]}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Ph2", "=", "1.476"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Po2", "=", "0.2095"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"B", "=", "0.15"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Rc", "=", "0.0003"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ksi1", "=", + RowBox[{"-", ".948"}]}], ";", + RowBox[{"ksi3", "=", + RowBox[{"7.22", " ", + SuperscriptBox["10", + RowBox[{"-", "5"}]]}]}], ";", + RowBox[{"ksi4", "=", + RowBox[{ + RowBox[{"-", "1.0615"}], " ", + SuperscriptBox["10", + RowBox[{"-", "4"}]]}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"psi", "=", "23"}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Jmax", "=", + RowBox[{"672", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], + SuperscriptBox["10", "4"]}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Jn", "=", + RowBox[{"22", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], + SuperscriptBox["10", "4"]}]}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"Imax", "=", "42"}], ";"}]}], "Input", + CellChangeTimes->{{3.807520406266676*^9, 3.8075204122384233`*^9}, { + 3.807521115821776*^9, 3.807521126020562*^9}, {3.807521230792799*^9, + 3.8075215759116573`*^9}, {3.8075216636945295`*^9, 3.8075217124200335`*^9}, + 3.8134875053060446`*^9, {3.814000434883108*^9, 3.814000436339897*^9}, { + 3.814000902114501*^9, 3.814000904225292*^9}}, + ExpressionUUID -> "5aaa5c6c-e89a-4f64-896b-b785eed88ad3"], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"J", "=", + RowBox[{"ifc", "/", "A"}]}]], "Input", + CellChangeTimes->{{3.8075229245414724`*^9, 3.807522932888567*^9}, + 3.814001883466316*^9}, + ExpressionUUID -> "168b4911-a70e-4cc9-af2f-533b0981c3d0"], + +Cell[BoxData[ + RowBox[{"160.`", " ", "ifc"}]], "Output", + CellChangeTimes->{3.814001889369592*^9, 3.8140019276367617`*^9, + 3.8140021237382517`*^9, 3.8140021856350183`*^9, 3.814002514001303*^9}] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"160.`", " ", "ifc"}]], "Input", + CellChangeTimes->{{3.8140018834823*^9, 3.814001883487294*^9}}], + +Cell[BoxData[ + RowBox[{"160.`", " ", "ifc"}]], "Output", + CellChangeTimes->{3.814001889427533*^9, 3.814001927689707*^9, + 3.814002123795193*^9, 3.8140021856949596`*^9, 3.8140025140582533`*^9}] +}, Open ]], + +Cell[BoxData[ + RowBox[{ + RowBox[{"Ch2", "=", "1"}], ";"}]], "Input", + CellChangeTimes->{{3.807523110600075*^9, 3.8075231351083736`*^9}}, + ExpressionUUID -> "de1ab2e4-6bfb-422f-8ef8-a2661e4bda62"], + +Cell[CellGroupData[{ + +Cell[BoxData["rhoM"], "Input", + ExpressionUUID -> "620d71f4-2c3c-44af-a9fc-86f7ce71589f"], + +Cell[BoxData[ + FractionBox[ + RowBox[{"181.6`", " ", + RowBox[{"(", + RowBox[{"1", "+", + RowBox[{"0.00048`", " ", "ifc"}], "+", + RowBox[{"2.2814525138382176`*^-6", " ", + SuperscriptBox["ifc", "2.5`"]}]}], ")"}]}], + RowBox[{"22.366`", "\[VeryThinSpace]", "-", + RowBox[{"0.06217944881958792`", " ", "ifc"}]}]]], "Output", + CellChangeTimes->{3.81400188963232*^9, 3.8140019278964934`*^9, + 3.8140021240029783`*^9, 3.81400218589675*^9, 3.8140025142750216`*^9}] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{"ksi2", ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "30"}], "}"}]}], "]"}]], "Input", + CellChangeTimes->{{3.807603078846569*^9, 3.8076030798337865`*^9}, { + 3.8140010255948524`*^9, 3.814001026552495*^9}, 3.814001883563216*^9}, + ExpressionUUID -> "62a9af8a-eade-44e7-ac2e-69be48f98025"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJxTTMoPSmViYGAwAWIQ/e3eySMq3UvstNJ3vXcxybN3U3l19+P1S/Yw/s/r +5lM/XH8E5x92Xr7k4qLPcL7M/Z3PknT+wvkiOfGr2J2ZHWD8SYZuu/1COeD8 +mzMMDnwU4IXzu5fUn2eSFITzxac87pw8VxjObw/xtLv0TRTOL7ZcGH+ySQLO +d3n/qyrvsRSc32gTmChlIQvnW62buaVuvzycn/PjY8MJXkU4/6e2wD3dUCU4 +32b1mgXTpinD+R+FvBLCDqnA+U96EsKK2NXgfM/35Z5PzdTh/DfJHMVb6jUc +EOEpztR+SBPOFzqr1rfhvRacL9OxPsDMTAfOn6FtKSCcrgvnn5JyNP08UQ/h +H5lDE/Sv6cP5fMyLShKbDOB8uUZ5m0g1QzifUzVmW9BxBF/PVnJ9eawRnF90 +T+iwF4MxnP/+c0+o5wwE313/2CxPXRM4f99n69/fzyH4eTpGty6mmsL5tu9S +rkRymsH5rioSvryLEHyNhq6KQ+bmcL5WquV+1VsIfuq+jJYthRZw/v4FV1I+ +ilrC+V9W/P+uvx3BT1ZdzTnL1woRX1qTzTZ9QPB3LPn98GuHNZwf5aLsYC1n +A+dL57bv1DuA4Ity5Wz0DbeF829ZT768bDWCPy9319f//xF8ADt5Yw0= + "]]}, + Annotation[#, "Charting`Private`Tag$9113#1"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0, 30}, {0., 0.007374066622696943}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, { + Scaled[0.05], + Scaled[0.05]}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{ + 3.8140010278644705`*^9, 3.814001138934239*^9, 3.814001348187642*^9, + 3.814001386476096*^9, 3.8140014307485485`*^9, 3.8140015022573195`*^9, + 3.8140015475873175`*^9, 3.814001738071384*^9, 3.8140017778764906`*^9, { + 3.8140018248799477`*^9, 3.814001833638857*^9}, 3.814001889768181*^9, + 3.814001927978409*^9, 3.8140021240789013`*^9, 3.8140021859726715`*^9, + 3.8140025143509526`*^9}] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{"rhoM", ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "30"}], "}"}]}], "]"}]], "Input", + CellChangeTimes->{{3.807603078846569*^9, 3.8076030798337865`*^9}, + 3.8140018835702095`*^9}, + ExpressionUUID -> "62a9af8a-eade-44e7-ac2e-69be48f98025"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwV0HtUjHkcBvDUcdRmUqPZpmS8v+myNd2mGpOp3ubpJjO7tbQiut8IqdxC +pAsquqCE3A7poNJFKmmptlpkFxupkcXKZVdLFzVd2fb1x/c85/PPc87zJeFx +vlGqKioq3sx9zdEX7W3GWcUud0lSu4Cm0HmWu9NVkSbdXPi6Vs4YnIfhXEWe +VNR5o2g944Slpd1qiiKpQfytpFLGOv16eRPd1dLYMU+JwIXCy5s+cSPdLVLZ +Kcs75lIKi437ng91P5IqCwbdzF0pTHQ7FAx290rtb1V3mntSaHW/VNxRNCz9 +QxgQ8tKbguHLG+/CLb9Ie1qH1WevoKAbE1I6y10N7LKtFQbBFPJsF//s46cO +9R9EP75dQ+HpCWHzkDYLhaP720zjKGQVJz9U1deBbV2fttkOCnpHXx/IPzMX +bn2hrDmpFDKWy1wejXKwWm1qx4YDFLZIzoe0p3FxOFJbmZ1HwWNgMjH2tQH0 +dG5TRqcopDovCzNYNB9UgO/eMxcoOFYU1uxpWoD0WJZ97xUKMeNDKXdZBN5u +aUsKa5l9FtovrPz4CDYvec9rouBcduXcsWNGWCpUvsu6S2GILQ9d0WKMzyH6 +qdEdFN5kh67YPMsUup1fwvWfUZANbJe9FX8Hw52slEVvKHyIUN9Sk2yGLQUb +UoT9X/+pp5rRYo5f4nOStMcpsO+b5lYNCCCoyfENmEFgmFm5VCy2RLsOR7Jf +k+CEhUR77lorXIizkXM5BPcMXBcOH7FG1Sfx9CEegaNhy2GbLhuouvrM+mhG +oKVWtDUsTQiTkumYSjsCXuoC51WmthhdnCgLpAk0TALrfO/YIkeQpznkRWBN +61duD7IDiV83/m4ZweYX7Fa5ij1Kz8YLHwQSDAxn+8lO2GP6sc4e3bUEXja3 +T8qsROiZHZTpsomgcdhpauyBCLvqSWvoboJYS7uejqiFCNJ4lfU8nYDuj+xc +pSFG6vU5dv55BJ7GXG9WkRhtjg4cizMEZikHd7Q4OMDbrMH61SUCQZSkyaTH +ASWffk89fY0gqjF6X82mRUhb6axf1kjQdK4zcogjQV1j3kTbPYKRy9NjNtcl +mPlf6/lfuwgiTMo0Tno7IrdvnVC3l2BIkC+uHnSExF+qmtBPUF889UqZ6YRh +uz4to0mC1R5GcOI5gzUpz7k6k495GzNuWDc741uPKb8ANh+cb2Kueq+k0bz3 +Wp2cx0exe1Li4Coa2QlNHimM7ZJy3fMDacREzntSy9hnsOqJIowGr7z1M7WA +j/Qu5UREDA3/5U/XjjEeL0p2S0yloaYpKi8mfPQ45T++WEYjojxZqWLCR/S2 +4tOyChqew7fvixmPVtRGfaiiEcwOvxzDmM1XjNnW0ZjtfzRSwfh79fmGt5pp +WEd+GK805eNm58XIx09oBB3ffyTEjA+5Vr1VgoKG0Qj3UAFjhVf7KPcZjSP6 +qod+YzzS8G9m8F80ljh2FTiY82F1Xlj+vo/GevGBpjkCpq/HNSH7I416pwcP +PRnLdX+S2gzS2D1jfe8uxmsytnVsVTL75Be1/mE80px+Um+cRrSmlxnPgo+0 +yeMRDZM0/lSXeixnrC0qsQz6QqM6LDf8IOOzGxuU09M0/hYt3NvM+H8w6gLm + + "]]}, + Annotation[#, "Charting`Private`Tag$9151#1"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 8.11946706440439}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0, 30}, {8.11946706440439, 9.085453129048302}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, { + Scaled[0.05], + Scaled[0.05]}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{ + 3.8076030821374664`*^9, 3.807603254893193*^9, 3.807603328362651*^9, + 3.807603400118878*^9, 3.807603513832471*^9, 3.807603579040957*^9, + 3.807604162000599*^9, 3.8076046808066187`*^9, 3.8076048243756113`*^9, + 3.8079017780133996`*^9, 3.8096917026244755`*^9, 3.8096928375309067`*^9, + 3.810007903633004*^9, 3.8108798593965564`*^9, 3.8108799381969547`*^9, { + 3.8121985561562414`*^9, 3.8121985690790606`*^9}, 3.8122028290323505`*^9, + 3.8122862663798356`*^9, 3.8126319956670103`*^9, 3.812809584707507*^9, + 3.812809625206061*^9, 3.812810881810196*^9, {3.813390385815804*^9, + 3.813390410497208*^9}, 3.8140003553261175`*^9, {3.814000425077675*^9, + 3.814000441323131*^9}, {3.8140006083647065`*^9, 3.814000634940775*^9}, + 3.814000782972973*^9, 3.814001139150017*^9, 3.8140013483065195`*^9, + 3.8140013866139555`*^9, 3.814001430937354*^9, 3.8140015024391317`*^9, + 3.814001547755143*^9, 3.8140017382921567`*^9, 3.814001778108252*^9, { + 3.8140018250547676`*^9, 3.814001833777712*^9}, 3.8140018898920527`*^9, + 3.8140019281312532`*^9, 3.8140021242277603`*^9, 3.8140021860915475`*^9, + 3.814002514442848*^9}, + ExpressionUUID -> "4225b6c9-1b17-42bd-820a-e6a5f4fd1ca7"] +}, Open ]], + +Cell["Comparison with the aprocimate expression for uconA", "Text", + CellChangeTimes->{{3.8140026334169235`*^9, 3.8140026503302107`*^9}}], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{ + RowBox[{"{", + RowBox[{"ucon", ",", "uconA"}], "}"}], ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "44"}], "}"}], ",", + RowBox[{"PlotRange", "\[Rule]", + RowBox[{"{", + RowBox[{"0", ",", "2"}], "}"}]}]}], "]"}]], "Input", + CellChangeTimes->{{3.8075231455098195`*^9, 3.8075231760114655`*^9}, { + 3.807525114186741*^9, 3.807525163185214*^9}, 3.809691839025322*^9, + 3.8096918861052923`*^9, 3.8140018835782027`*^9, {3.81400250292089*^9, + 3.8140026223250713`*^9}}, + ExpressionUUID -> "31a202fc-ffca-4d33-b52b-0fe9295fe3f1"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwVVHk0FPoX14tEekW8poixLyUShXCvma+xRK/IkngVstRrU6FChWyjsrQo +KUxJIltJPKFEqVfZt8Y2GLINkfXlN78/7rnnnvs599zP53PPlXc7YXv4NwEB +gWR+/D8zmA+oPvLPTG5/4XXRYjaaqMgoGSawmMBTpAkpMkSA27Zn2oGVBDJe +x+R/MtaBefFAoz7rKaxvMnAYs1CHaXXdd+qsEiCc0FNiNgbwpbvVSIH1Eb6G +Yf1Be0soKc0KkGW1w+qT19dpeO6DvI23bsmwhuCVs2OFdKQPtLYFjWd+WoDp +UIre8cHz4HTgzqpaDyEsyadU9+mFQUKO+UFNFEPPRMMqzlw0TJT6P1VrEUft +n5StQRAHXzdmWeTtlkJhS3OeRPMNKHZkFyWvWYdRO851MxsS4aPvzJW5ShkU +o80k9LTeg/ei5+c8pamoEHkn8vy+FNiywy8pZFYe5QucgzhBaXA2x+1q60tF +DNbssFsR8xBspCuzvY8pY1SFeyQnOR00+lkv1S1UUetJp4LnSAb0TJ6WUFmq +jtmRljfblJ9Citsbh70cDXzMbdmpnZoN49VXPhQXb8JPlrJvKiVyYcMpg6su +vpsRhGwEfrfMg8f/6G1IVNVG96M2imKP8iG7h3FPbtkWjCsQsHeZKoBt+mtX +4/QWZLrH9JqeeAFRIgpJCxwdfLle3WaaVwgfFh5+birfimVRq5bPehZBjBz3 +p2WuLkbnU4QNVxaDkUdqddt1PfSpzX3LzCiBQqVbOcJHt2HEnvjL221KoUDS +KuZfp+14KeDrtQGNMkhW8RPP26aPU5pNYHexHES9DzE1VQ3wxdokleXRFWCq +HCHDWGOIOuvmnpfdfwOHBZUdAscM8VBSl0lezlsQWxMStrNjB2pffCDXO1gJ +qXTH/fqlRhh8NvT+JYUqWBzztKy4bYzcW/ku13yqoeuj3iZOmAlWiNpmjPW/ +h5wPgS8V3ADPBV1UTPKqgUsXKpL+U0OkCF797YXmJ6CyBHJnEhE17xh1/Ln4 +Lzxazv5SscwUe88PeK+e/gJDQuuONAeZojV17HWoZi2oSca1zA+bIs+w+LSa +bx2U++reY4+aYvOcZrpoQB041TYfKOPx8VGTZ3lBdRB5TZYbMmmKO37tXqyK +qoOB5VlTIgumSBuZ3Z6SWgcZ/1VJUFbQcH7tF1vhujpQ5S5Y66rT8GyY0r0a +vXpQKfau+PswDQ1WSi04izZA4VXDUjMvGpqn3UBN8QYwOyT2StaHhiOs/YcE +KQ3gsTw39+vfNGz0vm1XodwAaQ7TD3TP0FBlZLrcz7QB5H5cCV4IoWH4Emul +pnMNQNnE2hGTQkNtbe7j5NEGELnPfvG0nYZLbPNZ5HsjfDskMOLBpmGm8VWz +JRONkKusqCTbScP2lmdqlbON4JDtHR/bQ0Nif6bdRaQJHv7z4/jZQRoyr1lI +tas1AbaLqME0DY9R2k0lfZrAj7Ltbp0EHYMD4VrNaBNYfXOqZUrS8WhQm/jh +6SbYkHJhudkfdPzFtrYVFmiGStUKv5fr6HjlfYmpu3gziG+3trtHpePMNquj +53WbIcveTcxzMx0PUjLGdQKbgRN/LXjWko6KF9xlTSRa4I/Gu9zmnXRcH/du +RblMC1isfby70IaOmd8Ew21UWyArqUzh9B46anv7RjCNWsDvIa9q2ImO+TG7 +km95tYBooe2qLi86yqb2GC4pbwHt1j9Sqq7QUXV7kuev863gJq0o8iiCP98g +MFcjohVuumr5hkbx9+2/HuSZ0Apz3eYEr9JR60QLrsxqhcrvAQOvbtCRe3n0 +u3RHKzgutGlns/j97PpBd7M2CJZ7UJFQwedvmZvyU74dJvcsHLZ9S8ePSk92 ++Wu1w5GwfaLi7+h4tfCI1ArjdnAcXGN37T0dTZT9qv92agftgsjeyC90DOiT +HJSNbYcehq9wMJuOPYz11b5Lv4H5cTMb71k6GjZzKCXz3+B1Stq4yjwd/3zs +p75BjA269Ys3+xboyHS7fiBJhg1U/eIONwGCq6nVb0eM2TC3ROukqzDBF20d +8VOX2ZB1k5JgK0Vw0P5sw/iqDlhdOtRitIXg54Eppc3mnRDs4f9iQofgWFcT +LXF/JwyvWBqfoUswUIuhuvlkJ7x3Xr9TUp8gpk8ad93phIszFqVDJgS3t/4e +f3qsE0a3pqfetSY4OlC/X8y2C1zatwTv3kUw3NZlota1C2pCSp2X7SaoOaCa +89ynC9JrG9b42hFsTBrtr7/cBa4nloZbOhP8OnbKObqgCz5lHjwy40XQhj0S +cHJDNxjaDjOe+RD08ZdMctzYDRmz/ooeRwmeuU0J8DLohjCL69++HCfITWjV +FnLohh39pbsenyUYet9Bxz6uGzLlpbc6hBKUT8u22iXeA5QP6avErhCkftBR +tVDogfCTOsMV4QS7KjT6grf2wKEyy0ea0QT/KpITzHTg410D1grFEUzPct62 +KaUHIhIb5wvuEyywi/74zZQDe19biV5PIXjYKPBI+D4OUHvLKEfSCPZrCM+n +n+JAsVamHjWdYFxvtdVBFgdGq4JPxGQTzDC8wLVe2Qslwz+CvHIIlpqJFJqp +90KkhE8MLY+PtxLc22fWCwp/2T2Zec7XJ2XSy+ByLzhMqXI8/iG4GB6ysGNJ +HyhKJ4/Da4I/ac93nlDsAx5KCEiXE1xXlGiezOiD6JgFmdq3fH/tzUqUY/vA +Mf/Uxqx3BK8nCE2nFvaBUku/QUQ1QanvnypdOvqgVLHWwfgj/55EqP59W/oh +2pJxmPIvwR6Pmz29rv3gcKLk9I/PBGmWM/fDmf3AK34U+6SO4EKe1bJtw/1Q +2rX+QVgDwVcn9WJi5bgQvSw2+0ATwY2Bv0er2XNByfZ8jVQbQWN7RtFgNRfG +/cdaeO0E76x/Ep8gNACvkz24H9kE5d6w0y4yBoD5tnUqvZOg0GSI0ArmADgN +7hIM6Sb4YEJzP6t+AJRXVUq4cvj+R18cq6EOwoSugbx+H1+P7X1E9vQgMC8p +mowOEEyOOX3umMZ3cEpPtP7wne9PjJHHubjvoPRp5f6HwwSfLLubP7VkCMbH +Q3wujhL00s+UqwkagtdrZ/ydeQQDBCu/hggPA9P4WLjeBMGljPp8VtowOLn3 +3Fg9STCXInZGf+8IKEc5soamCJ7M2UDtVByFiWef8qqm+S9mT/5M74YxKGsw +LU+dJSgcTv21ehMPYuYKPwfOEwyWpLx7vsiDfdRNbMf/CA4UCfy2yWwCVBip +QzqLBEvCYtveKU/B4xKfcR6/vmNXpLL7yDz8D6MJoNc= + "]]}, + Annotation[#, "Charting`Private`Tag$9858#1"]& ], + TagBox[ + {RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwlUnk0lYsWRxGqJ5SU6ZgTJWOS7H3O931St3qS6aZUImORBr1EJaqbqUt6 +SYSjeCSKimMWMnMM1yyO4WTIXMau56231/qt/c8e1m+Qt/cwd+Tj4eFhreJ/ +3SToJc1F/q1xy3dtxjxXy1hFWskwghkEO6Y7vgy7bwJux/E5K2Y0jHqMzJW5 +0+Ag61uLATMVKLNpkSz3PTCnplumxswFYZt5qVR3hPq+diMFZjUYtkgnvHY3 +g9z8NzdkmZ1gm2TilOh+Ft6pP30qzRyFzYUWbkx3T2jv8J1KqVmGAFa9h4/M +XbA5EyXCduDHbhetnykX/4CI9INnd+EG/CysNKpY9Rim871Td7SJIvFKOmGb +fiQ0qL8xfWe2BR/f2EL7bhUFLOvu7BjxbWgTapTNy46Baq/5wMVSaVxLuklk +S8VDhfDNxQtSNAwnY8+OqjFBa//1aP8FeVT22/2ywfEVXEu3D2n/pIg0uqHX +ed8kOCpVmuZ8URlZNocUAoL/AzuHmJ/UTFVxfbRfnm91KnBmr4iprFHD3Spf +WLHcNIizL7Gy6N+JTOO0neulMmDqS2Ali6WBTV4F0mvwHchc3hdyyms3Xig/ +UpFi8R6S8vRknqnuwdvyor1kYCakcUxeyAloob5pqXbG6yzQN9i6Cee0kGmb +xf059AH+EFKIXu7XRusbeYseap+gcjmx7q8iHaRH7VQpscuGYDnuz0MZukgF +yOwSzMkBI4f4Lx1hehi/UWDAUjAXPio9TV/npo8aZZaBunZ5kLn5cHCtzV7U +naJbH+TkQ4zKddF3+gZ4RVgxnTxTCMLO54J2qe7D0hqhUJVHRUBXfiBtIm6I +IWub76/1KAbHtcpWtyYMMVHPNPDPEyWwQdw/4Lee/XitMm60y+4zxBPWtgb5 +Rhh09VDd4sVSWJm4cKj43weQ4U2cbAorg95qPY3+AGPslRDJezZSDumVtz4p +2AP+9DjaFm9eAXd8iqN/7UCcETCreyVUBTQmT8b8M0RWYdo+ga5qeCXYXV8s +QMcX4/r7zbi1MMq/zbXVl44lMSputsYNoDTUuBRxm44Hu/Jlo4kGOFUeHGJ2 +l44WtdaMHtMGqLvP864ygI6eThPcSyca4P26b3O5QXQcjiXEWM4NcFPoU2Bc +FB1nJkpoSxENILzRMt7lAx1PzxcpEt8bYMfmP9uWxui4QPMNa0llQ5GX7ovu +cTrqZPInPX3PBht265nCSTpufHNN+HQOGx6GynL9Z+l4xnNX/UI5G74Jvvkh +tEzHXyMHhK5y2JD8q1xMcj0D03W4uy5vbwRV7vIRXTUG2mTECRSFNoIKy7nY +3ZGBmrJhZs6PmuBjiGE+5cRAPfrvEY/Dm4A6tyFH1oWBAQ7q/YXPm8BBMCOj +wZ2BcZ7V9TqpTZBgNfdS9yoDaVtHhi/XNIHcTKDfsj8Dz7UdLfnnpmaQ1GDu +D45joJtWX31HTDMkr1zd65jAwLQXu8/Nv26GvU0mOsaJDHwumnNcNqMZrG6O +7JxMYuDGnZJ37pU0w5MKre0W6Qx8ojRzPovbDJsci+alChh40XRKMVenBYRi +uz+kdjLw95aDntmNLdB1jue7Qzdj1X/3NYe7WiBDWVFJ9isDY/Pfmw8MtoBV +mnP4Yw4DH+iVWekstEBi3syla8MM9JHuOm5E+wuwU2gHzDEwa9N/TPk9/4Lr +kvrPG8UIzAq+Kdgo0QqHu2zYQZsJrGCdyHki3woycT6ClASBYx+1vp7TaIVS +1eLrn7YRuK/SrkKK0Qqie4+ceEEjUGnl72qRS63wxtJ+w4XdBAYcLeoWqGiF +/vBQv4VDq/MaCtYpAW0g0fKc2/obgTF6xlsH/mwD061JZh+PEij6YU2exss2 +eBNdqHDlOIFsfqPtozltcD1xsnzMhkCOpg6/3GQbCH80F+l1IpD/+8sDPmfa +YU+7RFx5IIHTZw0EGw53gL2UotCrBwQy63yapE92QORpTa97fxAoXzOgf8ul +Axb7DpIYQmAeY4fZlYcdUDpy41vOEwIfKpu+MvnSAdbLHXvSmARWZReVxZt2 +gp/cy+KIYgI3XpoWOmDbBbPHlx3NPxM47sz3+w+3LnAN+F1YtIzAyyErRiW3 +usB6WPxEaAWBGuck7J7HdsGezIcDD+sJ/EEeMTft7wKOidc6v24CuRcxt8Cz +Gw5eoo46LxA4dVs971BMDxTEJUypLBF4NElBh5vRA7pNK5GDywT220pyYkt7 +gGbA6rHnIdFil3z+6bEeWOTV9Dy9jsRNNVds5Q58hTeRkhHmW0gsprlW9fd/ +hU35o21GWiR2i739KZLYC34O3h+mtUn07/1cdSe9F8bWrwlP1iVRkvuIjy+3 +FypObv9ts8HqPd5Sdf3GXrg9b5o/akzimQ1fz7nw9sG4zuv450dIvL7zfKr0 ++T6oSTnrOu9Eos8z8ex2XQ4Ymo+ZvHUhUbn2aVgigwPJC96KDm4k+mb+QynQ +jAMBpmFd9ZdIvO9efOKhOwf2D+UfS7pGImtYLuHFKw6kyEvpWN0jcVYwuWuX +dD88eNaylBlLYk1QFDteegAsCg4Lh8WRWK15rU1QcwBoA4WSrgkk8jWHtofT +B4ClmaJHe02i476R06JOAzBe7ucRnEbiCRHL2s+ZA2D1Q7XfIY9E0SsFEXYW +g6AoFTMFBSTyX7XtVHUZhEkU45EqIjHxhZC6lN8gPApelmZ/XuWvemzobvIg +5CuyrQ5Uk+gcFm5rtzIISuY3q7Z0kPh3m/rG+g9DMOU90TbZSaJhhXbTv2qH +oCDGgVvdTeLC6fGP1oNDYDN8bK1/H4l3bN2upW/hQtAdRePxbySOd0SW9N3g +wvTbmnflcySej3T2njn0DYrWy0V5b6Ew55Sk/lPpEWDLD3K0t1I4ZO8zLWQ4 +Apy9qRrjkhTyPdhsWWI9Amsc9hY5SFN4d9371rVPRsAk75/c44oUilounhoT +GYUa9zt6GloUSpTyNWtJjEG3v8ltrjaFF2q+ZLkZjMH4sw2VCboUHpvgTVk6 +OQYiZc9ObTOgsHFX3YxC/BiYy7y7JwAUbrYLcsrS+g5ttX3s3iOr+/qaUcqO +4zDcnyT14hiFYW/m3F1CxmFx4aKjtRmFbKUtOlIfx0FKZXG+9gSFghu9PtQL +ToCdnxgt9ySFGt+bXmZkTsDAbuJSpDOFijl9EPR4En6QQtlmrhSue//rY3jy +JAjY1vNucKfwyZe9k31Fk6D6wDbS34PCX+LWhaemJ8H165U8j+sU0hvfKw/b +TMFEWKLw4QAKvXNkDBP1psGky5ZjcJ/C7T0DS0ZW0xC7Q5yl+pBCFZW1dUe9 +p+FI8V0X/mAKfdOz1DisaUietqsoiqCw0FuyU9F0BlaMJeLSI1f56W4uqHKf +AaugWu/Yf1P44VrLAE/4DPArGaneiqbwYaGhxY6eGbC33HZ/L5PCxxYB4l98 +ZyEnvuG0yqtVPRLcyw4nzcKm8Qd6W5IoVNOuMvNhz0LB/Z8D0ykUftqvJD2r ++gOkspuIt+8pdFwn31ra/QOat4fyKpdQWLWms9Hr8hyoO1Ht4qUUrsitD5VJ +ngP/zOUMvvJVf/Yb8NZ9nYM9R9zO9lZS+I9QgsfOfB5CfE0Lo9kULspqPpGm +FmCgcuXpoyYK5cU8/VoCFsBI4tOlf7VQKBPFv7utbAFG3irLWrdTmHxPNav/ +t0Uw6eXzFeujMNrFtvOQyxLEaLAsePtX82ep0BWQtQSzNy5rTA5QqC1UcdOJ +dxkSRHs7a7+t5kfStehU3DKsMPIN/5ikkBbe45Y/+wuswq6K3ZimMP8O4cM9 +9je87VQfuTBLYegvbRPj1L/h1NXnUeT86r9fjcxS1xXILDp+WWeRwtncPyVo +dSvAbriQqbxEIc//C/8LX1B40w== + "]]}, + Annotation[#, "Charting`Private`Tag$9858#2"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0., 43.99999910204082}, {0, 2}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, {0, 0}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{{3.8140025307509856`*^9, 3.8140026226279907`*^9}}] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{"uOhmic", ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "60"}], "}"}], ",", + RowBox[{"PlotRange", "\[Rule]", + RowBox[{"{", + RowBox[{"0", ",", "2"}], "}"}]}]}], "]"}]], "Input", + CellChangeTimes->{{3.807901752109039*^9, 3.807901763818799*^9}, + 3.809691835585297*^9, 3.80969188363571*^9, {3.81339035846745*^9, + 3.813390376129346*^9}, {3.8133904466613884`*^9, 3.81339046932749*^9}, + 3.8140006580394545`*^9, {3.8140018669042797`*^9, 3.814001883627152*^9}}, + ExpressionUUID -> "154203e7-a246-4619-90c8-ba640ea2c994"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwVkHk41Akchz08kd2t7CBHtDmLYmI15fx+NWJn8pNEh6UYNNqQJGclx6Ka +hHH9plDjaGOJUjG5VrtlakuiZozSltpnlcYx7naatX98nvfP930+RqwjPmHK +SkpKxOL+58yQ8HfTc00uNjFSfzvfz879ZbqJruJ8aPeUlq+gDLigdg9LV8wH +I6+2M46UEZc47xqRivgGGL2JZ72nzLt8K9XJnxd1wb21yZtYWurwutXryJTo +GZziPZJG6+iBu+mHVxOit3D1BOpfNLSAedHmwnHRJDyV6BxQWNjDPfrVyl6+ +CpJtms2WfkwweN3yN2vDMjzeqJaUWbELtCIO1KjRNdFGU+/mq6X+kG/jftfL +Txf7aQ1fD6UHwUDJxs4JDUMseuunKH8SAucqU3qU9YwwUX+0Scxmg07B8Blu +qQkevBsTkjD3E2T5MlyezZhh38Ocne67ouCY/ZUDwrR1uKrphixBEQ1uYwtJ +UcOW+ObllyozQQykOu0M1t9ihW3CcuMl0bHgUE82neqgorElrL+0Iw4i5iZO +dy+zQXZ7/OOjmgkwv15jyMrPFntV5QtaykngVPvr5aKi79F/Ski2jSbDBIUZ +tLvLDn0HP2rLBSfhHSdod4waDSOWDLbm30oBxlg84z1tM8rrmjMFwtMwGrL0 +WFPKFjQXph9K7Eld/FNHOavLHq1zWqLD+9KA8tg8p2HMAbWOGHqWdaeDQfZ1 +bxrNCStYvtFZzzOgZL29hibbGQ8tT/jmfN/P8FDfdZMszwUrVVkro3oywcGg +K5f6AjCxRXxnejgLlqvwY4PTEKOKp9utR7Jhdep3TvvMXVHv085SidpZUDcL +uO3zwBWfOhENX0zPgbWz3vX4wK0oqxOa/2jLgZghyj2mEh0vVtiVMfzPw5iM +48cooeN+5716DjE54EG9z2NYuSFLRtGhZV+Adpnj59knbhh09LfC+YBciNpg +K+kN24ZVWc5/FnzKBWdpaP8+dXe0SJSnXODkwTZTXWIZ3x3/ZQetW2uSD+tO +n03o2uyBGeOXUweb88EyzL7DTOKB2nmtotJALoS1h2c0Hf0Bhwu2NNbNc6Hj +cn/ohDYDNWtUOYFVBTD1i2KWeoeBhx/4bC/xLoQQs1p1HsFEb9Ge3vuThTBh +yaXdGGfiMKd7d3BVETRXfn4znb0d+Y3vau97FYO/mwk6rvZEYcbMkrDZYlgV +mdVi3emJsezuwm2NJaD9VUQjsYfAgmoDFU4wCZX0k0nj+wgcsWmLrAolwfZk +Dp0bQKCglq7RwSbBa7zhuTiYQCPJKvlkJAmZL6bnQyIILPOqjQtMImGOn7I1 +KZVAH9mA1IlLgsSR21ddSyC3fOMa8z9ICD9eeYlRT+A/DqNc924SZupvhY02 +ELg31B/Zj0igGItnbW4TKDEMp1/rJWH7UkODtk4Crx+TT1KHSGjtrw7te07g +oZGbco9ZEpjLm63ixARGtpQqDi+QIPYQzugOEmi544pDrpyEKcHH7P1/EThR +vyJgQIUHVlc21o18IPBusQsRpcGDVolrHOcTgcyRWt0CTR4wtXYBdZzA6hcH +DQUreXAw63hv7PSiL/n1M1VDHkx1ZvJ05gisoNakW63hQdpCcYhggUDfxJeR +viY80LC7tiFQvtgjPpGXbM6DskjBtEJBYPzjPCnfggf/AefHQ5o= + "]]}, + Annotation[#, "Charting`Private`Tag$9195#1"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0., 59.99999877551021}, {0, 2}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, {0, 0}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{{3.8133903865194016`*^9, 3.813390411298749*^9}, { + 3.813390452139729*^9, 3.8133904703948793`*^9}, 3.8140003554958754`*^9, { + 3.814000425269477*^9, 3.8140004415039454`*^9}, {3.814000608612451*^9, + 3.814000680291408*^9}, 3.814000783368565*^9, 3.814001139375784*^9, + 3.814001348548273*^9, 3.8140013868666935`*^9, 3.8140014312020836`*^9, + 3.814001502658905*^9, 3.8140015479978924`*^9, 3.814001738588851*^9, + 3.814001778356995*^9, {3.814001825312503*^9, 3.814001834045435*^9}, + 3.8140018902097273`*^9, 3.8140019282920856`*^9, 3.814002124390581*^9, + 3.8140021862763586`*^9, 3.814002514636649*^9}, + ExpressionUUID -> "b7a48b76-0348-4da3-a4e0-8fe4e239562e"] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{"uact", ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "12"}], "}"}], ",", + RowBox[{"PlotRange", "\[Rule]", + RowBox[{"{", + RowBox[{ + RowBox[{"-", "1"}], ",", "2"}], "}"}]}]}], "]"}]], "Input", + CellChangeTimes->{ + 3.807901752109039*^9, 3.8096918329907913`*^9, 3.8096918808513126`*^9, { + 3.8140010922578707`*^9, 3.814001097057517*^9}, 3.8140018836311464`*^9}, + ExpressionUUID -> "d923dc31-aac8-4ee4-b011-a1e08ba854fc"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwVx3k41PsCx3GhKAmFSotsM2l1terE51tHKtVBsjtlz9FC7imyxElKY0aW +KBnhtCBLoazDDMbM/FQiImXLKGsU0aK47h/v5/28NFy8D7tLSkhIJM/0/387 +cDrZ3DvaKObBNt2dna3cy2701S9op+FoHZUjVirgPh/u8WLRLiBiJK3n47dM +bpbK29RW9mV8iZz84+Wbf7mfCn5nnqRFoV57bYIkO4mrpttcNt0Si1RTpbJT +gjiuoT/jPxQ7AfU3T1kEcxlcJ6FReqzzLUj4NYmkW0O4F1XHljvSbsPpadRU +np4X92W+JRU7nopQjsVDvZgDcHuz/tLXln9BxPGcuUa+GJ8lC8fSu1CM2+94 +KzUEl3W7v/PY96E3GrzCcygciy04j3VCMqD4XnzHKDISGf4J3gznBzAvemtT +cCwaT4Wm7y1pufh2blNGp0I8cv0WmjtKPwLvcLOoWu8G/CJDcqLGH+Fx38Pg +UP1EyBbYeY615IP3UW1XwHs26gWCGh2qAMqjVi4S7NtIfLNJy7b0MSLsb7IU +1FOxRnJBB4ddCH+7B3Gq99MwqhL42wirCLwH08mMP/9FmW7fTY2QYqzrW/T3 +M/k7OGhRZXnZuRShRZ3ZzfZ34Z16jjKjVSC0LWLdx/z72P5YTLu4mAufpIuc +rYbpkHBbvdtemoe7BV1Ox6rTQfnFpzDHeTDSt3xryM+AfYq3/eeWKiyp8x8r +TX4AI13aVYZ5Nb7EOjTmz8+CZkFbkRZVjamPXsum/LMwKNivYl3KR+CEPEve +NBtBw1r1pWwBXN8YFis35MDJ/82UpYoQNjW3PSrW58JYMmb9R5YQtrP6XkZE +5EJedYqhHiKCRYBCce32h7ht+HrPJedaWLqKwwd2P0Ilk1l2iFaHDwduvB0/ +nYeKgdZncpl18JX0xePreeDso3dQa18gI3qDVGNJHhwknSXuLKnHksrktSaS ++bCqmNRUX9mADHm5M+HMfJhu/Y/nYt1GfFLPONV6tQD73rf4nPNqxATn4JzE +9ALsvX7h/KusRhzuf7Z8nF8A49GnjLgNTRgqej7MnCqAUa5HjsLmV3j6I3pF +8KnH2ERjj8qgBX6vNA+u2/kE+q92T3qEtqD2rlJO8ZEn0LvULyWobMHrhoda +s049wYburSqXjF/j5yoTlWfsJ1h9u2GbhGkrzELX9Xp/f4LlqjLB3468Rd2F +oYRf6YWYPcdXpt+rE0smyDqZd0Xo2x+iMJbeiUKPzzukR4tQy2Iu/tXTiXC/ +NeldksUQMhrjIjZ24Tem0RUD7WJELhy+w87sgkvmPDt/92Ioa2rx+cnv0KHu +2Xy1uxi0XSxplctiKPS2+TCpEiwWx8neuiuGhUnMnh0tJZANvzVfvVoMmaHW +/pc9JRgQpSvrSvRg3cufd2umS/DQvErbMKAHj4bteEWbS7Hd6aux++n3kK7V +6p2VVIr9Ic7hT6x7oRZxyPGmfRn0r1WapP3dC0XN4+IG9zIsT9GQZcX2IiN7 +luYvnzJ8qnjHcKvrxQKTTivdK2VImHKOXmTSh+zDn0605ZehJ9gl6cyWfhzr +DLColeEgNMg1b73yIA6PN0zGZ3Dgxaz2Xao/iK/6vud/z+fgCFtr82zzQaz0 +ott8KOOAzhEXtkUOQjbQ+9r8FxzUTbpyIqWGQNyDTrR/4WB5oJuwf3QIBsKq +zDtG5Sg6795+r2EYD7INeg48Lcd9oxMtaqPDaG2oOxveVI4EqTMN1xaO4IcP +69iT9nKcYwXVnLccQcKWushvI+XYmhaXc+jVCHaF1Z9YoFwBh56uioCTn9BR +tDAnwr4Cb+QUrmn6fAbVdM9l47sKtNqf2OjrN4aMjn1Hz77mgtG99+SNy2No +iOgfNunkYoeXdiYnfgxr9rC3LfrABft8u6bM4zG42PGV2GNcON00U2V/GkNY ++ZmebTI89L7a9Kvmry84qNcmGafBw7j5z9qljuOw8Xi4OfQID0p7WR6V5Cs0 +WVO2/QU8KDa5529zmETODX2rEK9KaK06mRnuMo3YZCvrFukqbG8/9XRX7Cxi +dbI/931YFSp/hB5sSpIif4TqvKRNV8GTKxJVXJxNfn6wvKd7vBqJrulqKk4y +pHuewWAUvxrrbd9NTLnPJblKQbX1Gnx0jJnVkf1yRDIu6aqjLx+jnUv1VK3k +ie/uczW3qvmIzgo4bmOjQBpsbvHmLKgBTUH2kH+SIlEMY7QSsxoU+oRmRaUo +kYznroKJmBo06cTJWMQuJNohH9tfP6uBdljj6j8TFxHVIOqc3VwBDMw7N6ck +KRN+ip53+S4B2n3CjVhMFaL8h795/38FyDewk6+JUSWUfYRInC6AqrWwNSN8 +Manv6zO1aRYA3RIxVX8vIXtGHz5QlRQiUdVTnua/lOSlLbyRv1GIi7f/urLF +S40k9Bp137cVIrnupiDKZxnxCZc29QoTIvh03KcVvstJqP1S7c4sIQadVy+x +c1lBTs17o29dL0TkrwHpDo+VZM6GopCECSFKh/aOLLBXJ05zriiuXipCs872 +7h3aq4j9RH7DvB0ieOq6boy7t4rsU5JLyHIUodLaIXDXSg1S0V2jLxckwibb +gUzlNA1i+rTlxeJkEU6GmbQYLtMk958VXV1aJkKEh+yPWXGahGf8gV3VIkL5 +CufpAWUtIqcUJC83IULJ1GWpNVFahMHozUxQolBX8PsAS0mbNAfu+J63gULN +Kg8BM1abvI457RBlSuFSkVXau3k65GKMeHDElYKjZttRB5YOsSI5Bo0XKEwW +bly2VoZGUmbLqjjeoBAk1f8s/gKNsCOPrurNpaCqbeCsI0EndmJ9tw9CCn6n +rb/MO08nXny172UdFJZvdRPRAulk5+jz7lWdFHi/zrB3B9NJHfNMdfiM57FY +xgH/0In91ei/zLoo3M7iX++/SicZCg77u99REPTpbxHdopNlTkzbOe8pKLsq +nAvn0MnrrkTe3kEKJWtWmKZV0IncnPORWTM+OrpmZTmPTph1gYcUhihk/GMi ++MKnk4a40cLmGf+WGqzq9pxOdnTVq7sPU3BpHyzc3UEnJZm5pqGfKcjc+844 +2kUnvLawCPGMs0/KHAvophPt7Phyk1EKE5OaMvkf6OSl2Vl5+TEKDDV7G40R +OmF0mxknfqGwsfv4WsPPdLJy05adP2fclHl22naMThTPuq49Nk5hpUFMevRX +Onk1kjqiPUGhWiIlMPs7ncw1KOBfmbGnKNtMNEknjteVYwZmPD+6VKvnF538 +iBAcOfSVQp6N6Ov0NJ1kJ9cqPJrx/wCKDddq + "]]}, + Annotation[#, "Charting`Private`Tag$9233#1"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0., 11.99999975510204}, {-1, 2}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, {0, 0}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{ + 3.8079017783490534`*^9, 3.809691704144603*^9, 3.8096928396526885`*^9, + 3.8100079038078227`*^9, 3.810879859749193*^9, 3.8108799384067373`*^9, { + 3.812198556285883*^9, 3.8121985692109256`*^9}, 3.8122028292371397`*^9, + 3.8122862666355715`*^9, 3.8126319959338055`*^9, 3.8128095872200847`*^9, + 3.8128096263623424`*^9, 3.8128108868638406`*^9, {3.813390387433878*^9, + 3.813390412283187*^9}, 3.8140003557566094`*^9, {3.814000425459281*^9, + 3.814000441662781*^9}, {3.814000608805252*^9, 3.814000635488211*^9}, + 3.8140007834554777`*^9, {3.814001092681557*^9, 3.814001097830301*^9}, + 3.8140011394626937`*^9, 3.8140013486311855`*^9, 3.814001386968587*^9, + 3.814001431282999*^9, 3.8140015027418194`*^9, 3.814001548099787*^9, + 3.8140017386827545`*^9, 3.8140017784509*^9, {3.814001825396414*^9, + 3.814001834124354*^9}, 3.814001890327603*^9, 3.814001928370006*^9, + 3.8140021244694977`*^9, 3.8140021863522797`*^9, 3.814002514721562*^9}, + ExpressionUUID -> "f4c09d02-f49c-467b-bc33-2a9a1880cf7a"] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{ + RowBox[{"{", "ucon", "}"}], ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "60"}], "}"}], ",", + RowBox[{"PlotRange", "\[Rule]", + RowBox[{"{", + RowBox[{"0", ",", "2"}], "}"}]}]}], "]"}]], "Input", + CellChangeTimes->{{3.8075231455098195`*^9, 3.8075231760114655`*^9}, { + 3.807525114186741*^9, 3.807525163185214*^9}, {3.807603506209684*^9, + 3.8076035070258493`*^9}, {3.807603562587194*^9, 3.8076036552367115`*^9}, { + 3.807901798010665*^9, 3.8079018241459*^9}, {3.807901989241525*^9, + 3.80790200720923*^9}, 3.814001273079596*^9, 3.8140018836381397`*^9}, + ExpressionUUID -> "c825a9da-aba1-48b4-9973-9eb7d3d5f308"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwlknk41fsWh0WZTiqzEAkdQ9joknGtvX/fMp2kZGpSSho4ZYgSKU2EbpEM +J0lHKYTKEIUoc2rbbLZhszOTBpQdnct1n7ueZz2fP9Y/7+d9lprXiR3eggIC +AkmL+7+c6W14qxFTaK2o3aS5p97Iuu2uwhk6Jx5kbKmfxRaSgLIfvBQ498FZ +q5IfZakGwU7ZHUKcZzAzsazS29oQJL/Ix892VINV7YpNVgw69L1yPPG9gwUv +DI7jEvvtsEVjnDvZ0Q+dvyul53ocgNkO08RvHVOwnmKtCD3jD2+orMyW+0J4 +zLp2X0lEJCj3lQ57bZBA2d8lxURHYkDG1zNbhJJGrdj9AQGF8RBvuOWlo4sC +bp3zM4wTTYbOZNrryVVrMHmram2dXhrEZEZ8EFytho/4hj9Oh2aA/K2B6IQ0 +dbT3VBp94psJV3faWbNmNNHY7MyHzTZZEGiW4dkQqYWJukF9JyKygXydC/1z +QAeZl2QDnTOewAXL7QcUN+lhkpzUPONYAZjnpRSeqzRAB/MCGs/8Gfj+nDxf +L2GIr14UfddYUgizuqt69VyMcJ/7xvIw4WKwzMm9d/u2MQafMdV1UnkBk1L2 ++12rN2KT8YJ6s14ZDMbudw0QMcGXBSUOnTGvwO5riN2QiSlGK/bTdg1VwMRB +0cDCiE04XnjjRd3714s+5QWvVpuhi/p0sbt1NUg1r79e8NUc2bmKzdP5b0A5 +Kt/JxMQSoyvYRUyvGkjWNVsl7WOFIj8KLjWp1EGjIv1f0zetscrvSXjbP/Vg +rlx9w6AdMOzshmp56yZYIXQ/6EAkoo2G1Zk3ac2gckHV0mM9HV1P3qhbZceE +vEDRdVwtOuKTlm3u25hgfXhS5IAuHWu+UTN/uzBhr8Ob1iM0Or5eduK5jRcT +7sj6HD9tTseYvzSjq84yYXV2XmqSIx1tK2aTL+YzQabVapYdTMfvjhlBxxVb +QExzT/GOOjo+sm8+ZrvQAsdWg31OAx2NUfuVrTALGiXW9Qq9o2NFjdcGRwkW +xM6MLCti0rH2n2tXjyixYEV9oIt8Fx3drq1b6DZlgdTxmO/dE3TscF7De+vP +AuWnZUbeUgzEvYEPO8dYEPYgrbZchoE5Rvcr4yZZwE05v0tOnoHFO7Yut51l +wd3ILZF1Sgx0V8QjH0RbYe1OVou2JgNfVUva6Wi1giZ/7OQXUwbq2ofOrD7S +CvpWq/ND9jJQ02WST/vcCs/Vj/4S3L94j1ziEzrTCpvES22uezEw7dGTrncL +rcDocOdl+jAwWmi/XJxUG7j6J0uy/BkodteRE7apDSIeyAdtuMJAhUCFpTpX +2oApIWf2MY+BZUbKBx202eDy3fuy71MGiiTrdHUbs6Grq6iF/5yBSlIb50Os +2TCY5XJsRSkD+wWtilqd2fCTnviXxRsGel681agUwQa1YJn5xA4GemzRWivC +YUNAr9QbewEKV44c2q1xqx3qa/eUZwtS+PxFg3JCejuo5D8sEV9GId1nOmZl +Tjs0RpjnNopRqLaQxDesbod1al6J9tIUhng2lK2dbIeWg0997NdTmOKbv7Vm +ewfQxrYtt/+Dwji6ajSlyoErLSnC2Y4UerdTes82cKCndEBAfDuFX0K1S4zN +ORB1LeRHgwuFDTC346QLB3i66b12nhQq0iTK2bEcuPHnlwK7AAp9Smw0Ly9w +4Ot0rItd8iJv1QeG00wn9HAyXNNSKfzEMji1WbgLGsuL3SbvUCjzI2eXi1wX +ZF7leaRkUHiZHfao1qQLdilt3DeWTeGvkMHk2dNdUMPoPhxdvsjvV/x4VrAb +nv3+zYdbSeGTpdfD6mW64d7yZUcNqyk0NHmZ+GJ9N4S26x/vrKWQH/Ilft6+ +G2jHIk9oMykU1Ma1tMRu+Oum9umG/kVffjfUs2g9EBVsfWbNEIV7U08zm0gP +BO92DvUfoZBR0q+o5NEDTprhYasnFvt/kD9kGdkDwqXM80d/UDhxK6HtbnsP ++PNCosVECapNyPHvRHFhX03stb3iBGvLWPymdC78kZ0R83Q5wfrhqXDjEi6s +D2qK85AkmPA6+GzBMBd6RFTjHysS1Llo/jLSthdsDGpT7fQI5knfr81R6AN3 +YdudTAOC9gnl9k4mfXCM2yDhZkRQdJQTtH1nH1yPaT5/yJSgiaXzXMDNPmgf +aTscQScY32npYCnKg9EK17XChOBuWYO6vxV4MJfI6YzdQnAu8aws0ebBGtLz +R6oDQQOFX6f+5cCDQ/cGjIpcCGYJ7LH4LZ4HwSHeExbuBEnvxc4jmTyIchx5 +UL2L4E0Vy/cSJTzI/WdcgelJsEyn/p4JlwfT7lPz40cJjgU/9LDV+wiRkkua +1p4j6DtXqyrY9xFujUZeyjpP0C29MlyT/xEeVi611r9IcF5aNe/tyn5o9BN9 +ahFFEEOLFWIY/SDZuDLJNZ7gr3TxoO68fliXcdOJe4vg9tIeoYimfth4Wlr8 +UBJBcaWZqJbRfnBfLx/uf4fgHRf2toeaA3AvUuVg7EOC2ccF2TqPB+CZxz1l +6ceLPm/H1O57NwBvaevaU3II/ueS29U73wZgtFfTLquA4F7bhLQQy0GYK8oS +1H9OUGZq3zLzQ4OwPE77VWERQQWxre+d4gbBwELPoLqMoJ9DJ+kZGASUyh+1 +LScoa14uGiU5BDvGaPc/VBIsrG/T4+MQBCdtlOW+JVjFEqYVPRiCqD+L3x+s +IygUaLR0d/cQpG7eFDXeQJAhHPQ5UHoYKqYtfvHfE7ycn678M2YYMt6VeDm3 +EBw4uWPsQv0wXHpg3JjXSjBjasWsvugIHD6XbyjeTlBYRU7dzWEE7Nx0U7w5 +i3xHK8IPxI/ABlqWQFUXwVN259bUc0dghZj6EWUuwVnncYk1+qPQVqZo2vqR +YGkDrTCMNwolCbfv6g8SDDDrfOhHxiDVV0r42jDBDk4zzezpGIRtvu43NErQ +9KLO1mStcfBUEWfjp0V/gauzWbnjwOBftrzzmWDYVGKVEP0TaDCXZPK/Eswv +k0r999gnEHkc/pvzFMHHNeqiP3InYPzCbEDed4KWn7hVRxI/Q/OuU11ifIIF +o2YSboVfoMB4ku49u/jPZudInuw3iF/u9/j1L4JXrv29MKQxCaeGRlcpzxN0 +1L963UZuGqR3V6Q0LxAU+P/gfwHUnF5Z + "]]}, + Annotation[#, "Charting`Private`Tag$9272#1"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0., 41.99996305665658}, {0, 2}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, {0, 0}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{{3.807901999933651*^9, 3.8079020081905165`*^9}, + 3.8096917044024553`*^9, 3.8096919364340987`*^9, 3.8096928401184244`*^9, + 3.810007904017606*^9, 3.810879859816123*^9, 3.810879938471672*^9, { + 3.812198556334833*^9, 3.81219856925488*^9}, 3.8122028293050675`*^9, + 3.812286266718486*^9, 3.812631996097636*^9, 3.812809588171404*^9, + 3.812809626917245*^9, 3.812810888395961*^9, {3.813390387680737*^9, + 3.8133904126579714`*^9}, 3.814000355832527*^9, {3.814000425548193*^9, + 3.814000441745696*^9}, {3.8140006088991566`*^9, 3.814000635594102*^9}, + 3.81400078354838*^9, 3.814001139550604*^9, 3.814001274744955*^9, + 3.8140013487200956`*^9, 3.8140013870554996`*^9, 3.81400143136791*^9, + 3.8140015028287287`*^9, 3.8140015481986856`*^9, 3.8140017387756577`*^9, + 3.8140017785258207`*^9, {3.8140018254733353`*^9, 3.8140018342072678`*^9}, + 3.814001890418512*^9, 3.814001928458914*^9, 3.8140021245562005`*^9, + 3.814002186439192*^9, 3.8140025148104715`*^9}, + ExpressionUUID -> "6cbc6d78-4783-4c10-80c8-1acee75f73fb"] +}, Open ]], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"Plot", "[", + RowBox[{ + RowBox[{"{", + RowBox[{ + "Enernst", ",", "ucell", ",", "uact", ",", "uOhmic", ",", "ucon"}], "}"}], + ",", + RowBox[{"{", + RowBox[{"ifc", ",", "0", ",", "60"}], "}"}], ",", " ", + RowBox[{"PlotRange", "\[Rule]", + RowBox[{"{", + RowBox[{"0", ",", "2"}], "}"}]}]}], "]"}]], "Input", + CellChangeTimes->{{3.8075231455098195`*^9, 3.8075231760114655`*^9}, { + 3.807525114186741*^9, 3.807525163185214*^9}, {3.807603506209684*^9, + 3.8076035070258493`*^9}, {3.807603562587194*^9, 3.8076036552367115`*^9}, { + 3.807901798010665*^9, 3.8079018241459*^9}, {3.8096917823267193`*^9, + 3.8096918106604476`*^9}, {3.809691900688919*^9, 3.80969190105171*^9}, { + 3.8096919597212915`*^9, 3.8096919660196705`*^9}, {3.810879848136751*^9, + 3.8108798554060974`*^9}, {3.8140015627992744`*^9, 3.8140015666626587`*^9}, { + 3.8140018669132705`*^9, 3.814001883643134*^9}}, + ExpressionUUID -> "c825a9da-aba1-48b4-9973-9eb7d3d5f308"], + +Cell[BoxData[ + GraphicsBox[{{{}, {}, + TagBox[ + {RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJxTTMoPSmViYGAwBWIQ/e3eySMq3VvszqxfM3er+md7N5VXdz9ef2QP4/+8 +bj71w/VPcP5h5+VLLi5idoDxZe7vfJakwwvni+TEr2J3FobzJxm67fYLlYDz +b84wOPBRQBbO715Sf55JUhHOF5/yuHPyXGU4vz3E0+7SN1U4v9hyYfzJJg04 +3+X9r6q8x1pwfqNNYKKUhS6cb7Vu5pa6/fpwfs6Pjw0neA3h/J/aAvd0Q43g +fJvVaxZMm2YM538U8koIO2QC5z/pSQgrYjeD8z3fl3s+NTOH898kcxRvqbdw +QISnOFP7IUs4X+isWt+G91aI8OtYH2BmZgPnz9C2FBBOt4XzT0k5mn6eaIfw +j8yhCfrX7OF8PuZFJYlNDnC+XKO8TaSaI5zPqRqzLeg4gq9nK7m+PNYJzi+6 +J3TYi8EZzn//uSfUcwaC765/bJanrgucv++z9e/v5xB8BjBwhfPzdIxuXUxF +8G3fpVyJ5HSD811VJHx5FyH4Gg1dFYfM3eF8rVTL/aq3EPzUfRktWwo94Pz9 +C66kfBT1hPO/rPj/XX87gp+suppzlq8XIv60Jptt+oDg71jy++HXDm84P8pF +2cFazgfOl85t36l3AMEX5crZ6BvuC+ffsp58edlqBH9e7q6v//8j+ABReLUD + + "]]}, + Annotation[#, "Charting`Private`Tag$9315#1"]& ], + TagBox[ + {RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwtVAkwlQ0Xlp0iFEqohJRdKlvOufd96wslLZZUQslHi8SPCkmShK+UQlL6 +iE+LfUskJUsqW3bX5V5rt+u+F1F98ftn/jNz5syZeebM85x5zlnr7rPPQ1BA +QODjQv6vfmfUv1O/UWgpltBlEloxC22pK87TOuOh5NGureEBk4Dyn91XdD6G +OZnbhszlk6DQIyshQz4D/2SeXHoPHwLssjuEOvNBgTGO/Hw+uBV8yJ6PLYFW +Zvp9u9t82KXwLeQX8Qoohdir3uf5kGJxLetXcBV0qnN1zx/jgyxXMf5HRzVQ +Lp4rTtvxIfJh1sUZoxo4xk5efw/48K+dqcd0bC2cUaY1XDLgwznBBtvJ0Xqw +KOKVNKvxYbTA2YQiGqFw0m12twIfXDy+rp1I/QR1M3+XvZPkg/fiyqvfg5tA +y6zzs4wAH/pf2fpMdbRABFO1tZRDQbK84nE/kTbwH2y7Ocai4MCZfie+0RcY +FjFg3+2hoGH1WTovtgNqLZ19NzVScDXIZKtPeSd4KPVEStVQgM0COtzRLri4 +i2NoWklBcfgteQ7RC/usvHW98ig423NQ8qRvHwh8/5js9pQCbWO1+bFUBrTv +Kb91O4OCpnMHpyaDmfAslWl0O5mCHerjfVTHIDD6dgg9jqQg3c7WKe8MC4yG +r10RCqdgUUh+y1kRNnjw5gQjQyh49eVC7YTREHj7sy4N+1NgeG1x3rfYEfhd +56MwdpyCuAIf7efqoyAcXDuo7kYBp78141T5KBTtyFoccISCJyYpyV9Hx8Du +U1HIAQcKlMd1IsYIDvgoV74a20nBBYVbc1ndHOiZf1Nasp2CDvp00J++32DA +Jv7JHToF8fcrTo+kcuFs3Q+B8xYURGhmPuUH8yDIeUalz4CCHx1bE3gdfOix +kS8tWEVBqZG4a+aGSYgTzVUQXklBQGznRpeLkyBZ4uvhokABn36+6oPqFNia +2dzQl6Vg/PnLr088pqHXQKzZXIyC3ivb6EcmZ+DU16taNVM8SGZISS3fPgtp +0/Ntd/g8cDJldDTcnQU/+eQcbx4PvnBDT5uY/YCQ2tO7tDg8+HSwKnHZ5Z9A +agwIj7B4UKVPTNRL/4Y7bzzS7dt4EBq97GWY628wrFjMCmzhgcUQK2Jr/m8o +dNZxSG3iQVlyhFKG/Rzox6WGzDTyIF/k/fawlHmoM97o11nDg5bT6rar5Bdh +7Yk4WbKUB2+JzPTmx0IoNPwz68BDHhjE5YzN1Alhseth66kHPEjtLNFTnRBC +8+7XnISUhb2driv1NhdG54Tb8v1JPNC7N9Yo1CaMBxzm10fdWdA7rj29WUQU +awLqD+hH8+DsrdztyZ7iKEytLM8K4IFyf9mwu44UPhBzKbXdzwOBSd/E+r1S +qJma2WG1jwds0Y3WBoFSKFim1rJ9Lw+e6yU///1GCtPXPd6De3hgGXrBP9FR +GqMCbfTBhgdHVcwFP4UvRfMYmxx3ggfNuoy4FI4Mxvgejd9kzIPlp45mixHL +UCnt4NknijyIN9xRbmu/Ar807jh17fUEdCUaVFEyKqgiv1V7vdsE3Ei/9Flw +5Vrc5LhPLWfRBCjeYV2//WAdPgrS2eSRxYVrB6wsW75rIN742+6BIxf8TNOO +1odrYagAlKcu4gI58fPCGdZG5Ja2+Unmf4PLFnvdlEx0MYFoNpM7/g3MXiQV +hr7Wx+zQ+1yu9Dc4NUuF1UkZomuIdPnFSg780JZh6Nob4Rz/GedvDw5YPH32 +6O7dTZg1MaRnuoQDlJy1q0O1MVb9kxjtUvwV2DGuDufEtqCWl8rRn/ZfwWoi +0Gpoy1YcDJ+asZ8dB84xcb/CSya45/RGvRVx4wv3qyh4rdoUiwwPGS9eMw5y +HzXjcifM0LJN9iFZMAbKUTl2W7ZY4BcDW7VDm8cgUdtUZpnnNhTOiwusLR6F +BiXa5slblpiotaXPw2AUzJSrb+q3A15hBPIP3RwBaaHH/m7hiC76jVKrx4dB +9fJqi4OaNAzyHJ3rURmGF37ian1aNDxlpOkYojQMlicoMTdtGk6c8MpQVhyG +IzZvW/80oGHgZ9WV9jLDkCLveTLIjIY39bhLnwsOw8rsF8n3bGnouHtJ5ffh +IVjeuu3HlwAaOoyZ/ux5PgQSGoeL99XS8GNH0Ak944W/sxKsn9bTMPFfd/8g +gyFokFJjCDXScE0S9/trnSGI+T4iUtREQ25Qu/UfGkMgXednr9hNQ2HN69Vb +FIZA7uSNqR4ODedv8s4nzLBBOe+lkYccHS3kS12NS9kQnPHgfcVyOtI6VCU1 +CtnQlxTmrKBIxytxzx7I5bIhNXxHeO0qOjq/W+fDzmTDmgMtzRs06CgUvVrH +/R4bNGbGznK30nH5SRWvN/9hg962lTmBR+j4qfDw+LA+GwrWef0SdKVjHHPf +N3FtNphIlv0R505HL/Gj5zQ12UDvcGKme9Jx7KNP/35lNjj4Jsq2+C7wCy7a +GSjOhksZiv46kXTsGr+u2NnPgiYpBdOBF3SUKPTxLItmgf2Ux9VTeXRsEm7z +MbnKgu7uouaZAjoKBnEy8i6xgJ1p7y1dRsc6wtAz3p8Fs7SE++Zv6fjrvVbd +YhcWrA1YPpfQQcf18bfLm/VZcI4h99ZagECVmdiT2z4NQt37wxXZggQuG8O/ +9tYNgmrOkxJJEQIl8K9+l+pBaLhk9qxBgsAhkdm3x4sHQW2te4L1MgIvL7pW +tSp1EJqP5XlaaxJY7LimS/PUIBiM7VlivYtAjSmU1hAchMjmJNFsWwLHfUVf +mP4agN4yloDkXgK1WggGOTUAUdGB0/X2BNqEVUVYDg8AU/shw+oogRfYfszy ++gG4eYaba3WOwLqRFM67uAGYmIyxt0okcLdI6d51MgvzOtMcHiQTmFeboPhd +bAAaKoodqRQC70r8jCyfZ0L6NebBpDQCYwr+eq4ywQTnVcYuY9kEDs6vmTb9 +yIQaes+J6xUEThVfmsuIZEL+ep5n32sCo/O56jEhTHi0RMTLsJrAyPktT938 +mXChXe9k13sCPwcc6+lyY4KBd7jPhiYCeVk2d2fMmXD/1oag+kECN8dzd+/v +6oeoAMvzKkMEakfuXtPwrh8CDu2/4DtCoMw9uUMKuf1gpxESvJJDoJ8ER1cn +sh9Ey5rCvKYJDAtWsDAx6AdfZuB1CXES9XZY6a+4yACXmpjoI5IkWrz1XHz1 +GAN2ZafdyFtCovrhcc8yGwZo+n+IPShLonjWb/RfxYBesdXx/yiROCoXNClb +2gd/6L9PttIlkT++sr+e3QtOojsPNOmTGCw9JV/2vhe8++qlHI1I3MIIem6T +1QtxNz6GHd9K4r4Y49d7vXuhfaTtxCXaAj5tSdr9sR4YrXRYI0qSiP66Sa51 +PfAzobMrZgeJCpUGkwVPekCF7N2VbENi9yONTT/ceuD4I5ZRkT2JLzZPzz5o +6YaAQA+OuROJKStWDwQ874Yo25GMamcS20afqr251g3P/h1f0XR0gT+1dOSe +WTdMOvHnxr1IXP5A+m5NYheEyy76sCaURLkCs7Bpw064MxoekRlG4nd+/x5i +USc8eS1sqXeFRE1L+ctJnzug4bR4nnkUiUF+jMHNXh0g27D0nkM8ieSQ2vBI +XDuopd2y67tDojGrKmKzfTsYBy2TPH6PxCpYBRpK7eCkqRjim0Limuu2uzMe +foFH4arHYp6QeKFpqmbibhvkH3ykvOwfEtkq5q3Kdm3wzkCtPekpiaE7jHdu +EWuDUYaGVWYuiU8qQldln2mFn0WZgnoFJA7WLrN/qdoKS2I3vCosItFF83bL +2sYW0DfX1a9+SeJ7pWKFzaotgHI5ozsrSIxOqM89V90M+8YMHn9+TaJd+/24 +DceaIeCesXzfuwX9Z/7mdCQ2QdSZ4k/HakkM4OaFrtVtguTtJlHj9Qv8mO5d +Euc/Q+Wk+a+ZTyTu1HAmbBM+Qlpjifv+ZhJjOE4Cro8bISJjU8OL1gX8y5py +9uMPcCI0x1CynUQBSFoRktAAVo7aSR6dC36c+k9FTFA96BhkCrzpJlHYJdRJ +27oOpCXW/ancR2LvxcPlMuK10PZSaWvrAInvcljRwtveQcntu6l6bBKXeO4W +vvCsGpJPyYlGDy/06nMbr85WQfD2uNNDoySGPRXRiDCuhKOqkl/wK4lRvUeE +1WVfAn3mqkXKtwX/2a5Tlz5TBOpNi9JnJkjM5ZbaqWnlgtg/IYv380nkuU00 +tCqkw/jlH+deTC3Ma4yJ/WEYCZtKEkW9phf0/D/+C2bGL74= + "]]}, + Annotation[#, "Charting`Private`Tag$9315#2"]& ], + TagBox[ + {RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwt1nk01fkbB3ChQpF9X8rElJ3StT+PfcjXWFJpsmRpzIRKQrKnVIPGMrZk +IqlhlH2Xi3tdu2uLrJWIyJqtwu/+zpnPOc/5nNc/7/+e5ZDLZRt3ZiYmpkeM ++v9v43UvZ5MvE5j+eyjQ5SI8mAXkVbGSbT0fEBzmYec2+hceU2wH19riwc8q +d4BlsAhKyqXepkymw4XittydmHJYbk4fTXLIAgvBz8HfDGtgP1vrxfk/n0K6 +TtTzb0FkcBvnkM43fg4880LxmwMNcD9c52HDo1y48/fzm+tqVDhW+j6Y9+W/ +8N1K0301hgb/yFUsx959AT7MrZYr0y1gbXXm1hXRApguPqexZNgOHtcN3q2M +FoCj++yhhYxOoBw7UNQZVwi/73t1ey2IDqvZ94ptNYpgvMby8peBHhhP/Jvm +6FYMaQJCbtd290H3yeau5LliOOU9fnZZrR8sC7e/7/EqgVapKwaLMQMQ7/PG +i2pfCrcDNEiXqwch59iRtYu0UsBuJoX56Tfg9sExe165DMoi4gTmDEdgdOLX +H31WyuDKsD3HpaujEBEdr6DwcznIH5femckYA1JeuhDxrBzoPvZfVoLewrt4 +5uM9RAWYHP40ujTwHpxlBq6N3qiEbCvLs4XeEzDE2qfNXFcJu4KLeq7s/gAr +3CyxgsxVUNMfSFtQmwS00mm7HVEFqlH7Cj/HfAQlyZ/PGF2uhtjiy/L5h6fh +YRiaknOqYW6896ln9TQcUvppdnKkGnI00tNmp2fAqUgk28u4BsQ/KUTOGM6B +TXah5hJbLQQKxm0/H5qDDpH33CakWhgwWA3wuPoZOsr3mOa51UL8w1qvjxnz +YO6bptleUwuRss/yloMWwVfUz9Xa9RVsDpD+WhxYhr0scpXnH9RBhRqb87Oj +K5BQySohVloHfjGDco43V6DFtP6t5lAdLBvcILdJfgEJnZTI0zxk+JRfNZvj +vgpu7y1/9DtNhpFbugYOK+tw99IjmYP9ZEgb4+TkN96AfVULSzsTZDirOTbQ +mrQBmnTlrfxlMvTPh3hpaG3CHZLK1I0D9dBpT07hC/8Ka4NxW0sm9UBWNlxo +4doCi6ahRLMX9RByn68qzHkLVhVtqA+q6kFnciKSVLQFQUaZTCVN9VCZFin6 +1G4buDw9b6SO1UPR7ibjsPQdqHjo5DK7vwF6vA5bignswvU00FJza4BGw2fZ +3VksmP56hrWcqRFUYl/OrDez4CyXQbQ6eyNkDJYrSS6woG2yY8MTnkYI8Gqu ++F2bFV9keqhZSTeCUvJMO0sfKxoUWD5cMGiEtE/yq+q792DYpS37gPBGuBJX +YJz2KxsKd5GebX5phLHhivvkGDas3I6Lo39rhJOy9V1TxWyYaF02kc5MAdnq +bvtjTOz4jGKqL8hNgeEPy17tKew4bbNm+UCOAiYa6knbLRwYj7+4lDhQQHy8 +cspFgRMzpBbTQ2spwLRyNaXFmhNT54KcxRsp8GGPnLmKPyd+UG3dKWymQL5S +Wv5WPSembFeINPdSQC8k0DflDBd+jKzPzpyhgJOENnNnxAHEtjvJwvxU6FYc +i02f40at00WeIW5UoJCqPv68w437r0fI2/1GhTL9JGTh5cHH3A5pst5USLOz +XP6NxIMCIuFllf5UcAl+ZUeK4EHV2KjDWfepsNyeId4jxIuKdbmGt19Sgd/T +KXevIR9OqU45v1mlgtzeJ01WZ/gwmFJw1O8rFTBr6n3qJT7k4v9TkmuHCp6D +XmIKiXx43q+gRJmtCShGQdFWk3yo+qgwW0u0CXwlUr1To/gxrNyG6q/bBL2d +PWry7QK4Zix+sC2sCeJVTaot7YRxsvWzhPf3JlAetjfV9RDGTSm9qdc7TdAe +6dUrf1MYZUOSOXRZaLBnMHGWLVMYDe7m+e/ioMHNkAmxxjlh5BfRtr0kRAO3 +trAgUqQIjvzx9GqTKg1OuFfrHiwWxen6gCfFbjR4k6JCXuKWwOJpGk2cQoM/ +skO7mEUOoe7Kt8aiwGYQSpy4l/DoB5TelKRyCLRA1CkzvZ41GZyiFUmIJLbA +Nc1Mp5aIIzg+PI/nDrSC0cLXQO8JOYwxkOB38G+FcB3rC6IainjtIvO5hr5W +0HqRWhJSp4zgZazJqtYGnhtLYc2cqhg/77bxIKINNuW5xxTt1JAlA4539raB +Tt6/j5OSjqFLsauylmQ7LPGaO59uOI5ZY7Y/+Tq1w4do59M+e0+gxlFFdbms +djBb8DebPEHC0qEyi/2j7TDnynatJFQDcwbiJ6NFOhjzUYg5qkETT33bHF20 +7gDeDtnYggUtzP5Hv048sgPE7760OnFCB+3LrElCFR2QIq/JzferLjobFVXe +n+qAVlF99ZU4PewjboiY83aClnjDn8qvAXFrePcUdAIXS5bvhQhEWUM26yGP +TpAMl9Kxl9VHpncdFY8SOoFd5nyZDU0fucrex/PWdIKSrshLfwcD/O7+JPPe +207wGeNtNGcyxL/uhc237OmChZVoO7MUQ1y8YBX6y9EuMFVuSjNTNMIZ6yDU +M++CVyva39Y7jXDQs4913LPrv71rjKUel/7g8e8CbwW1oW53Y7TUe5CpF90F +uvNuffbsJjgkm6l3Mr8LjA8LE5xZJkg6Er5h0dYFR8LuBzSQTNHq8ct9ax+7 +QM5ds05myBQty6T1pFjo4P7KI7Lk6k/Ide3s/kluOtQ97nNbEjDDktldJT5S +dPjyfGdduZzhNbFJZ0U6uMrksacR5njP73Q+jxYdluQSThQtmuMyoX3qlikd +KrK/vVu9exJTCqbrabZ0OGf0A2pLWmDSSoJpjBMdxLyiKpXIFnhdKmRmvycd +BDg8C4kzBG4fWC7296dDtmFw4KI9gVM5bUdyGVYLjjVMOE+gCqPRRhi2XCzo +H7xAoN+ygqd+AB3uvF7ddPUkMF2dd4TjBh02skINAsMJfD2aO5EeSIch7YTe +nDwCj2cUJtcG0xl3QXa62QsCO1UOBS8wvPai1H2ugECuv6QdD4XQgVd6cF21 +jMDC9VHe2wyfZJMQryUTOClBmFqE0qGmL8ett5/AbOaakTdhdDDnqlD0GyTw +aHrOzX3hdBg0bVkTHiZw6JayoC7DX6pm7zq+ZeTZSek9ZlgxUyV/5hOBnH9H +21+MYOQN6ftFfybwjGlofzLD5vy2oLxIoJWHINHC8MWo692+qwQWy6grK9xi +5JHvpAltEEiYv0p1YDjia7Jr1VcC19bnd2IZ5j7+j4LDFoEmy7QLZIYzvKpW +d3YIzPhuVrfE8P8AEZG5oA== + "]]}, + Annotation[#, "Charting`Private`Tag$9315#3"]& ], + TagBox[ + {RGBColor[0.922526, 0.385626, 0.209179], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwdkHs0lAkYxh1OZHcrO8gl2lyLQqyU6/tqXHYm3yShshSDRoUkuVZyWZRJ +GLdvCuXWxhKlYnJb7ZapLYmaMUpbas8qDeM+2snafc55zu/P53cePeZRr1B5 +OTk5xlL/4+ww/zfD7GYny2ixn7X3Z8eBMs0EZ2E+dHiIy1dRBp1QvZepKawA +PUb7WXvKqFOsZ61AQXgD9N7EMd9TpE7fijXypYJuuLc+aQtTTRletzGOTgue +wWnuI3GUhha4GX54JRG8hasnUfuirglIBVsLJwST8FSkcWDRxBbuUa9W9VUo +INmu2mLqQwed161/MTetwBNNSokZlbtBLfxArRJVFS1VtW6+Wu4H+ZZudxk+ +mjhg0/j1cFogDJZs7pKo6GLRW5/F8ifBkF2V3CuvpYcJ2mPNQhYLNApGznJK +DfDg3ejg+PnDkOlNc3o2a4T9D3N2ue2OhOO2Vw7wUzfgmuYbU/GLUeAyvpAY +OWKKb15+qTbiRUOKw64g7W1m2M4v118WFQN2DWTz6U4L1DeFjZd2xkL4vORM +zwpLZHXEPT6mGg/SjSrDZj5W2KcoW1CTTwSHul8uFxV9j37TfLJ9LAkkFHqg +b7c1eg99VJfxTsE7dqBvtJINhi8basu/lQy08Tjae5utKKtvyeDxz8BY8PLj +zcnb0JifdiihN2XpTw35zG5bNM9pjQrrTwXKY+OcxnE7VDuq61HWkwY6Wdc9 +bWwcsJLpHZX5PB1KNtqqqLIc8dDK+G/O9/8ED7Wdt0zlOWGVInN1ZG8G2Ol0 +51q8AExoFd6ZGcmElQoVMUGpiJHFMx3mo1mwNuU7h33Gzqj1aVepSOkcKBv5 +3/Z64IxPHYjGL4bZYO6odT0uYDtO1fONf7RiQ/Qw5R5djooXK63LaH7nYXyK +7UMroeJ+x71adtE54G5xn0szc0HmFEXDJusCdEzZf5574oKBx34tlPrngtz/ +ccXD+31l0uxciNxkJeoLdcXqTMc/Cj7lgqM4ZGCfshuaJMiSL7DzwNVQk1hR +4Yb/sAI3rDfIhw1nzsV3b3XH9InLKUMt+WAaattpJHJH9bw2QWkAB0I7wtKb +j/2AIwXbmuqlHOi8PBAiUaehaq0iO6C6AKZ/XpyzuEPDIw+8dpR4FkKwUZ0y +l6Cjp2BP3/3JQpCYcmxuTNBxhN3jG1RdBC1Vn9/MZO3AiqZ3dfcZxeDnYoD2 +az2Qnz67LHSuGNZEZLaad3lgDKun0LWpBNS/Cm8i9hBYUKOjwA4ioYp6KnFi +H4Gjlu0R1SEkWJ3KoXL8CeTVUVU6WSQwJhqfC4MI1BOtkU1GkJDxYkYaHE5g +GaMuNiCRhPmK5O2JKQR6TQ2KHTgkiOw5/TV1BHLKN68z/p2EsBNVl2gNBP5t +N8Zx6yFhtuFW6FgjgXtD/JD1iASKvnDO8jaBIt0w6rU+EnYs19Vp7yLw+nHZ +pMUwCW0DNSH9zwk8NHpT5j5HAn1li1mskMCI1tLFIwskCN35s5pDBJruvGKX +KyNhmvcxa/+fBEoaVvkPKnDB7Mrm+tEPBN4tdiIiVbjQJnKOZX8ikD5ap1mg +ygW62m6wmCCw5sVBXd5qLhzMPNEXM7O0l/T6maIuF6a7Mrga8wRWWtSmma3j +QupCcTBvgUDvhJcR3gZcULG+tilAtuQjPJmXZMyFsgjezOIigXGP88QVJlz4 +F9r+SI4= + "]]}, + Annotation[#, "Charting`Private`Tag$9315#4"]& ], + TagBox[ + {RGBColor[0.528488, 0.470624, 0.701351], AbsoluteThickness[1.6], Opacity[ + 1.], LineBox[CompressedData[" +1:eJwlknk41fsWh0WZTiqzEAkdQ9joknGtvX/fMp2kZGpSSho4ZYgSKU2EbpEM +J0lHKYTKEIUoc2rbbLZhszOTBpQdnct1n7ueZz2fP9Y/7+d9lprXiR3eggIC +AkmL+7+c6W14qxFTaK2o3aS5p97Iuu2uwhk6Jx5kbKmfxRaSgLIfvBQ498FZ +q5IfZakGwU7ZHUKcZzAzsazS29oQJL/Ix892VINV7YpNVgw69L1yPPG9gwUv +DI7jEvvtsEVjnDvZ0Q+dvyul53ocgNkO08RvHVOwnmKtCD3jD2+orMyW+0J4 +zLp2X0lEJCj3lQ57bZBA2d8lxURHYkDG1zNbhJJGrdj9AQGF8RBvuOWlo4sC +bp3zM4wTTYbOZNrryVVrMHmram2dXhrEZEZ8EFytho/4hj9Oh2aA/K2B6IQ0 +dbT3VBp94psJV3faWbNmNNHY7MyHzTZZEGiW4dkQqYWJukF9JyKygXydC/1z +QAeZl2QDnTOewAXL7QcUN+lhkpzUPONYAZjnpRSeqzRAB/MCGs/8Gfj+nDxf +L2GIr14UfddYUgizuqt69VyMcJ/7xvIw4WKwzMm9d/u2MQafMdV1UnkBk1L2 ++12rN2KT8YJ6s14ZDMbudw0QMcGXBSUOnTGvwO5riN2QiSlGK/bTdg1VwMRB +0cDCiE04XnjjRd3714s+5QWvVpuhi/p0sbt1NUg1r79e8NUc2bmKzdP5b0A5 +Kt/JxMQSoyvYRUyvGkjWNVsl7WOFIj8KLjWp1EGjIv1f0zetscrvSXjbP/Vg +rlx9w6AdMOzshmp56yZYIXQ/6EAkoo2G1Zk3ac2gckHV0mM9HV1P3qhbZceE +vEDRdVwtOuKTlm3u25hgfXhS5IAuHWu+UTN/uzBhr8Ob1iM0Or5eduK5jRcT +7sj6HD9tTseYvzSjq84yYXV2XmqSIx1tK2aTL+YzQabVapYdTMfvjhlBxxVb +QExzT/GOOjo+sm8+ZrvQAsdWg31OAx2NUfuVrTALGiXW9Qq9o2NFjdcGRwkW +xM6MLCti0rH2n2tXjyixYEV9oIt8Fx3drq1b6DZlgdTxmO/dE3TscF7De+vP +AuWnZUbeUgzEvYEPO8dYEPYgrbZchoE5Rvcr4yZZwE05v0tOnoHFO7Yut51l +wd3ILZF1Sgx0V8QjH0RbYe1OVou2JgNfVUva6Wi1giZ/7OQXUwbq2ofOrD7S +CvpWq/ND9jJQ02WST/vcCs/Vj/4S3L94j1ziEzrTCpvES22uezEw7dGTrncL +rcDocOdl+jAwWmi/XJxUG7j6J0uy/BkodteRE7apDSIeyAdtuMJAhUCFpTpX +2oApIWf2MY+BZUbKBx202eDy3fuy71MGiiTrdHUbs6Grq6iF/5yBSlIb50Os +2TCY5XJsRSkD+wWtilqd2fCTnviXxRsGel681agUwQa1YJn5xA4GemzRWivC +YUNAr9QbewEKV44c2q1xqx3qa/eUZwtS+PxFg3JCejuo5D8sEV9GId1nOmZl +Tjs0RpjnNopRqLaQxDesbod1al6J9tIUhng2lK2dbIeWg0997NdTmOKbv7Vm +ewfQxrYtt/+Dwji6ajSlyoErLSnC2Y4UerdTes82cKCndEBAfDuFX0K1S4zN +ORB1LeRHgwuFDTC346QLB3i66b12nhQq0iTK2bEcuPHnlwK7AAp9Smw0Ly9w +4Ot0rItd8iJv1QeG00wn9HAyXNNSKfzEMji1WbgLGsuL3SbvUCjzI2eXi1wX +ZF7leaRkUHiZHfao1qQLdilt3DeWTeGvkMHk2dNdUMPoPhxdvsjvV/x4VrAb +nv3+zYdbSeGTpdfD6mW64d7yZUcNqyk0NHmZ+GJ9N4S26x/vrKWQH/Ilft6+ +G2jHIk9oMykU1Ma1tMRu+Oum9umG/kVffjfUs2g9EBVsfWbNEIV7U08zm0gP +BO92DvUfoZBR0q+o5NEDTprhYasnFvt/kD9kGdkDwqXM80d/UDhxK6HtbnsP ++PNCosVECapNyPHvRHFhX03stb3iBGvLWPymdC78kZ0R83Q5wfrhqXDjEi6s +D2qK85AkmPA6+GzBMBd6RFTjHysS1Llo/jLSthdsDGpT7fQI5knfr81R6AN3 +YdudTAOC9gnl9k4mfXCM2yDhZkRQdJQTtH1nH1yPaT5/yJSgiaXzXMDNPmgf +aTscQScY32npYCnKg9EK17XChOBuWYO6vxV4MJfI6YzdQnAu8aws0ebBGtLz +R6oDQQOFX6f+5cCDQ/cGjIpcCGYJ7LH4LZ4HwSHeExbuBEnvxc4jmTyIchx5 +UL2L4E0Vy/cSJTzI/WdcgelJsEyn/p4JlwfT7lPz40cJjgU/9LDV+wiRkkua +1p4j6DtXqyrY9xFujUZeyjpP0C29MlyT/xEeVi611r9IcF5aNe/tyn5o9BN9 +ahFFEEOLFWIY/SDZuDLJNZ7gr3TxoO68fliXcdOJe4vg9tIeoYimfth4Wlr8 +UBJBcaWZqJbRfnBfLx/uf4fgHRf2toeaA3AvUuVg7EOC2ccF2TqPB+CZxz1l +6ceLPm/H1O57NwBvaevaU3II/ueS29U73wZgtFfTLquA4F7bhLQQy0GYK8oS +1H9OUGZq3zLzQ4OwPE77VWERQQWxre+d4gbBwELPoLqMoJ9DJ+kZGASUyh+1 +LScoa14uGiU5BDvGaPc/VBIsrG/T4+MQBCdtlOW+JVjFEqYVPRiCqD+L3x+s +IygUaLR0d/cQpG7eFDXeQJAhHPQ5UHoYKqYtfvHfE7ycn678M2YYMt6VeDm3 +EBw4uWPsQv0wXHpg3JjXSjBjasWsvugIHD6XbyjeTlBYRU7dzWEE7Nx0U7w5 +i3xHK8IPxI/ABlqWQFUXwVN259bUc0dghZj6EWUuwVnncYk1+qPQVqZo2vqR +YGkDrTCMNwolCbfv6g8SDDDrfOhHxiDVV0r42jDBDk4zzezpGIRtvu43NErQ +9KLO1mStcfBUEWfjp0V/gauzWbnjwOBftrzzmWDYVGKVEP0TaDCXZPK/Eswv +k0r999gnEHkc/pvzFMHHNeqiP3InYPzCbEDed4KWn7hVRxI/Q/OuU11ifIIF +o2YSboVfoMB4ku49u/jPZudInuw3iF/u9/j1L4JXrv29MKQxCaeGRlcpzxN0 +1L963UZuGqR3V6Q0LxAU+P/gfwHUnF5Z + "]]}, + Annotation[#, "Charting`Private`Tag$9315#5"]& ]}, {}, {}}, + AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], + Axes->{True, True}, + AxesLabel->{None, None}, + AxesOrigin->{0, 0}, + DisplayFunction->Identity, + Frame->{{False, False}, {False, False}}, + FrameLabel->{{None, None}, {None, None}}, + FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}}, + GridLines->{None, None}, + GridLinesStyle->Directive[ + GrayLevel[0.5, 0.4]], + ImagePadding->All, + Method->{ + "DefaultBoundaryStyle" -> Automatic, "DefaultMeshStyle" -> + AbsolutePointSize[6], "ScalingFunctions" -> None, + "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& ), "CopiedValueFunction" -> ({ + (Part[{{Identity, Identity}, {Identity, Identity}}, 1, 2][#]& )[ + Part[#, 1]], + (Part[{{Identity, Identity}, {Identity, Identity}}, 2, 2][#]& )[ + Part[#, 2]]}& )}}, + PlotRange->{{0., 59.99999877551021}, {0, 2}}, + PlotRangeClipping->True, + PlotRangePadding->{{ + Scaled[0.02], + Scaled[0.02]}, {0, 0}}, + Ticks->{Automatic, Automatic}]], "Output", + CellChangeTimes->{ + 3.807523177588703*^9, {3.80752512169022*^9, 3.8075251642702694`*^9}, + 3.807603255925602*^9, 3.807603328810252*^9, 3.8076034005567513`*^9, + 3.8076035145975842`*^9, {3.8076035799873004`*^9, 3.8076036240307913`*^9}, + 3.807603656270948*^9, 3.807604162868746*^9, 3.807604681600789*^9, + 3.8076048267867975`*^9, 3.8079017784209805`*^9, 3.8079018311753244`*^9, + 3.8096917047852373`*^9, 3.80969181676894*^9, 3.809691936874175*^9, + 3.809692840494209*^9, 3.8100079040995216`*^9, 3.8108798598780622`*^9, + 3.8108799385605793`*^9, {3.8121985563817844`*^9, 3.812198569311822*^9}, + 3.812202829397973*^9, 3.812286266814554*^9, 3.8126319962334967`*^9, + 3.8128095885867305`*^9, 3.812809627235176*^9, 3.812810889833084*^9, { + 3.813390388057522*^9, 3.813390413274617*^9}, 3.814000355926431*^9, { + 3.8140004257469845`*^9, 3.814000442076556*^9}, {3.8140006090679812`*^9, + 3.8140006357918963`*^9}, 3.814000783730192*^9, 3.8140011396804695`*^9, + 3.8140013488519573`*^9, 3.8140013871913586`*^9, 3.8140014314892874`*^9, + 3.8140015029446115`*^9, {3.8140015483265533`*^9, 3.8140015682260847`*^9}, + 3.814001738890541*^9, 3.81400177863371*^9, {3.8140018255792265`*^9, + 3.8140018343271513`*^9}, 3.8140018905263987`*^9, 3.814001928566802*^9, + 3.8140021246598644`*^9, 3.8140021865420837`*^9, 3.814002514921355*^9}, + ExpressionUUID -> "227cda6f-9500-4f63-870d-1fbdfedd7712"] +}, Open ]] +}, Open ]] +}, +WindowSize->{991, 721}, +WindowMargins->{{240, Automatic}, {43, Automatic}}, +FrontEndVersion->"11.0 for Microsoft Windows (64-bit) (September 21, 2016)", +StyleDefinitions->"Default.nb", +ExpressionUUID -> "02453db1-2cda-4983-b9e6-cc376752ecc3" +] +(* End of Notebook Content *) + +(* Internal cache information *) +(*CellTagsOutline +CellTagsIndex->{} +*) +(*CellTagsIndex +CellTagsIndex->{} +*) +(*NotebookFileOutline +Notebook[{ +Cell[CellGroupData[{ +Cell[580, 22, 239, 3, 70, "Section"], +Cell[822, 27, 298, 5, 49, "Text"], +Cell[1123, 34, 445, 7, 30, "Input"], +Cell[1571, 43, 159, 3, 30, "Text"], +Cell[1733, 48, 638, 21, 57, "Input"], +Cell[2374, 71, 712, 15, 30, "Input"], +Cell[3089, 88, 625, 13, 54, "Input"], +Cell[3717, 103, 1314, 37, 80, "Input"], +Cell[5034, 142, 412, 10, 59, "Input"], +Cell[5449, 154, 333, 9, 49, "Input"], +Cell[5785, 165, 181, 4, 30, "Text"], +Cell[5969, 171, 376, 11, 53, "Input"], +Cell[6348, 184, 485, 10, 49, "Input"], +Cell[6836, 196, 109, 1, 30, "Text"], +Cell[6948, 199, 534, 11, 49, "Input"], +Cell[7485, 212, 497, 13, 34, "Input"], +Cell[CellGroupData[{ +Cell[8007, 229, 257, 6, 30, "Input"], +Cell[8267, 237, 1340, 19, 30, "Output"] +}, Open ]], +Cell[9622, 259, 286, 6, 30, "Input"], +Cell[9911, 267, 697, 16, 107, "Input"], +Cell[10611, 285, 1952, 56, 259, "Input"], +Cell[CellGroupData[{ +Cell[12588, 345, 227, 5, 30, "Input"], +Cell[12818, 352, 195, 3, 30, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[13050, 360, 119, 2, 30, InheritFromParent], +Cell[13172, 364, 193, 3, 30, "Output"] +}, Open ]], +Cell[13380, 370, 196, 4, 30, "Input"], +Cell[CellGroupData[{ +Cell[13601, 378, 89, 1, 30, "Input"], +Cell[13693, 381, 482, 11, 49, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[14212, 397, 346, 7, 30, "Input"], +Cell[14561, 406, 2577, 56, 229, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[17175, 467, 300, 7, 30, "Input"], +Cell[17478, 476, 4381, 84, 236, "Output"] +}, Open ]], +Cell[21874, 563, 137, 1, 30, "Text"], +Cell[CellGroupData[{ +Cell[22036, 568, 601, 14, 30, "Input"], +Cell[22640, 584, 8996, 162, 253, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[31673, 751, 590, 12, 30, "Input"], +Cell[32266, 765, 3848, 74, 253, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[36151, 844, 494, 12, 30, "Input"], +Cell[36648, 858, 5825, 106, 240, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[42510, 969, 690, 14, 30, "Input"], +Cell[43203, 985, 5716, 104, 253, "Output"] +}, Open ]], +Cell[CellGroupData[{ +Cell[48956, 1094, 982, 20, 30, "Input"], +Cell[49941, 1116, 16888, 296, 253, "Output"] +}, Open ]] +}, Open ]] +} +] +*) + diff --git a/FuelCellLib/Documentation/References/FuelCellModelling01339484.pdf b/FuelCellLib/Documentation/References/FuelCellModelling01339484.pdf new file mode 100644 index 0000000..ece8c79 Binary files /dev/null and b/FuelCellLib/Documentation/References/FuelCellModelling01339484.pdf differ diff --git a/FuelCellLib/Documentation/References/FuelCellModelling1-s2.0-S1474667016396756-main.pdf b/FuelCellLib/Documentation/References/FuelCellModelling1-s2.0-S1474667016396756-main.pdf new file mode 100644 index 0000000..4440c27 Binary files /dev/null and b/FuelCellLib/Documentation/References/FuelCellModelling1-s2.0-S1474667016396756-main.pdf differ diff --git a/FuelCellLib/Documentation/References/Simulation_models_of_fuel_cell_systems.pdf b/FuelCellLib/Documentation/References/Simulation_models_of_fuel_cell_systems.pdf new file mode 100644 index 0000000..a1d4817 Binary files /dev/null and b/FuelCellLib/Documentation/References/Simulation_models_of_fuel_cell_systems.pdf differ diff --git a/FuelCellLib/Examples/ElectricAircraftMissionADFC.hmf b/FuelCellLib/Examples/ElectricAircraftMissionADFC.hmf new file mode 100644 index 0000000..6aa3470 --- /dev/null +++ b/FuelCellLib/Examples/ElectricAircraftMissionADFC.hmf @@ -0,0 +1,6860 @@ + + + + + 59c07d33-554f-49d3-a163-a928823d4380 + HopsanDefaultComponentLibrary + + + 34d80e82-7ea5-442f-bf1f-31e18645de82 + HopsanInternals + + + afd1b9b5-0b66-4d17-9e90-1da59a2be242 + ActivityDiagramLibrary + + + FuelCell + FuelCell + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + diff --git a/FuelCellLib/Examples/ElectricFuelCellL1Test.hmf b/FuelCellLib/Examples/ElectricFuelCellL1Test.hmf new file mode 100644 index 0000000..0619db8 --- /dev/null +++ b/FuelCellLib/Examples/ElectricFuelCellL1Test.hmf @@ -0,0 +1,914 @@ + + + + + 59c07d33-554f-49d3-a163-a928823d4380 + HopsanDefaultComponentLibrary + + + FuelCell + FuelCell + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + horizontal + vertical + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + vertical + horizontal + vertical + + + + + + + + + + + + + + horizontal + vertical + horizontal + + + + + + + + + + + + + vertical + horizontal + + + + + + + + + + + + + + + horizontal + vertical + horizontal + vertical + + + + + + + diff --git a/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.hpp b/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.hpp new file mode 100644 index 0000000..d98b930 --- /dev/null +++ b/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.hpp @@ -0,0 +1,547 @@ +#ifndef ELECTRICFUELCELLL1_HPP_INCLUDED +#define ELECTRICFUELCELLL1_HPP_INCLUDED + +#include +#include "ComponentEssentials.h" +#include "ComponentUtilities.h" +#include "math.h" + +//! +//! @file ElectricFuelCellL1.hpp +//! @author Petter Krus +// co-author/auditor **Not yet audited by a second person** +//! @date Wed 11 Nov 2020 17:33:54 +//! @brief Level 1 (conceptual) Fuel cell model with some dynamics +//! @ingroup ElectricComponents +//! +//==This code has been autogenerated using Compgen== +//from +/*{, C:, Users, petkr14, Dropbox, HopsanComponents, FuelCellLibrary, \ +FuelCellComponents}/ElectricFuelcellL18.nb*/ + +using namespace hopsan; + +class ElectricFuelCellL1 : public ComponentQ +{ +private: + double R; + double cv; + double kmFC; + double nstack; + double T; + double Tref; + double A; + double l; + double Ph2; + double Po2; + double P0; + double Faraday; + double dS; + double dG; + double B; + double Rc; + double Ch2; + double ksi1; + double ksi3; + double ksi4; + double psi; + double Jmax; + double Jn; + double MH2; + double cA; + double thaucon; + double timeComp; + double e; + Port *mpPfc; + Port *mpPp1; + double delayParts1[9]; + double delayParts2[9]; + double delayParts3[9]; + double delayParts4[9]; + double delayParts5[9]; + Matrix jacobianMatrix; + Vec systemEquations; + Matrix delayedPart; + int i; + int iter; + int mNoiter; + double jsyseqnweight[4]; + int order[5]; + int mNstep; + //Port Pfc variable + double ufc; + double ifc; + double cfc; + double Zcfc; + //Port Pp1 variable + double pp1; + double qmp1; + double Tp1; + double dEp1; + double cp1; + double Zcp1; +//==This code has been autogenerated using Compgen== + //inputVariables + double thetaFcRef; + //outputVariables + double mFC; + double unernst; + double uohmic; + double uact; + double ucon; + double ufc0; + double ufcr; + double ufc1; + double ifc0; + double etaFC; + double Powfc; + double rhoM; + double WH2; + //LocalExpressions variables + double cp; + double Co2; + double ksi2; + double Rohmic; + //Expressions variables + //Port Pfc pointer + double *mpP_ufc; + double *mpP_ifc; + double *mpP_cfc; + double *mpP_Zcfc; + //Port Pp1 pointer + double *mpP_pp1; + double *mpP_qmp1; + double *mpP_Tp1; + double *mpP_dEp1; + double *mpP_cp1; + double *mpP_Zcp1; + //Delay declarations +//==This code has been autogenerated using Compgen== + //inputVariables pointers + double *mpthetaFcRef; + //inputParameters pointers + double *mpR; + double *mpcv; + double *mpkmFC; + double *mpnstack; + double *mpT; + double *mpTref; + double *mpA; + double *mpl; + double *mpPh2; + double *mpPo2; + double *mpP0; + double *mpFaraday; + double *mpdS; + double *mpdG; + double *mpB; + double *mpRc; + double *mpCh2; + double *mpksi1; + double *mpksi3; + double *mpksi4; + double *mppsi; + double *mpJmax; + double *mpJn; + double *mpMH2; + double *mpcA; + double *mpthaucon; + double *mptimeComp; + double *mpe; + //outputVariables pointers + double *mpmFC; + double *mpunernst; + double *mpuohmic; + double *mpuact; + double *mpucon; + double *mpufc0; + double *mpufcr; + double *mpufc1; + double *mpifc0; + double *mpetaFC; + double *mpPowfc; + double *mprhoM; + double *mpWH2; + Delay mDelayedPart10; + Delay mDelayedPart20; + Delay mDelayedPart21; + Delay mDelayedPart30; + Delay mDelayedPart31; + EquationSystemSolver *mpSolver; + +public: + static Component *Creator() + { + return new ElectricFuelCellL1(); + } + + void configure() + { +//==This code has been autogenerated using Compgen== + + mNstep=9; + jacobianMatrix.create(5,5); + systemEquations.create(5); + delayedPart.create(6,6); + mNoiter=2; + jsyseqnweight[0]=1; + jsyseqnweight[1]=0.67; + jsyseqnweight[2]=0.5; + jsyseqnweight[3]=0.5; + + + //Add ports to the component + mpPfc=addPowerPort("Pfc","NodeElectric"); + mpPp1=addPowerPort("Pp1","NodePneumatic"); + //Add inputVariables to the component + addInputVariable("thetaFcRef","Power fraction reference \ +[0,1]","",1.,&mpthetaFcRef); + + //Add inputParammeters to the component + addInputVariable("R", "Gas constant", "J/Kg K", 4124.2,&mpR); + addInputVariable("cv", "heatcoeff", "J/Kg K", 10183.,&mpcv); + addInputVariable("kmFC", "Fuel cell spec. power", "W/kg", \ +1000.,&mpkmFC); + addInputVariable("nstack", "", "", 1,&mpnstack); + addInputVariable("T", "", "K", 323,&mpT); + addInputVariable("Tref", "", "K", 298.15,&mpTref); + addInputVariable("A", "", "m2", 0.00625,&mpA); + addInputVariable("l", "", "m", 0.000025,&mpl); + addInputVariable("Ph2", "Hydrogen partial press", "atm", \ +1.476,&mpPh2); + addInputVariable("Po2", "Oxygen partial press", "atm", \ +0.2095,&mpPo2); + addInputVariable("P0", "", "atm", 1,&mpP0); + addInputVariable("Faraday", "", "", 96485.3,&mpFaraday); + addInputVariable("dS", "", "", 164.02501,&mpdS); + addInputVariable("dG", "Gibbs free energy", "", 228000.6,&mpdG); + addInputVariable("B", "", "V", 0.15,&mpB); + addInputVariable("Rc", "", "", 0.0003,&mpRc); + addInputVariable("Ch2", "", "", 0.2,&mpCh2); + addInputVariable("ksi1", "", "", -0.948,&mpksi1); + addInputVariable("ksi3", "", "", 0.0000722,&mpksi3); + addInputVariable("ksi4", "", "", \ +-0.00010640000000000001,&mpksi4); + addInputVariable("psi", "", "", 23.,&mppsi); + addInputVariable("Jmax", "Max current intensity", "A/m2", \ +6720.,&mpJmax); + addInputVariable("Jn", "", "A/m2", 220.,&mpJn); + addInputVariable("MH2", "", "kg/mol", 0.002016,&mpMH2); + addInputVariable("cA", "Capacitance", "F", 10.,&mpcA); + addInputVariable("thaucon", "", "s", 0.1,&mpthaucon); + addInputVariable("timeComp", "time compression factor.", "", \ +1.,&mptimeComp); + addInputVariable("e", "e", "", 2.71828,&mpe); + //Add outputVariables to the component + addOutputVariable("mFC","Mass of fuel cell","kg",1.,&mpmFC); + addOutputVariable("unernst","","V",1.,&mpunernst); + addOutputVariable("uohmic","","V",1,&mpuohmic); + addOutputVariable("uact","","V",1,&mpuact); + addOutputVariable("ucon","","V",1,&mpucon); + addOutputVariable("ufc0","","V",1,&mpufc0); + addOutputVariable("ufcr","","V",1,&mpufcr); + addOutputVariable("ufc1","","V",1,&mpufc1); + addOutputVariable("ifc0","","A",0.,&mpifc0); + addOutputVariable("etaFC","Fuel cell efficiency","",0.,&mpetaFC); + addOutputVariable("Powfc","","Power",0.,&mpPowfc); + addOutputVariable("rhoM","","kg/m^3",0.,&mprhoM); + addOutputVariable("WH2","","kg/s",0.,&mpWH2); + +//==This code has been autogenerated using Compgen== + //Add constantParameters + mpSolver = new EquationSystemSolver(this,5); + } + + void initialize() + { + //Read port variable pointers from nodes + //Port Pfc + mpP_ufc=getSafeNodeDataPtr(mpPfc, NodeElectric::Voltage); + mpP_ifc=getSafeNodeDataPtr(mpPfc, NodeElectric::Current); + mpP_cfc=getSafeNodeDataPtr(mpPfc, NodeElectric::WaveVariable); + mpP_Zcfc=getSafeNodeDataPtr(mpPfc, NodeElectric::CharImpedance); + //Port Pp1 + mpP_pp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::Pressure); + mpP_qmp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::MassFlow); + mpP_Tp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::Temperature); + mpP_dEp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::EnergyFlow); + mpP_cp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::WaveVariable); + mpP_Zcp1=getSafeNodeDataPtr(mpPp1, NodePneumatic::CharImpedance); + + //Read variables from nodes + //Port Pfc + ufc = (*mpP_ufc); + ifc = (*mpP_ifc); + cfc = (*mpP_cfc); + Zcfc = (*mpP_Zcfc); + //Port Pp1 + pp1 = (*mpP_pp1); + qmp1 = (*mpP_qmp1); + Tp1 = (*mpP_Tp1); + dEp1 = (*mpP_dEp1); + cp1 = (*mpP_cp1); + Zcp1 = (*mpP_Zcp1); + + //Read inputVariables from nodes + thetaFcRef = (*mpthetaFcRef); + + //Read inputParameters from nodes + R = (*mpR); + cv = (*mpcv); + kmFC = (*mpkmFC); + nstack = (*mpnstack); + T = (*mpT); + Tref = (*mpTref); + A = (*mpA); + l = (*mpl); + Ph2 = (*mpPh2); + Po2 = (*mpPo2); + P0 = (*mpP0); + Faraday = (*mpFaraday); + dS = (*mpdS); + dG = (*mpdG); + B = (*mpB); + Rc = (*mpRc); + Ch2 = (*mpCh2); + ksi1 = (*mpksi1); + ksi3 = (*mpksi3); + ksi4 = (*mpksi4); + psi = (*mppsi); + Jmax = (*mpJmax); + Jn = (*mpJn); + MH2 = (*mpMH2); + cA = (*mpcA); + thaucon = (*mpthaucon); + timeComp = (*mptimeComp); + e = (*mpe); + + //Read outputVariables from nodes + mFC = (*mpmFC); + unernst = (*mpunernst); + uohmic = (*mpuohmic); + uact = (*mpuact); + ucon = (*mpucon); + ufc0 = (*mpufc0); + ufcr = (*mpufcr); + ufc1 = (*mpufc1); + ifc0 = (*mpifc0); + etaFC = (*mpetaFC); + Powfc = (*mpPowfc); + rhoM = (*mprhoM); + WH2 = (*mpWH2); + +//==This code has been autogenerated using Compgen== + + //LocalExpressions + cp = cv + R; + Co2 = 1.968503937007874e-7*Power(e,498/T)*Po2; + ksi2 = 0.00286 + 0.0002*log(10000*A) + 0.000043*log(Ch2); + rhoM = (181.6*(1 + (3.e-6*ifc0)/A + \ +6.753150562581011e-7*Power(T,2)*Power(lowLimit(ifc0/(10000.*A),0.),2.5)))/(-0\ +.634 - (3*Power(e,(4.18*(-303 + T))/T)*ifc0)/(10000.*A) + psi); + unernst = dG/(2.*Faraday) + (dS*(T - Tref))/(2.*Faraday) + \ +(R*T*log((Ph2*Sqrt(Po2))/P0))/(2.*Faraday); + uact = lowLimit(-ksi1 - ksi2*T - ksi3*T*log(Co2) - \ +ksi4*T*log(lowLimit(ifc0,9.999999999999999e-31)),0); + ucon = (1.3*B*limit(ifc/(A*Jmax),0.,1.075))/(1 - \ +0.7480520100000002*Power(limit(ifc/(A*Jmax),0.,1.075),4)); + uohmic = (ifc*l*rhoM)/(100.*A); + Rohmic = (l*rhoM)/(100.*A); + ufcr = lowLimit(-uact - ucon + unernst - uohmic,0.); + ufc0 = lowLimit(-uact - ucon + unernst,0.); + + //Initialize delays + delayParts2[1] = (-(mTimestep*ufc0) + mTimestep*ufc1 - \ +2*thaucon*ufc1)/(mTimestep + 2*thaucon); + mDelayedPart21.initialize(mNstep,delayParts2[1]); + delayParts3[1] = (-(ifc*mTimestep) + ifc0*mTimestep - \ +2*ifc0*thaucon)/(mTimestep + 2*thaucon); + mDelayedPart31.initialize(mNstep,delayParts3[1]); + + delayedPart[1][1] = delayParts1[1]; + delayedPart[2][1] = delayParts2[1]; + delayedPart[3][1] = delayParts3[1]; + delayedPart[4][1] = delayParts4[1]; + delayedPart[5][1] = delayParts5[1]; + + simulateOneTimestep(); + + } + void simulateOneTimestep() + { + Vec stateVar(5); + Vec stateVark(5); + Vec deltaStateVar(5); + + //Read variables from nodes + //Port Pfc + cfc = (*mpP_cfc); + Zcfc = (*mpP_Zcfc); + //Port Pp1 + Tp1 = (*mpP_Tp1); + cp1 = (*mpP_cp1); + Zcp1 = (*mpP_Zcp1); + + //Read inputVariables from nodes + thetaFcRef = (*mpthetaFcRef); + + //Read inputParameters from nodes + R = (*mpR); + cv = (*mpcv); + kmFC = (*mpkmFC); + nstack = (*mpnstack); + T = (*mpT); + Tref = (*mpTref); + A = (*mpA); + l = (*mpl); + Ph2 = (*mpPh2); + Po2 = (*mpPo2); + P0 = (*mpP0); + Faraday = (*mpFaraday); + dS = (*mpdS); + dG = (*mpdG); + B = (*mpB); + Rc = (*mpRc); + Ch2 = (*mpCh2); + ksi1 = (*mpksi1); + ksi3 = (*mpksi3); + ksi4 = (*mpksi4); + psi = (*mppsi); + Jmax = (*mpJmax); + Jn = (*mpJn); + MH2 = (*mpMH2); + cA = (*mpcA); + thaucon = (*mpthaucon); + timeComp = (*mptimeComp); + e = (*mpe); + + //LocalExpressions + cp = cv + R; + Co2 = 1.968503937007874e-7*Power(e,498/T)*Po2; + ksi2 = 0.00286 + 0.0002*log(10000*A) + 0.000043*log(Ch2); + rhoM = (181.6*(1 + (3.e-6*ifc0)/A + \ +6.753150562581011e-7*Power(T,2)*Power(lowLimit(ifc0/(10000.*A),0.),2.5)))/(-0\ +.634 - (3*Power(e,(4.18*(-303 + T))/T)*ifc0)/(10000.*A) + psi); + unernst = dG/(2.*Faraday) + (dS*(T - Tref))/(2.*Faraday) + \ +(R*T*log((Ph2*Sqrt(Po2))/P0))/(2.*Faraday); + uact = lowLimit(-ksi1 - ksi2*T - ksi3*T*log(Co2) - \ +ksi4*T*log(lowLimit(ifc0,9.999999999999999e-31)),0); + ucon = (1.3*B*limit(ifc/(A*Jmax),0.,1.075))/(1 - \ +0.7480520100000002*Power(limit(ifc/(A*Jmax),0.,1.075),4)); + uohmic = (ifc*l*rhoM)/(100.*A); + Rohmic = (l*rhoM)/(100.*A); + ufcr = lowLimit(-uact - ucon + unernst - uohmic,0.); + ufc0 = lowLimit(-uact - ucon + unernst,0.); + + //Initializing variable vector for Newton-Raphson + stateVark[0] = ifc; + stateVark[1] = ufc1; + stateVark[2] = ifc0; + stateVark[3] = ufc; + stateVark[4] = pp1; + + //Iterative solution using Newton-Rapshson + for(iter=1;iter<=mNoiter;iter++) + { + //FuelCellL1 + //Differential-algebraic system of equation parts + + //Assemble differential-algebraic equations + systemEquations[0] =ifc + (ufc - nstack*ufc1)/(nstack*Rohmic); + systemEquations[1] =-((mTimestep*ufc0)/(mTimestep + 2*thaucon)) + \ +ufc1 + delayedPart[2][1]; + systemEquations[2] =ifc0 - (ifc*mTimestep)/(mTimestep + 2*thaucon) \ ++ delayedPart[3][1]; + systemEquations[3] =-cfc + ufc - ifc*Zcfc; + systemEquations[4] =-cp1 + pp1 - dEp1*Zcp1; + + //Jacobian matrix + jacobianMatrix[0][0] = 1; + jacobianMatrix[0][1] = -(1/Rohmic); + jacobianMatrix[0][2] = 0; + jacobianMatrix[0][3] = 1/(nstack*Rohmic); + jacobianMatrix[0][4] = 0; + jacobianMatrix[1][0] = 0; + jacobianMatrix[1][1] = 1; + jacobianMatrix[1][2] = 0; + jacobianMatrix[1][3] = 0; + jacobianMatrix[1][4] = 0; + jacobianMatrix[2][0] = -(mTimestep/(mTimestep + 2*thaucon)); + jacobianMatrix[2][1] = 0; + jacobianMatrix[2][2] = 1; + jacobianMatrix[2][3] = 0; + jacobianMatrix[2][4] = 0; + jacobianMatrix[3][0] = -Zcfc; + jacobianMatrix[3][1] = 0; + jacobianMatrix[3][2] = 0; + jacobianMatrix[3][3] = 1; + jacobianMatrix[3][4] = 0; + jacobianMatrix[4][0] = 0; + jacobianMatrix[4][1] = 0; + jacobianMatrix[4][2] = 0; + jacobianMatrix[4][3] = 0; + jacobianMatrix[4][4] = 1; +//==This code has been autogenerated using Compgen== + + //Solving equation using LU-faktorisation + mpSolver->solve(jacobianMatrix, systemEquations, stateVark, iter); + ifc=stateVark[0]; + ufc1=stateVark[1]; + ifc0=stateVark[2]; + ufc=stateVark[3]; + pp1=stateVark[4]; + //Expressions + etaFC = ufc/(nstack*unernst); + Powfc = ifc*ufc; + WH2 = (ifc*MH2*nstack)/(2.*Faraday); + qmp1 = -(ifc*MH2*nstack)/(2.*Faraday); + dEp1 = cp*qmp1*Tp1; + mFC = (A*Jmax*nstack*unernst)/kmFC; + } + + //Calculate the delayed parts + delayParts2[1] = (-(mTimestep*ufc0) + mTimestep*ufc1 - \ +2*thaucon*ufc1)/(mTimestep + 2*thaucon); + delayParts3[1] = (-(ifc*mTimestep) + ifc0*mTimestep - \ +2*ifc0*thaucon)/(mTimestep + 2*thaucon); + + delayedPart[1][1] = delayParts1[1]; + delayedPart[2][1] = delayParts2[1]; + delayedPart[3][1] = delayParts3[1]; + delayedPart[4][1] = delayParts4[1]; + delayedPart[5][1] = delayParts5[1]; + + //Write new values to nodes + //Port Pfc + (*mpP_ufc)=ufc; + (*mpP_ifc)=ifc; + //Port Pp1 + (*mpP_pp1)=pp1; + (*mpP_qmp1)=qmp1; + (*mpP_dEp1)=dEp1; + //outputVariables + (*mpmFC)=mFC; + (*mpunernst)=unernst; + (*mpuohmic)=uohmic; + (*mpuact)=uact; + (*mpucon)=ucon; + (*mpufc0)=ufc0; + (*mpufcr)=ufcr; + (*mpufc1)=ufc1; + (*mpifc0)=ifc0; + (*mpetaFC)=etaFC; + (*mpPowfc)=Powfc; + (*mprhoM)=rhoM; + (*mpWH2)=WH2; + + //Update the delayed variabels + mDelayedPart21.update(delayParts2[1]); + mDelayedPart31.update(delayParts3[1]); + + } + void deconfigure() + { + delete mpSolver; + } +}; +#endif // ELECTRICFUELCELLL1_HPP_INCLUDED diff --git a/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.xml b/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.xml new file mode 100644 index 0000000..1e6d94d --- /dev/null +++ b/FuelCellLib/FuelCellComponents/ElectricFuelCellL1.xml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/FuelCellLib/FuelCellComponents/ElectricFuelcell.svg b/FuelCellLib/FuelCellComponents/ElectricFuelcell.svg new file mode 100644 index 0000000..d1a4256 --- /dev/null +++ b/FuelCellLib/FuelCellComponents/ElectricFuelcell.svg @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + diff --git a/FuelCellLib/FuelCellComponents/ElectricFuelcellL1.nb b/FuelCellLib/FuelCellComponents/ElectricFuelcellL1.nb new file mode 100644 index 0000000..3714513 --- /dev/null +++ b/FuelCellLib/FuelCellComponents/ElectricFuelcellL1.nb @@ -0,0 +1,1006 @@ +(* Content-type: application/vnd.wolfram.mathematica *) + +(*** Wolfram Notebook File ***) +(* http://www.wolfram.com/nb *) + +(* CreatedBy='Mathematica 8.0' *) + +(*CacheID: 234*) +(* Internal cache information: +NotebookFileLineBreakTest +NotebookFileLineBreakTest +NotebookDataPosition[ 157, 7] +NotebookDataLength[ 49598, 998] +NotebookOptionsPosition[ 48007, 950] +NotebookOutlinePosition[ 48684, 973] +CellTagsIndexPosition[ 48641, 970] +WindowFrame->Normal*) + +(* Beginning of Notebook Content *) +Notebook[{ + +Cell[CellGroupData[{ +Cell["ElectricFuelCellL1", "Title", + CellChangeTimes->{{3.520873834546875*^9, 3.520873840984375*^9}, { + 3.520880951484375*^9, 3.520880952703125*^9}, 3.5353435216307597`*^9, { + 3.8139995919011564`*^9, 3.8139995974917917`*^9}}, + ExpressionUUID -> "57b21790-662b-4ee4-8918-fd00c687c174"], + +Cell["\<\ +This is a dynamic model of a fuel cell. The model is based on basic models in \ +literature. It is a Level 1 model. I.e it is useful to represent a fuel cell \ +in system. It can be parameterized to yield adequate accuracy to represent a \ +fuel cell in a system, particularly for conceptual design. The model contains \ +some dynamics. + +References + +1. Radmanesh, H., Heidari Yazdi, S. S., Gharehpetian, G. B. & Fathi, S. H. \ +Modelling and simulation of fuel cell dynamics for electrical energy usage of \ +Hercules airplanes. Sci. World J. 2014, (2014). +2. Thanapalan, K. K. T., Williams, J. G., Liu, G. P. & Rees, D. Modelling of \ +a Pem Fuel Cell System. IFAC Proceedings Volumes 41, (IFAC, 2008). +3. Boccaletti, C., Duni, G., Fabbri, G. & Santini, E. Simulation models of \ +fuel cell systems. Proc. ICEM, Electr. Mach. Chania, Greece 6 (2006). \ +doi:10.1111/j.1743-6109.2008.01122.x.Endothelial\ +\>", "Text", + CellChangeTimes->{{3.8139996015276814`*^9, 3.8139999157836046`*^9}}], + +Cell[CellGroupData[{ + +Cell[BoxData[ + RowBox[{"<<", "C:\\\\Hopsan\\Compgen\\CompgenNG.mx"}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.525533906765625*^9, 3.525533914734375*^9}, + 3.577601924150117*^9, 3.753532820170209*^9, 3.753532868377143*^9, + 3.762728078322752*^9}, + ExpressionUUID -> "fb626f91-feab-4a07-b722-dbbcc151c4cc"], + +Cell[BoxData[ + RowBox[{"path", "=", + RowBox[{"ToFileName", "[", + RowBox[{"{", + RowBox[{ + "\"\\"", ",", "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\"", ",", + "\"\\"", ",", "\"\\""}], "}"}], "]"}]}]], "Input", + CellGroupingRules->{"GroupTogetherGrouping", 10000.}, + CellChangeTimes->{{3.754985113560959*^9, 3.754985114033472*^9}, { + 3.757063485852047*^9, 3.757063485995899*^9}, 3.76272807832475*^9, { + 3.7747826878685503`*^9, 3.774782689771587*^9}, {3.774797375685176*^9, + 3.7747973875893726`*^9}, {3.7760688172187753`*^9, + 3.7760688264662404`*^9}, {3.7760688832017593`*^9, + 3.7760688836492944`*^9}, {3.7846317812093024`*^9, 3.784631800055241*^9}, { + 3.790939336655615*^9, 3.790939344120914*^9}, {3.7994934461032467`*^9, + 3.7994934538013234`*^9}, {3.79974100026252*^9, 3.799741026886066*^9}, + 3.812283771905965*^9, {3.812283878750459*^9, 3.812283970057192*^9}, + 3.812433433933036*^9, 3.812434085221577*^9, {3.8124344329826465`*^9, + 3.812434438238638*^9}, {3.8124370537370176`*^9, 3.812437056984214*^9}, { + 3.8124371450929265`*^9, 3.812437172519957*^9}}, + ExpressionUUID -> "87099fba-26b4-4a14-8efc-4913b3525ac8"] +}, Open ]], + +Cell[BoxData["\<\"C:\\\\Users\\\\petkr14\\\\Dropbox\\\\HopsanComponents\\\\\ +AeroComponents\\\\Aero\\\\\"\>"], "Output", + CellChangeTimes->{ + 3.812437062071355*^9, 3.8124371869143744`*^9, 3.8124446205953465`*^9, + 3.812445622220993*^9, 3.8124458763042235`*^9, 3.812446015183985*^9, + 3.812446089889885*^9, 3.8124462504045706`*^9, 3.812446471667842*^9, + 3.812446603080182*^9, 3.812446645072215*^9, 3.8124492998011446`*^9, + 3.8124493663940754`*^9, 3.8124504175374737`*^9, 3.8124505279089117`*^9, + 3.8124507362629805`*^9, 3.8124508129886093`*^9, 3.81245193203526*^9, + 3.8124521938361197`*^9, 3.812452275295189*^9, 3.8124523983292313`*^9, + 3.8128044394133687`*^9, 3.8128045773483257`*^9, 3.8128048063658524`*^9, + 3.8128055603855534`*^9, 3.8128056953342667`*^9, 3.8128058013773336`*^9, + 3.8128059917785306`*^9, 3.81280624244522*^9, 3.812806299114996*^9, + 3.8128080652806826`*^9, 3.812808188696411*^9, 3.8128082793498816`*^9, { + 3.812808323063326*^9, 3.812808348340244*^9}, 3.8128087515385895`*^9, + 3.8128092757390594`*^9, 3.8133195244119005`*^9, 3.813321931894185*^9, + 3.813321967418949*^9, 3.813322802081803*^9, 3.8133248619321733`*^9, + 3.813325079940005*^9, {3.8133256344623823`*^9, 3.8133256474776974`*^9}, + 3.8133272857414637`*^9, 3.8133274608995295`*^9, 3.8133893463183327`*^9, + 3.8133895038131943`*^9, 3.813389590775037*^9, 3.813389714102804*^9, + 3.813390947998685*^9, 3.813391082268714*^9, 3.8133911885791993`*^9, + 3.8133930009292526`*^9, 3.813393195860009*^9, 3.8133935691586657`*^9, + 3.8133962016903963`*^9, 3.813396486922597*^9, 3.8133966975192637`*^9, + 3.8133967847077136`*^9, 3.8133969573110533`*^9, 3.8133971055099583`*^9, + 3.8133978151946864`*^9, 3.813398834768599*^9, 3.813399335678241*^9, + 3.8133994202058744`*^9, 3.8133998414318485`*^9, 3.8134001477980976`*^9, + 3.813491389643916*^9, 3.813495100083356*^9, 3.8134952091770253`*^9, + 3.8134952991874313`*^9, 3.8134954049455004`*^9, 3.813495497123536*^9, + 3.8134956973980303`*^9, 3.8134958555177426`*^9, 3.8134959526882725`*^9, + 3.813668274527954*^9, 3.813668419909424*^9, 3.813668486810704*^9, + 3.8136685493518295`*^9, 3.8136686546922407`*^9, 3.8136703382998457`*^9, + 3.8136724327106695`*^9, 3.813672542437233*^9}, + ExpressionUUID -> "39246cf4-dbd6-45be-8b20-65b0c8b0d003"], + +Cell[BoxData[ + RowBox[{"Off", "[", + RowBox[{"General", "::", "\"\\""}], "]"}]], "Input", + PageWidth:>WindowWidth, + ExpressionUUID -> "652a0152-5a14-4b79-b70d-d9fa36510144"], + +Cell[BoxData[{ + RowBox[{ + RowBox[{"domain", "=", "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"displayName", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{ + "brief", "=", + "\"\\""}], + ";"}], "\n", + RowBox[{ + RowBox[{"componentType", "=", "\"\\""}], ";"}], "\n", + RowBox[{ + RowBox[{"author", "=", "\"\\>\""}], + ";"}], "\n", + RowBox[{ + RowBox[{ + "affiliation", " ", "=", " ", + "\"\\""}], ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"SetFilenames", "[", + RowBox[{"path", ",", "domain", ",", "displayName"}], "]"}], + ";"}], "\[IndentingNewLine]", + RowBox[{ + RowBox[{"ResetComponentVariables", "[", "]"}], ";"}]}], "Input", + CellChangeTimes->{{3.520880152296875*^9, 3.520880230078125*^9}, + 3.520932125875*^9, 3.520932753984375*^9, {3.52093324790625*^9, + 3.520933251453125*^9}, {3.521775289609375*^9, 3.521775289921875*^9}, { + 3.52249560790625*^9, 3.522495611953125*^9}, {3.5353435506144285`*^9, + 3.5353435625103617`*^9}, {3.538982066538947*^9, 3.5389820811170716`*^9}, { + 3.538982378538947*^9, 3.538982399913947*^9}, {3.540095811916009*^9, + 3.5400958134316144`*^9}, {3.5400958446187153`*^9, + 3.5400958611341286`*^9}, {3.7994929462982273`*^9, 3.79949294812035*^9}, + 3.799493326163699*^9, {3.7997722672221565`*^9, 3.799772286280518*^9}, { + 3.7997723174983525`*^9, 3.799772319009794*^9}, {3.8000104740765705`*^9, + 3.8000105130094523`*^9}, 3.8000732267354856`*^9, {3.8124334857733374`*^9, + 3.8124334933629923`*^9}}, + ExpressionUUID -> "aa43e10d-c05d-43e3-a087-d1ec17470b5d"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputVariables", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "thetaFcRef", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], + "\[IndentingNewLine]", "}"}]}], ";"}]], "Input", + CellChangeTimes->{{3.446223460296875*^9, 3.44622356096875*^9}, { + 3.4462236030625*^9, 3.446223670484375*^9}, {3.446223703640625*^9, + 3.4462238429375*^9}, {3.4462265591875*^9, 3.44622670078125*^9}, { + 3.4463566622546744`*^9, 3.4463566920669837`*^9}, 3.4463567240041475`*^9, { + 3.446357070530962*^9, 3.446357073718421*^9}, 3.446379656956832*^9, { + 3.4464008796202064`*^9, 3.44640090863546*^9}, {3.446452519793661*^9, + 3.446452619136775*^9}, {3.446460814522464*^9, 3.446460921949324*^9}, { + 3.446460972761937*^9, 3.4464609779947715`*^9}, {3.446461042663227*^9, + 3.4464610541442213`*^9}, {3.446522488390625*^9, 3.446522516109375*^9}, { + 3.446522610078125*^9, 3.446522622265625*^9}, {3.44652284971875*^9, + 3.446522850484375*^9}, 3.446524524569768*^9, {3.44657946146875*^9, + 3.44657946196875*^9}, {3.446637579390625*^9, 3.446637622890625*^9}, { + 3.44663767678125*^9, 3.446637762140625*^9}, {3.446741156203125*^9, + 3.446741194671875*^9}, 3.446744375703125*^9, {3.4468319421875*^9, + 3.446831994875*^9}, {3.447609315015625*^9, 3.447609356953125*^9}, + 3.44760944415625*^9, {3.447938433375*^9, 3.44793848459375*^9}, { + 3.447938571546875*^9, 3.4479385744375*^9}, {3.447951560046875*^9, + 3.44795160009375*^9}, {3.457505934953125*^9, 3.457505949234375*^9}, { + 3.540095890602502*^9, 3.540095891883735*^9}, {3.800013706988228*^9, + 3.8000137263942327`*^9}, {3.800082537647973*^9, 3.800082542135347*^9}, { + 3.800090224922123*^9, 3.8000902659348636`*^9}}, + ExpressionUUID -> "5248b079-d643-4e8a-986c-34efe7ba874e"], + +Cell[BoxData[ + RowBox[{ + RowBox[{"inputParameters", "=", + RowBox[{"{", "\[IndentingNewLine]", + RowBox[{ + RowBox[{"{", + RowBox[{ + "R", ",", "4124.2", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "cv", ",", "10183.", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "kmFC", ",", "1000.", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "nstack", ",", "1", ",", "double", ",", "\"\<\>\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "T", ",", "323", ",", "double", ",", "\"\\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Tref", ",", "298.15", ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"A", ",", + RowBox[{"62.5", " ", + SuperscriptBox["10", + RowBox[{"-", "4"}]]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"l", ",", + RowBox[{"25", " ", + SuperscriptBox["10", + RowBox[{"-", "6"}]]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Ph2", ",", "1.476", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Po2", ",", "0.2095", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "P0", ",", "1", ",", "double", ",", "\"\\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Faraday", ",", "96485.3", ",", "double", ",", "\"\<\>\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"dS", ",", + RowBox[{".85", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], "2", " ", "96485.3"}], ",", "double", ",", + "\"\<\>\"", ",", "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "dG", ",", "228000.6", ",", "double", ",", "\"\<\>\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "B", ",", "0.15", ",", "double", ",", "\"\\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Rc", ",", "0.0003", ",", "double", ",", "\"\<\>\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "Ch2", ",", "0.2", ",", "double", ",", "\"\<\>\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"ksi1", ",", + RowBox[{"-", ".948"}], ",", "double", ",", "\"\<\>\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"ksi3", ",", + RowBox[{"7.22", " ", + SuperscriptBox["10", + RowBox[{"-", "5"}]]}], ",", "double", ",", "\"\<\>\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"ksi4", ",", + RowBox[{ + RowBox[{"-", "1.064"}], " ", + SuperscriptBox["10", + RowBox[{"-", "4"}]]}], ",", "double", ",", "\"\<\>\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "psi", ",", "23.", ",", "double", ",", "\"\<\>\"", ",", "\"\<\>\""}], + "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"Jmax", ",", + RowBox[{"672.", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], + SuperscriptBox["10", "4"]}], ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"Jn", ",", + RowBox[{"22.", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], + SuperscriptBox["10", "4"]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"MH2", ",", + RowBox[{"2.016", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "cA", ",", "10.", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "conNum", ",", "1000.", ",", "double", ",", "\"\<1/Ohm\>\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "thaucon", ",", ".1", ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "timeComp", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"Jn", ",", + RowBox[{"22.", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]], + SuperscriptBox["10", "4"]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{"MH2", ",", + RowBox[{"2.016", " ", + SuperscriptBox["10", + RowBox[{"-", "3"}]]}], ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "cA", ",", "10.", ",", "double", ",", "\"\\"", ",", + "\"\\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "thaucon", ",", ".1", ",", "double", ",", "\"\\"", ",", + "\"\<\>\""}], "}"}], ",", "\[IndentingNewLine]", + RowBox[{"{", + RowBox[{ + "timeComp", ",", "1.", ",", "double", ",", "\"\<\>\"", ",", + "\"\