One option is to use the resource function CombinePlots
. Will require some changes.
ktimepath1 =
Plot[{Evaluate[k[t] /. solm]}, {t, 0, 200},
PlotRange -> All,
AxesLabel -> {"t", "k"},
PlotLegends -> {"k"},
Frame -> True,
PlotStyle -> Thickness[0.01]] (* The two overlay exactly so increase thickness *)
ktimepath2 =
Plot[{Evaluate[k2[t] /. solm2]}, {t, 0, 200},
PlotRange -> All,
AxesLabel -> {"t", "k2"},
PlotLegends -> {"k2"}, Frame -> True,
FrameStyle -> Red,
PlotStyle -> Red]
ResourceFunction["CombinePlots"][ktimepath1, ktimepath2,
"AxesSides" -> "TwoY",
ImageSize -> 600]
