[MITgcm-support] add the time dependent wind by 'zonalWindFile'

Martin Losch Martin.Losch at awi.de
Thu Nov 22 03:44:25 EST 2012

Even though your forcing is not supposed to be period, you need to set this in 'data':
periodicExternalForcing =.true.,
externForcingPeriod = "time interval between forcing field records, i.e. "timesteps" in your matlab code",
externForcingCycle = "time afte which the forcing repeats"

The model then reads a new forcing field record after externForcingPeriod until it reaches the end of externForcingCycle. You just have to make sure that your integration time is less than that. 

(With this approach, however, you will have the wind ramp up linearly between step 19 and 20. If you want an discontiuous change you need do a restart with new constant forcing.)


On Nov 21, 2012, at 7:04 PM, Victor wrote:

> Hi guys
> I am trying to setup a model with time dependent wind (not periodic), but the wind file is always not added in properly. I set 'zonalWindFile='windx.bin'' in the 'data' file. The 'windx.bin' is generated by Matlab 2012 like this:
> ___________________________________________
> tau=0.1;
> nx=160;ny=1,nz=30;
> timesteps=240;
> windx=rand(nx,ny,timesteps);
> for i=1:timsteps
>     if i<=20
>         windx(:,:,i)=zeros(nx,ny,1);
>     else
>         windx(:,:,i)=ones(nx,ny,1)*tau;
>     end
> end
> fid=fopen('windx.bin','w','b');
> fwrite(fid,windx,'real*8');
> fclose(fid);
> _______________________________________________
> The adding of constant wind has been sucessful. While for the time dependent wind it always gets zeros value for U and V. The no-zeros value of the wind seems to not be read in. I still can not find the way through after checking out the related information in manul and email support. 
> Thanks very much for the help. 
> -- 
> Best regards. 
> Shengli Chen
> Xiamen University, China
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support

More information about the MITgcm-support mailing list