CITE THIS NOTEBOOK: Romeo, Juliet and Rosaline love affair model by Sangdon Lee. Wolfram Community DEC 2 2022.

Description

Shakespeare’s scene:
Romeo and Juliet fall in love with each other. However, Romeo has still feeling on ex-girlfriend, Rosaline. Juliet and Rosaline do not know Romeo has still feelings for both of them and they are confused.
​https://en.wikipedia.org/wiki/Rosaline
The stock-flow diagram is shown below: R = Romeo, J = Juliet, RS = Rosaline.

Stock and flow diagram

We can classify the range of positive and negative feelings
◼
  • < - 100: dangerous level of negative feelings
  • ◼
  • within +/-100 is normal human feelings representing negative and positive feelings
  • ◼
  • 0 = neutral feeling
  • ◼
  • > +100: dangerous level o positive feelings
  • The coefficients starting with “c” indicate that they act as a damping coefficient, i.e., they dissipates or aggravates his or her feeling. These coefficients represent whether Romeo adds fuel or pour water to his feeling . Negative values of “c” dampens his or her feeling and make Romeo calm down. Positive values of “c” add fuel on his or her feeling .
    ​
    The coefficients starting with “k” indicate that they act like a spring coefficient . They make feelings oscillate forever without the coefficients starting with “c” .

    Modeling

    Romeo’s feeling toward Juliet
    
    t
    RomeoJuliet'[t]==+k1*Juliet[t]+c1*RomeoJuliet[t]+k5*RomeoRosaline[t],
    (
    1
    )
    Romeo' s feeling toward Rosaline
    
    t
    RomeoRosaline'[t]==+k2*RomeoJuliet[t]+c2*RomeoRosaline[t]+k6*Rosaline[t],
    (
    2
    )
    Juliet' s feeling toward Romeo . Juliet does not know Romeo has feelings to Rosaline
    
    t
    Juliet'[t]==+k3*RomeoJuliet[t]+c3*Juliet[t],
    (
    3
    )
    Rosaline's feeling toward Romeo. Rosaline does not know Romeo has feelings to Juliet
    
    t
    Rosaline'[t]==+k4*RomeoRosaline[t]+c4*Rosaline[t]
    (
    4
    )
    k1=FeelingsFromJulietToRomeo,k2=FeelingsFromRomeoToJuliet​​k3=FeelingsFromRomeoToJuliet,k4=FeelingsFromRomeoToRosaline​​k5=FeelingsFromRosalineToRomeo,k6=FeelingsFromRosalineToRomeo​​​​c1=FeelingsTowardHimselfWRTJuliet,c2=FeelingsTowardHimselfWRTRosaline​​c3=FeelingsTowardHerselfWRTRomeo,c4=FeelingsTowardHerselfWRTRomeo​​

    Solve the love affair model

    In[]:=
    psolRJR=ParametricNDSolve[​​{romeoJuliet'[t]==+k1*julietRomeo[t]+c1*romeoJuliet[t]+k5*romeoRosaline[t](*Romeo'sfeelingtowardJulietandRosaline*),​​romeoRosaline'[t]==+k2*romeoJuliet[t]+c2*romeoRosaline[t]+k6*rosalineRomeo[t](*Romeo'sfeelingtowardRosaline*),​​julietRomeo'[t]==+k3*romeoJuliet[t]+c3*julietRomeo[t](*Juliet'sfeelingtowardRomeo.JulietdoesnotknowRomeohasex-girlfriend,Rosaline*),​​rosalineRomeo'[t]==+k4*romeoRosaline[t]+c4*rosalineRomeo[t](*Rosaline'sfeelingtowardRomeo,RosalinedoesnotknowRomeohasagirlfriend,Juliet*),​​​​romeoJuliet[0]==r10,romeoRosaline[0]==r20,julietRomeo[0]==r30,rosalineRomeo[0]==r40},​​{romeoJuliet,romeoRosaline,julietRomeo,rosalineRomeo},​​{t,0,12*20},​​{c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40}];

    Simulation

    In[]:=
    Manipulate[​​{​​Plot[Evaluate[{​​romeoJuliet[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],romeoRosaline[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],julietRomeo[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],rosalineRomeo[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t]}/.psolRJR],​​{t,0,12*20},​​Frame->True,FrameLabel->{"Time","( Cold / Hot ) Feeling"},GridLines->Automatic,PlotRange->{All,{-200,200}},PlotLegends->Placed[{"Romeo's Feeling to Juliet","Romeo's Feeling to Rosaline","Juliet's Feeling to Romeo","Rosaline's Feeling to Romeo"},Above],ImageSize->400],​​​​(*Romeo'sfeelingtowardJulietandRosaline*)​​ParametricPlot[Evaluate[{​​romeoJuliet[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],​​romeoRosaline[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t]}/.psolRJR],​​{t,0,12*20},​​Frame->True,FrameLabel->{"Romeo's Feeling to Juliet","Romeo's Feeling to Rosaline"},GridLines->Automatic,ImageSize->250,PlotRange{{-200,200},{-200,200}}],​​​​(*Romeo'sfeelingtowardJuliet*)​​ParametricPlot[Evaluate[{​​romeoJuliet[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],​​julietRomeo[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t]}/.psolRJR],​​{t,0,12*20},​​Frame->True,FrameLabel->{"Romeo","Juliet"},GridLines->Automatic,ImageSize->250,PlotRange{{-200,200},{-200,200}}],​​​​(*Romeo'sfeelingtowardRosaline*)​​ParametricPlot[Evaluate[{​​romeoRosaline[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t],​​rosalineRomeo[c1,c2,c3,c4,k1,k2,k3,k4,k5,k6,r10,r20,r30,r40][t]}/.psolRJR],​​{t,0,12*20},​​Frame->True,FrameLabel->{"Romeo","Rosaline"},GridLines->Automatic,ImageSize->250,PlotRange{{-200,200},{-200,200}}]​​}//Row,​​​​(*Romeo'sfeelingtowardJuliet'sfeeling*)​​{{k1,-0.20,"k1: Romeo's feeling to Juliet"},-0.20,0.20,0.05},​​{{c1,-0.01,"c1: Romeo adds fuel or pour water \n to his feeling on Juliet"},-0.20,0.20,0.05},​​​​(*Romeo'sfeelingtowardRosaline'sfeeling*)​​{{k2,-0.19,"k2: Romeo's feeling to Rosaline"},-0.20,0.20,0.05},​​{{c2,+0.04,"c2: Romeo adds fuel or pour water \n to his feeling on Rosaline"},-0.20,0.20,0.05},Delimiter,​​​​(*Romeo'sfeelingbetweenJulietandRosaline*)​​{{k5,0.2,"k5: Romeo's feeling to Rosaline will also affect \n Romeo's feeling to Juliet"},-0.20,0.20,0.05},​​{{k6,0.13,"k6: Romeo's feeling to Juliet will also affect \n Romeo's feeling to Rosaline"},-0.20,0.20,0.05},Delimiter,​​​​(*Juliet'sfeelingtowardRomeo*)​​{{k3,+0.20,"k3: Juliet's feeling to Romeo'"},-0.20,0.20,0.05},​​{{c3,-0.02,"c3: Juliet adds fuel or pour water \n to her feeling on Romeo"},-0.20,0.20,0.05},Delimiter,​​​​(*Rosaline'sfeelingtowardRomeo*)​​{{k4,-0.08,"k4: Rosaline's feeling to Romeo"},-0.20,0.20,0.05},​​{{c4,+0.03,"c4: Rosaline adds fuel or pour water \n to her feeling on Romeo"},-0.20,0.20,0.05},Delimiter,​​​​(*initialfeelings*)​​{{r10,50.0,"Romeo's initial feeling to Juliet"},-100,100,5},​​{{r20,10.0,"Romeo's initial feeling to Rosaline"},-100,100,5},​​{{r30,25.0,"Juliet's initial feeling to Romeo"},-100,100,5},​​{{r40,05.0,"Rosaline's initial feeling to Romeo"},-100,100,5},SaveDefinitions->True]​​

    Observations from simulations and Improvements

    Simulations with various coefficient values show that the feelings among them are very complicated and could be easily out of control.
    Romeo should forget about his ex-girlfriend. Otherwise, things become complicated quickly.
    This model assumes that Juliet and Rosaline do not know Romeo has feelings for both of them and shows already complicated behavior. If Juliet and Rosaline know Romeo has feelings for both of them, this will show even more complicated behavior and their feelings are out of control quickly.