Parent Directory
|
Revision Log
|
Revision Graph
updating contrib streamice repo with latest files, and separated out convergence checks; and parameterised maximum iteration counts and interface w shelfice for coupling
1 | dgoldberg | 1.2 | C $Header: /u/gcmpack/MITgcm/pkg/streamice/phi_gl_streamice.F,v 1.2 2013/06/21 19:35:44 dgoldberg Exp $ |
2 | C $Name: $ | ||
3 | |||
4 | dgoldberg | 1.1 | #include "CPP_OPTIONS.h" |
5 | |||
6 | _RL FUNCTION PHI_GL_STREAMICE (X, W) | ||
7 | |||
8 | ! This function returns a "smoothed indicator function" | ||
9 | ! that is zero when x<0, 1 when x>w/2, and continuously diff. | ||
10 | |||
11 | _RL X, W | ||
12 | _RL TMP1, PI | ||
13 | |||
14 | dgoldberg | 1.2 | IF (X.le.0.0) THEN |
15 | dgoldberg | 1.1 | PHI_GL_STREAMICE = 0.0 |
16 | dgoldberg | 1.2 | ELSEIF(X.gt.0.5*W) THEN |
17 | dgoldberg | 1.1 | PHI_GL_STREAMICE = 1.0 |
18 | ELSE | ||
19 | PI = 3.14159265358979323844D0 | ||
20 | TMP1 = COS (2*PI*X/W) | ||
21 | PHI_GL_STREAMICE = 0.5 * (1-TMP1) | ||
22 | ENDIF | ||
23 | |||
24 | RETURN | ||
25 | dgoldberg | 1.2 | END |
ViewVC Help | |
Powered by ViewVC 1.1.22 |