checkerror.py

来自「Dolfin provide a high-performance linear」· Python 代码 · 共 18 行

PY
18
字号
#!/usr/bin/python## Copyright (C) 2005-2006 Anders Logg.# Licensed under the GNU LGPL Version 2.1.## Test script for checking the error of the# multi-adaptive solution. Good for testing.from os import systemfrom benchutil import *system("./dolfin-ode-reaction mcg fixed-point 1e-6 1000 5.0 parameters-bench.xml")e = check_error("solution.data", "reference_1000.data")print ""print "Error: %g" % eprint "Error should be 1.7708e-05 and take about 13.75 seconds to compute."

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?