{"action":"created","comment":{"url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments/56333256","id":56333256,"diff_hunk":"@@ -25,35 +26,107 @@ template class New_SuperCapacitorPostprocessor<2>;\n template class New_SuperCapacitorPostprocessorParameters<3>;\n template class New_SuperCapacitorPostprocessor<3>;\n \n-void compute_energy(std::vector<std::string> const &capacitor_state,\n-                    std::vector<double> const &time,\n+namespace internal\n+{\n+class energy_odeint\n+{\n+public:\n+  energy_odeint(std::vector<double> const &time,\n+                std::vector<double> const &power);\n+\n+  void operator()(std::vector<double> const &, std::vector<double> &dxdt,\n+                  double const current_time);\n+\n+private:\n+  std::vector<double> const time;\n+  std::vector<double> const power;\n+};\n+\n+energy_odeint::energy_odeint(std::vector<double> const &time,\n+                             std::vector<double> const &power)\n+    : time(time), power(power)\n+{\n+}\n+\n+void energy_odeint::operator()(std::vector<double> const &,\n+                               std::vector<double> &dxdt,\n+                               double const current_time)\n+{\n+  unsigned int pos = 0;\n+  for (unsigned int i = 0; i < time.size(); ++i, ++pos)\n+  {\n+    if (time[i] >= current_time)\n+      break;\n+  }\n+  if (pos == 0)\n+    dxdt[0] = power[0];\n+  else","path":"cpp/source/post_processor.cc","position":48,"original_position":48,"commit_id":"f1ad9c6a954a63897a69b85116b7156f03bada23","original_commit_id":"f1ad9c6a954a63897a69b85116b7156f03bada23","user":{"login":"dalg24","id":296978,"avatar_url":"https://avatars.githubusercontent.com/u/296978?v=3","gravatar_id":"","url":"https://api.github.com/users/dalg24","html_url":"https://github.com/dalg24","followers_url":"https://api.github.com/users/dalg24/followers","following_url":"https://api.github.com/users/dalg24/following{/other_user}","gists_url":"https://api.github.com/users/dalg24/gists{/gist_id}","starred_url":"https://api.github.com/users/dalg24/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dalg24/subscriptions","organizations_url":"https://api.github.com/users/dalg24/orgs","repos_url":"https://api.github.com/users/dalg24/repos","events_url":"https://api.github.com/users/dalg24/events{/privacy}","received_events_url":"https://api.github.com/users/dalg24/received_events","type":"User","site_admin":false},"body":"So here basically doing a linear interpolation, right?","created_at":"2016-03-16T13:36:55Z","updated_at":"2016-03-16T13:36:55Z","html_url":"https://github.com/ORNL-CEES/Cap/pull/65#discussion_r56333256","pull_request_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65","_links":{"self":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments/56333256"},"html":{"href":"https://github.com/ORNL-CEES/Cap/pull/65#discussion_r56333256"},"pull_request":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65"}}},"pull_request":{"url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65","id":62952555,"html_url":"https://github.com/ORNL-CEES/Cap/pull/65","diff_url":"https://github.com/ORNL-CEES/Cap/pull/65.diff","patch_url":"https://github.com/ORNL-CEES/Cap/pull/65.patch","issue_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/65","number":65,"state":"open","locked":false,"title":"Clean some tests.","user":{"login":"Rombur","id":368538,"avatar_url":"https://avatars.githubusercontent.com/u/368538?v=3","gravatar_id":"","url":"https://api.github.com/users/Rombur","html_url":"https://github.com/Rombur","followers_url":"https://api.github.com/users/Rombur/followers","following_url":"https://api.github.com/users/Rombur/following{/other_user}","gists_url":"https://api.github.com/users/Rombur/gists{/gist_id}","starred_url":"https://api.github.com/users/Rombur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rombur/subscriptions","organizations_url":"https://api.github.com/users/Rombur/orgs","repos_url":"https://api.github.com/users/Rombur/repos","events_url":"https://api.github.com/users/Rombur/events{/privacy}","received_events_url":"https://api.github.com/users/Rombur/received_events","type":"User","site_admin":false},"body":"I have removed the UQ test. I think that we should get ride of Tasmanian and do the UQ in python.","created_at":"2016-03-15T18:14:58Z","updated_at":"2016-03-16T13:36:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"24f6327947a3dddffe7766fe0c50982e9000e5d1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65/commits","review_comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65/comments","review_comment_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/65/comments","statuses_url":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/f1ad9c6a954a63897a69b85116b7156f03bada23","head":{"label":"Rombur:test","ref":"test","sha":"f1ad9c6a954a63897a69b85116b7156f03bada23","user":{"login":"Rombur","id":368538,"avatar_url":"https://avatars.githubusercontent.com/u/368538?v=3","gravatar_id":"","url":"https://api.github.com/users/Rombur","html_url":"https://github.com/Rombur","followers_url":"https://api.github.com/users/Rombur/followers","following_url":"https://api.github.com/users/Rombur/following{/other_user}","gists_url":"https://api.github.com/users/Rombur/gists{/gist_id}","starred_url":"https://api.github.com/users/Rombur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rombur/subscriptions","organizations_url":"https://api.github.com/users/Rombur/orgs","repos_url":"https://api.github.com/users/Rombur/repos","events_url":"https://api.github.com/users/Rombur/events{/privacy}","received_events_url":"https://api.github.com/users/Rombur/received_events","type":"User","site_admin":false},"repo":{"id":50516122,"name":"Cap","full_name":"Rombur/Cap","owner":{"login":"Rombur","id":368538,"avatar_url":"https://avatars.githubusercontent.com/u/368538?v=3","gravatar_id":"","url":"https://api.github.com/users/Rombur","html_url":"https://github.com/Rombur","followers_url":"https://api.github.com/users/Rombur/followers","following_url":"https://api.github.com/users/Rombur/following{/other_user}","gists_url":"https://api.github.com/users/Rombur/gists{/gist_id}","starred_url":"https://api.github.com/users/Rombur/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rombur/subscriptions","organizations_url":"https://api.github.com/users/Rombur/orgs","repos_url":"https://api.github.com/users/Rombur/repos","events_url":"https://api.github.com/users/Rombur/events{/privacy}","received_events_url":"https://api.github.com/users/Rombur/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Rombur/Cap","description":"A library for modeling energy storage devices.","fork":true,"url":"https://api.github.com/repos/Rombur/Cap","forks_url":"https://api.github.com/repos/Rombur/Cap/forks","keys_url":"https://api.github.com/repos/Rombur/Cap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Rombur/Cap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Rombur/Cap/teams","hooks_url":"https://api.github.com/repos/Rombur/Cap/hooks","issue_events_url":"https://api.github.com/repos/Rombur/Cap/issues/events{/number}","events_url":"https://api.github.com/repos/Rombur/Cap/events","assignees_url":"https://api.github.com/repos/Rombur/Cap/assignees{/user}","branches_url":"https://api.github.com/repos/Rombur/Cap/branches{/branch}","tags_url":"https://api.github.com/repos/Rombur/Cap/tags","blobs_url":"https://api.github.com/repos/Rombur/Cap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Rombur/Cap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Rombur/Cap/git/refs{/sha}","trees_url":"https://api.github.com/repos/Rombur/Cap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Rombur/Cap/statuses/{sha}","languages_url":"https://api.github.com/repos/Rombur/Cap/languages","stargazers_url":"https://api.github.com/repos/Rombur/Cap/stargazers","contributors_url":"https://api.github.com/repos/Rombur/Cap/contributors","subscribers_url":"https://api.github.com/repos/Rombur/Cap/subscribers","subscription_url":"https://api.github.com/repos/Rombur/Cap/subscription","commits_url":"https://api.github.com/repos/Rombur/Cap/commits{/sha}","git_commits_url":"https://api.github.com/repos/Rombur/Cap/git/commits{/sha}","comments_url":"https://api.github.com/repos/Rombur/Cap/comments{/number}","issue_comment_url":"https://api.github.com/repos/Rombur/Cap/issues/comments{/number}","contents_url":"https://api.github.com/repos/Rombur/Cap/contents/{+path}","compare_url":"https://api.github.com/repos/Rombur/Cap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Rombur/Cap/merges","archive_url":"https://api.github.com/repos/Rombur/Cap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Rombur/Cap/downloads","issues_url":"https://api.github.com/repos/Rombur/Cap/issues{/number}","pulls_url":"https://api.github.com/repos/Rombur/Cap/pulls{/number}","milestones_url":"https://api.github.com/repos/Rombur/Cap/milestones{/number}","notifications_url":"https://api.github.com/repos/Rombur/Cap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Rombur/Cap/labels{/name}","releases_url":"https://api.github.com/repos/Rombur/Cap/releases{/id}","deployments_url":"https://api.github.com/repos/Rombur/Cap/deployments","created_at":"2016-01-27T15:17:09Z","updated_at":"2016-01-27T15:17:10Z","pushed_at":"2016-03-16T13:16:05Z","git_url":"git://github.com/Rombur/Cap.git","ssh_url":"git@github.com:Rombur/Cap.git","clone_url":"https://github.com/Rombur/Cap.git","svn_url":"https://github.com/Rombur/Cap","homepage":"http://cap.readthedocs.org","size":1215,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ORNL-CEES:master","ref":"master","sha":"92771d88e063690b05b976a38ff9298a2a86bc3a","user":{"login":"ORNL-CEES","id":6653148,"avatar_url":"https://avatars.githubusercontent.com/u/6653148?v=3","gravatar_id":"","url":"https://api.github.com/users/ORNL-CEES","html_url":"https://github.com/ORNL-CEES","followers_url":"https://api.github.com/users/ORNL-CEES/followers","following_url":"https://api.github.com/users/ORNL-CEES/following{/other_user}","gists_url":"https://api.github.com/users/ORNL-CEES/gists{/gist_id}","starred_url":"https://api.github.com/users/ORNL-CEES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ORNL-CEES/subscriptions","organizations_url":"https://api.github.com/users/ORNL-CEES/orgs","repos_url":"https://api.github.com/users/ORNL-CEES/repos","events_url":"https://api.github.com/users/ORNL-CEES/events{/privacy}","received_events_url":"https://api.github.com/users/ORNL-CEES/received_events","type":"Organization","site_admin":false},"repo":{"id":50514800,"name":"Cap","full_name":"ORNL-CEES/Cap","owner":{"login":"ORNL-CEES","id":6653148,"avatar_url":"https://avatars.githubusercontent.com/u/6653148?v=3","gravatar_id":"","url":"https://api.github.com/users/ORNL-CEES","html_url":"https://github.com/ORNL-CEES","followers_url":"https://api.github.com/users/ORNL-CEES/followers","following_url":"https://api.github.com/users/ORNL-CEES/following{/other_user}","gists_url":"https://api.github.com/users/ORNL-CEES/gists{/gist_id}","starred_url":"https://api.github.com/users/ORNL-CEES/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ORNL-CEES/subscriptions","organizations_url":"https://api.github.com/users/ORNL-CEES/orgs","repos_url":"https://api.github.com/users/ORNL-CEES/repos","events_url":"https://api.github.com/users/ORNL-CEES/events{/privacy}","received_events_url":"https://api.github.com/users/ORNL-CEES/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ORNL-CEES/Cap","description":"A library for modeling energy storage devices.","fork":false,"url":"https://api.github.com/repos/ORNL-CEES/Cap","forks_url":"https://api.github.com/repos/ORNL-CEES/Cap/forks","keys_url":"https://api.github.com/repos/ORNL-CEES/Cap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ORNL-CEES/Cap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ORNL-CEES/Cap/teams","hooks_url":"https://api.github.com/repos/ORNL-CEES/Cap/hooks","issue_events_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/events{/number}","events_url":"https://api.github.com/repos/ORNL-CEES/Cap/events","assignees_url":"https://api.github.com/repos/ORNL-CEES/Cap/assignees{/user}","branches_url":"https://api.github.com/repos/ORNL-CEES/Cap/branches{/branch}","tags_url":"https://api.github.com/repos/ORNL-CEES/Cap/tags","blobs_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/refs{/sha}","trees_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/{sha}","languages_url":"https://api.github.com/repos/ORNL-CEES/Cap/languages","stargazers_url":"https://api.github.com/repos/ORNL-CEES/Cap/stargazers","contributors_url":"https://api.github.com/repos/ORNL-CEES/Cap/contributors","subscribers_url":"https://api.github.com/repos/ORNL-CEES/Cap/subscribers","subscription_url":"https://api.github.com/repos/ORNL-CEES/Cap/subscription","commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/commits{/sha}","git_commits_url":"https://api.github.com/repos/ORNL-CEES/Cap/git/commits{/sha}","comments_url":"https://api.github.com/repos/ORNL-CEES/Cap/comments{/number}","issue_comment_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues/comments{/number}","contents_url":"https://api.github.com/repos/ORNL-CEES/Cap/contents/{+path}","compare_url":"https://api.github.com/repos/ORNL-CEES/Cap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ORNL-CEES/Cap/merges","archive_url":"https://api.github.com/repos/ORNL-CEES/Cap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ORNL-CEES/Cap/downloads","issues_url":"https://api.github.com/repos/ORNL-CEES/Cap/issues{/number}","pulls_url":"https://api.github.com/repos/ORNL-CEES/Cap/pulls{/number}","milestones_url":"https://api.github.com/repos/ORNL-CEES/Cap/milestones{/number}","notifications_url":"https://api.github.com/repos/ORNL-CEES/Cap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ORNL-CEES/Cap/labels{/name}","releases_url":"https://api.github.com/repos/ORNL-CEES/Cap/releases{/id}","deployments_url":"https://api.github.com/repos/ORNL-CEES/Cap/deployments","created_at":"2016-01-27T14:56:58Z","updated_at":"2016-01-27T15:01:13Z","pushed_at":"2016-03-16T13:16:05Z","git_url":"git://github.com/ORNL-CEES/Cap.git","ssh_url":"git@github.com:ORNL-CEES/Cap.git","clone_url":"https://github.com/ORNL-CEES/Cap.git","svn_url":"https://github.com/ORNL-CEES/Cap","homepage":"http://cap.readthedocs.org","size":1221,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":8,"forks":3,"open_issues":8,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65"},"html":{"href":"https://github.com/ORNL-CEES/Cap/pull/65"},"issue":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/issues/65"},"comments":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/issues/65/comments"},"review_comments":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65/comments"},"review_comment":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/pulls/65/commits"},"statuses":{"href":"https://api.github.com/repos/ORNL-CEES/Cap/statuses/f1ad9c6a954a63897a69b85116b7156f03bada23"}}}}