@@ -264,14 +264,6 @@ function claw1ez() # No arguments
264
264
error (" *** ERROR *** periodic boundary conditions require mthbc(1) and mthbc(2) BOTH be set to 2" )
265
265
end
266
266
267
- # ## ! Figure out size of work array needed
268
- # ## mwork = (mx + 2*mbc) * (2 + 4*meqn + mwaves + meqn*mwaves)
269
- # ##
270
- # ## #
271
- # ## #
272
- # ## write(6,*) 'running...'
273
- # ## write(6,*) ' '
274
- # ## #
275
267
println (" running..." )
276
268
println (" " )
277
269
@@ -294,47 +286,15 @@ function claw1ez() # No arguments
294
286
295
287
aux = (maux > 0 ) ? OffsetArray (Float64, 1 : maux, 1 - mbc: mx+ mbc) : OffsetArray (Float64, 1 : 1 ,1 : 1 )
296
288
297
- # ## #
298
- # ## # # set aux array:
299
- # ## #
300
- # ## if (maux .gt. 0) then
301
- # ## call setaux(mbc,mx,xlower,dx,maux,aux)
302
- # ## endif
303
- # ##
304
- # ## ! Allocate q
305
- # ## allocate(q(meqn, 1-mbc:mx+mbc), stat=allocate_status)
306
- # ## if (allocate_status .ne. 0) then
307
- # ## print *, '*** Error allocating q array; exiting claw1ez'
308
- # ## go to 900
309
- # ## end if
310
-
311
289
q = OffsetArray (Float64, 1 : meqn, 1 - mbc: mx+ mbc)
312
290
313
- # ## # # set initial conditions:
314
- # ## #
315
- # ## call qinit(meqn,mbc,mx,xlower,dx,q,maux,aux)
316
- # ## #
317
-
318
- # println("q before qinit call: $q")
291
+ # set initial conditions:
319
292
320
293
qinit (prob_data, meqn, mbc, mx, xlower, dx, q, maux, aux)
321
294
322
- # println("q after qinit call:")
323
- # Base.print(q)
324
-
325
295
# output initial data
326
296
out1 (meqn,mbc,mx,xlower,dx,q,t0,0 ,aux,maux,
327
297
(outaux_init_only || outaux_always) )
328
-
329
- # ##
330
- # ## ! Allocate work array
331
- # ## allocate(work(mwork), stat=allocate_status)
332
- # ## if (allocate_status .ne. 0) then
333
- # ## print *, '*** Error allocating work array; exiting claw1ez'
334
- # ## go to 900
335
- # ## end if
336
-
337
-
338
298
#
339
299
# ----------
340
300
# Main loop:
@@ -355,7 +315,6 @@ function claw1ez() # No arguments
355
315
claw1 (prob_data,meqn,mwaves,maux,mbc,mx,
356
316
q,aux,xlower,dx,tstart,tend,dtv,cflv,nv,method,mthlim,
357
317
mthbc,
358
- # work, mwork, # ???
359
318
use_fwaves,
360
319
bc1,rp1,src1,b4step1)
361
320
@@ -382,7 +341,6 @@ function claw1ez() # No arguments
382
341
383
342
end
384
343
385
-
386
344
dtv[1 ] = dtv[5 ] # use final dt as starting value on next call
387
345
388
346
# output solution at this time
@@ -401,33 +359,10 @@ function claw1ez() # No arguments
401
359
out1 (meqn,mbc,mx,xlower,dx,q,tend,iframe,
402
360
aux,maux,outaux_always)
403
361
404
- # ## write(6,601) iframe,tend
405
- # ## write(10,1010) tend,info,dtv(3),dtv(4),dtv(5),
406
- # ## & cflv(3),cflv(4),nv(2)
407
- end
408
- # ## #
409
- # ## # # formats for writing out information about this call to claw:
410
- # ## #
411
- # ## 601 format('CLAW1EZ: Frame ',i4,
412
- # ## & ' output files done at time t =',
413
- # ## & d12.4,/)
414
- # ## #
415
- # ## 1010 format('tend =',d15.4,/,
416
- # ## & 'info =',i5,/,'smallest dt =',d15.4,/,'largest dt =',
417
- # ## & d15.4,/,'last dt =',d15.4,/,'largest cfl =',
418
- # ## & d15.4,/,'last cfl =',d15.4,/,'steps taken =',i4,/)
419
- # ## #
362
+ @printf (" CLAW1EZ: Frame %4d output files done at time t = %12.4e\n " , iframe,tend)
363
+ @printf (" tend = %15.4e \n info =%5d\n smallest dt =%15.4e\n largest dt =%15.4e\n last dt =%15.4e\n largest cfl =%15.4e\n last cfl =%15.4e\n steps taken =%4d\n " ,
364
+ tend,info,dtv[3 ],dtv[4 ],dtv[5 ],cflv[3 ],cflv[4 ],nv[2 ])
420
365
366
+ end
421
367
end
422
-
423
-
424
- # ## 900 continue
425
- # ## if (allocated(q)) deallocate(q)
426
- # ## if (allocated(aux)) deallocate(aux)
427
- # ## if (allocated(work)) deallocate(work)
428
- # ## if (allocated(mthlim)) deallocate(mthlim)
429
- # ## if (allocated(tout)) deallocate(tout)
430
- # ## if (allocated(iout_q)) deallocate(iout_q)
431
- # ## if (allocated(iout_aux)) deallocate(iout_aux)
432
-
433
368
end # claw1ez
0 commit comments