Hello Mateo
Many years have gone but this type of system is more actual than ever. Please see the link below:
https://www.mathworks.com/matlabcentral/fileexchange/59343-fuel-cell-battery-driven-electric-motor-h2-transfer
This is smoothly modelled in Simscape nowadays.
Regards Juan