Nonlinear public goods game in dynamical environments | Synapse