File size: 3,444 Bytes
5154c4e
3de3b50
5154c4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
{
  "id": "single-software-execution--cli--openfoam--task-16--ubuntu",
  "snapshot": "OpenFOAM11",
  "instruction": "Using OpenFOAM from the command line, copy `/home/user/Desktop/shockTube_base/` to `/home/user/Desktop/shock_tube/` and solve the fixed Sod shock-tube problem. Source the installed OpenFOAM environment before running OpenFOAM commands. At the start of the task, before running the case, load OpenFOAM with `source /opt/openfoam11/etc/bashrc`; the solver binaries are under `/opt/openfoam11/bin` and its platform bin directory.\n\nUse a `1 x 0.01 x 0.01 m` tube with exactly `(1000 1 1)` cells, zero-gradient end faces, empty transverse faces, and a diaphragm at `x=0.5 m`. The gas is calorically perfect with molecular weight 28.96 kg/kmol, `Cp=1004.5 J/(kg K)`, zero viscosity, and `gamma` approximately 1.4002. Set zero velocity everywhere. The left initial state is `p=100000 Pa`, `T=348.308740203735 K` (`rho=1 kg/m^3`); the right state is `p=10000 Pa`, `T=278.646992162988 K` (`rho=0.125 kg/m^3`). Run `blockMesh`, require a successful `checkMesh`, run `setFields`, and solve with `rhoCentralFoam` using `maxCo=0.2` through the exact sample time `t=0.0005 s`, retaining ASCII final `p`, `T`, and `U`. Save the outputs as `/home/user/Desktop/shock_tube/log.blockMesh`, `log.checkMesh`, `log.setFields`, and `log.rhoCentralFoam`; a failed mesh check is not acceptable. Write the final cell-centre field `C`. Define `shock_pressure` as the arithmetic mean of every final cell pressure whose centre satisfies `0.64 <= x <= 0.72 m`; this fixed interval must contain exactly 80 cells and have population standard deviation divided by its mean below 0.05. Create `/home/user/Desktop/postprocess.py` that reads the final `C` and `p`, writes all 1,000 cells to `/home/user/Desktop/pressure_profile.csv` with columns `x_m,p_pa`, and writes `/home/user/Desktop/summary.txt` as one line containing `shock_pressure` in Pa. Do not hard-code the result and do not use GUI tools.",
  "source": "https://github.com/openfoam/openfoam-dev",
  "config": [
    {
      "type": "upload_file",
      "parameters": {
        "files": [
          {
            "local_path": "task-16/init_file/shockTube_base.tar",
            "path": "/home/user/Desktop/shockTube_base.tar"
          }
        ]
      }
    },
    {
      "type": "launch",
      "parameters": {
        "command": "bash -c \"mkdir -p '/home/user/Desktop/' && tar -xf '/home/user/Desktop/shockTube_base.tar' -C '/home/user/Desktop/' && rm -f '/home/user/Desktop/shockTube_base.tar'\"",
        "shell": true
      }
    }
  ],
  "trajectory": "trajectories/",
  "related_apps": [
    "openfoam"
  ],
  "artifact_paths": [
    "/home/user/Desktop/postprocess.py",
    "/home/user/Desktop/pressure_profile.csv",
    "/home/user/Desktop/summary.txt"
  ],
  "evaluator": {
    "postconfig": [
      {
        "type": "upload_file",
        "parameters": {
          "files": [
            {
              "local_path": "task-16/eval.py",
              "path": "/home/user/Desktop/eval.py"
            }
          ]
        }
      }
    ],
    "func": "exact_match",
    "result": {
      "type": "vm_command_line",
      "command": "python3 /home/user/Desktop/eval.py",
      "shell": "true"
    },
    "expected": {
      "type": "rule",
      "rules": {
        "expected": "True\n"
      }
    }
  },
  "proxy": false,
  "fixed_ip": false,
  "possibility_of_env_change": "low"
}