Add External Force as a Function

Dear all,
I have already known that if I want to add an external force to a set of atoms, I can write a script just like this one:

#!perl

 

 

use strict;

use Getopt::Long;

use MaterialsScript qw(:all);

 

 

my \$doc = \$Documents{"test.xsd"};

Modules->Forcite->ChangeSettings([ExternalForceSet => "MySet",  ExternalForceStrength => 1 ,ExternalForceX=1.0]);

Modules->Forcite->Dynamics->Run(\$doc);

But in this script, external force is a constant, if the external force is not a constant but a funaction of time, how to deal with that?
Thanks,
Best regards,
Yours
CHENG Xu