{"action":"created","comment":{"url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/comments/177243868","pull_request_review_id":107083204,"id":177243868,"diff_hunk":"@@ -0,0 +1,33 @@\n+function [x, i] = MetodaTangentei(p, x0, tol, max_iter)\n+\t% solves f(x) = 0 by doing max_iter steps;\n+\t% the method requires one initial value (x0)\n+\t% which should be chosen close to the root;\n+\t% y = polyval(p, x) returns the value of a polynomial evaluated at x;\n+\t% y = polyder(p) returns the coefficients of the derivative of the polynomial \n+\t% whose coefficients are given by the vector p;\n+\tfd = polyder(p);\n+\tfor i = 1 : max_iter \t\t\n+\t\tfx = polyval(p, x0);\n+\t\tfxd = polyval(fd, x0);\n+\t\t% Calculate the value of xi using the formula;\n+\t\txi = x0 - fx / fxd;\n+\t\t% Calculate the value of polynomial evaluated at xi;\n+\t\tfxi = polyval(p, xi);\n+\t\t% xi is the solution;\n+\t\tif abs(fxi) < eps\n+\t\t\tx = xi;\n+\t\t\treturn;\n+\t\tendif\n+        \n+\t\tepsilon = abs((xi - x0) / xi);\n+        % stop if the method reached its convergence limit;","path":"MN/Algoritmi/Ecuatii-Neliniare/MetodaTangentei.m","position":23,"original_position":23,"commit_id":"a7ddec9a95a3dc974b2cf7a9b5056e8ece96c91e","original_commit_id":"a7ddec9a95a3dc974b2cf7a9b5056e8ece96c91e","user":{"login":"radusqrt","id":8861522,"avatar_url":"https://avatars2.githubusercontent.com/u/8861522?v=4","gravatar_id":"","url":"https://api.github.com/users/radusqrt","html_url":"https://github.com/radusqrt","followers_url":"https://api.github.com/users/radusqrt/followers","following_url":"https://api.github.com/users/radusqrt/following{/other_user}","gists_url":"https://api.github.com/users/radusqrt/gists{/gist_id}","starred_url":"https://api.github.com/users/radusqrt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/radusqrt/subscriptions","organizations_url":"https://api.github.com/users/radusqrt/orgs","repos_url":"https://api.github.com/users/radusqrt/repos","events_url":"https://api.github.com/users/radusqrt/events{/privacy}","received_events_url":"https://api.github.com/users/radusqrt/received_events","type":"User","site_admin":false},"body":"comentariul asta dat mai la dreapta","created_at":"2018-03-26T21:41:05Z","updated_at":"2018-03-26T21:41:52Z","html_url":"https://github.com/radusqrt/help-the-kids/pull/18#discussion_r177243868","pull_request_url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/comments/177243868"},"html":{"href":"https://github.com/radusqrt/help-the-kids/pull/18#discussion_r177243868"},"pull_request":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18"}}},"pull_request":{"url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18","id":177557680,"html_url":"https://github.com/radusqrt/help-the-kids/pull/18","diff_url":"https://github.com/radusqrt/help-the-kids/pull/18.diff","patch_url":"https://github.com/radusqrt/help-the-kids/pull/18.patch","issue_url":"https://api.github.com/repos/radusqrt/help-the-kids/issues/18","number":18,"state":"open","locked":false,"title":"Metoda Tangentei","user":{"login":"luissel","id":37814117,"avatar_url":"https://avatars3.githubusercontent.com/u/37814117?v=4","gravatar_id":"","url":"https://api.github.com/users/luissel","html_url":"https://github.com/luissel","followers_url":"https://api.github.com/users/luissel/followers","following_url":"https://api.github.com/users/luissel/following{/other_user}","gists_url":"https://api.github.com/users/luissel/gists{/gist_id}","starred_url":"https://api.github.com/users/luissel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luissel/subscriptions","organizations_url":"https://api.github.com/users/luissel/orgs","repos_url":"https://api.github.com/users/luissel/repos","events_url":"https://api.github.com/users/luissel/events{/privacy}","received_events_url":"https://api.github.com/users/luissel/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-03-26T20:24:13Z","updated_at":"2018-03-26T21:41:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8fa30ef81367eeb6f931d424b93c2f54949e80a3","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18/commits","review_comments_url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18/comments","review_comment_url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/comments{/number}","comments_url":"https://api.github.com/repos/radusqrt/help-the-kids/issues/18/comments","statuses_url":"https://api.github.com/repos/radusqrt/help-the-kids/statuses/a7ddec9a95a3dc974b2cf7a9b5056e8ece96c91e","head":{"label":"luissel:master","ref":"master","sha":"a7ddec9a95a3dc974b2cf7a9b5056e8ece96c91e","user":{"login":"luissel","id":37814117,"avatar_url":"https://avatars3.githubusercontent.com/u/37814117?v=4","gravatar_id":"","url":"https://api.github.com/users/luissel","html_url":"https://github.com/luissel","followers_url":"https://api.github.com/users/luissel/followers","following_url":"https://api.github.com/users/luissel/following{/other_user}","gists_url":"https://api.github.com/users/luissel/gists{/gist_id}","starred_url":"https://api.github.com/users/luissel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luissel/subscriptions","organizations_url":"https://api.github.com/users/luissel/orgs","repos_url":"https://api.github.com/users/luissel/repos","events_url":"https://api.github.com/users/luissel/events{/privacy}","received_events_url":"https://api.github.com/users/luissel/received_events","type":"User","site_admin":false},"repo":{"id":126879487,"name":"help-the-kids","full_name":"luissel/help-the-kids","owner":{"login":"luissel","id":37814117,"avatar_url":"https://avatars3.githubusercontent.com/u/37814117?v=4","gravatar_id":"","url":"https://api.github.com/users/luissel","html_url":"https://github.com/luissel","followers_url":"https://api.github.com/users/luissel/followers","following_url":"https://api.github.com/users/luissel/following{/other_user}","gists_url":"https://api.github.com/users/luissel/gists{/gist_id}","starred_url":"https://api.github.com/users/luissel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luissel/subscriptions","organizations_url":"https://api.github.com/users/luissel/orgs","repos_url":"https://api.github.com/users/luissel/repos","events_url":"https://api.github.com/users/luissel/events{/privacy}","received_events_url":"https://api.github.com/users/luissel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/luissel/help-the-kids","description":"Repository with the purpose of helping the young ones in need on their path to achieving the programmer wisdom.","fork":true,"url":"https://api.github.com/repos/luissel/help-the-kids","forks_url":"https://api.github.com/repos/luissel/help-the-kids/forks","keys_url":"https://api.github.com/repos/luissel/help-the-kids/keys{/key_id}","collaborators_url":"https://api.github.com/repos/luissel/help-the-kids/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/luissel/help-the-kids/teams","hooks_url":"https://api.github.com/repos/luissel/help-the-kids/hooks","issue_events_url":"https://api.github.com/repos/luissel/help-the-kids/issues/events{/number}","events_url":"https://api.github.com/repos/luissel/help-the-kids/events","assignees_url":"https://api.github.com/repos/luissel/help-the-kids/assignees{/user}","branches_url":"https://api.github.com/repos/luissel/help-the-kids/branches{/branch}","tags_url":"https://api.github.com/repos/luissel/help-the-kids/tags","blobs_url":"https://api.github.com/repos/luissel/help-the-kids/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/luissel/help-the-kids/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/luissel/help-the-kids/git/refs{/sha}","trees_url":"https://api.github.com/repos/luissel/help-the-kids/git/trees{/sha}","statuses_url":"https://api.github.com/repos/luissel/help-the-kids/statuses/{sha}","languages_url":"https://api.github.com/repos/luissel/help-the-kids/languages","stargazers_url":"https://api.github.com/repos/luissel/help-the-kids/stargazers","contributors_url":"https://api.github.com/repos/luissel/help-the-kids/contributors","subscribers_url":"https://api.github.com/repos/luissel/help-the-kids/subscribers","subscription_url":"https://api.github.com/repos/luissel/help-the-kids/subscription","commits_url":"https://api.github.com/repos/luissel/help-the-kids/commits{/sha}","git_commits_url":"https://api.github.com/repos/luissel/help-the-kids/git/commits{/sha}","comments_url":"https://api.github.com/repos/luissel/help-the-kids/comments{/number}","issue_comment_url":"https://api.github.com/repos/luissel/help-the-kids/issues/comments{/number}","contents_url":"https://api.github.com/repos/luissel/help-the-kids/contents/{+path}","compare_url":"https://api.github.com/repos/luissel/help-the-kids/compare/{base}...{head}","merges_url":"https://api.github.com/repos/luissel/help-the-kids/merges","archive_url":"https://api.github.com/repos/luissel/help-the-kids/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/luissel/help-the-kids/downloads","issues_url":"https://api.github.com/repos/luissel/help-the-kids/issues{/number}","pulls_url":"https://api.github.com/repos/luissel/help-the-kids/pulls{/number}","milestones_url":"https://api.github.com/repos/luissel/help-the-kids/milestones{/number}","notifications_url":"https://api.github.com/repos/luissel/help-the-kids/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/luissel/help-the-kids/labels{/name}","releases_url":"https://api.github.com/repos/luissel/help-the-kids/releases{/id}","deployments_url":"https://api.github.com/repos/luissel/help-the-kids/deployments","created_at":"2018-03-26T19:28:20Z","updated_at":"2018-03-26T20:21:41Z","pushed_at":"2018-03-26T20:21:40Z","git_url":"git://github.com/luissel/help-the-kids.git","ssh_url":"git@github.com:luissel/help-the-kids.git","clone_url":"https://github.com/luissel/help-the-kids.git","svn_url":"https://github.com/luissel/help-the-kids","homepage":null,"size":117,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"radusqrt:master","ref":"master","sha":"d4f438509127ba66455850724f1c61f7983ad315","user":{"login":"radusqrt","id":8861522,"avatar_url":"https://avatars2.githubusercontent.com/u/8861522?v=4","gravatar_id":"","url":"https://api.github.com/users/radusqrt","html_url":"https://github.com/radusqrt","followers_url":"https://api.github.com/users/radusqrt/followers","following_url":"https://api.github.com/users/radusqrt/following{/other_user}","gists_url":"https://api.github.com/users/radusqrt/gists{/gist_id}","starred_url":"https://api.github.com/users/radusqrt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/radusqrt/subscriptions","organizations_url":"https://api.github.com/users/radusqrt/orgs","repos_url":"https://api.github.com/users/radusqrt/repos","events_url":"https://api.github.com/users/radusqrt/events{/privacy}","received_events_url":"https://api.github.com/users/radusqrt/received_events","type":"User","site_admin":false},"repo":{"id":111743400,"name":"help-the-kids","full_name":"radusqrt/help-the-kids","owner":{"login":"radusqrt","id":8861522,"avatar_url":"https://avatars2.githubusercontent.com/u/8861522?v=4","gravatar_id":"","url":"https://api.github.com/users/radusqrt","html_url":"https://github.com/radusqrt","followers_url":"https://api.github.com/users/radusqrt/followers","following_url":"https://api.github.com/users/radusqrt/following{/other_user}","gists_url":"https://api.github.com/users/radusqrt/gists{/gist_id}","starred_url":"https://api.github.com/users/radusqrt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/radusqrt/subscriptions","organizations_url":"https://api.github.com/users/radusqrt/orgs","repos_url":"https://api.github.com/users/radusqrt/repos","events_url":"https://api.github.com/users/radusqrt/events{/privacy}","received_events_url":"https://api.github.com/users/radusqrt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/radusqrt/help-the-kids","description":"Repository with the purpose of helping the young ones in need on their path to achieving the programmer wisdom.","fork":false,"url":"https://api.github.com/repos/radusqrt/help-the-kids","forks_url":"https://api.github.com/repos/radusqrt/help-the-kids/forks","keys_url":"https://api.github.com/repos/radusqrt/help-the-kids/keys{/key_id}","collaborators_url":"https://api.github.com/repos/radusqrt/help-the-kids/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/radusqrt/help-the-kids/teams","hooks_url":"https://api.github.com/repos/radusqrt/help-the-kids/hooks","issue_events_url":"https://api.github.com/repos/radusqrt/help-the-kids/issues/events{/number}","events_url":"https://api.github.com/repos/radusqrt/help-the-kids/events","assignees_url":"https://api.github.com/repos/radusqrt/help-the-kids/assignees{/user}","branches_url":"https://api.github.com/repos/radusqrt/help-the-kids/branches{/branch}","tags_url":"https://api.github.com/repos/radusqrt/help-the-kids/tags","blobs_url":"https://api.github.com/repos/radusqrt/help-the-kids/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/radusqrt/help-the-kids/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/radusqrt/help-the-kids/git/refs{/sha}","trees_url":"https://api.github.com/repos/radusqrt/help-the-kids/git/trees{/sha}","statuses_url":"https://api.github.com/repos/radusqrt/help-the-kids/statuses/{sha}","languages_url":"https://api.github.com/repos/radusqrt/help-the-kids/languages","stargazers_url":"https://api.github.com/repos/radusqrt/help-the-kids/stargazers","contributors_url":"https://api.github.com/repos/radusqrt/help-the-kids/contributors","subscribers_url":"https://api.github.com/repos/radusqrt/help-the-kids/subscribers","subscription_url":"https://api.github.com/repos/radusqrt/help-the-kids/subscription","commits_url":"https://api.github.com/repos/radusqrt/help-the-kids/commits{/sha}","git_commits_url":"https://api.github.com/repos/radusqrt/help-the-kids/git/commits{/sha}","comments_url":"https://api.github.com/repos/radusqrt/help-the-kids/comments{/number}","issue_comment_url":"https://api.github.com/repos/radusqrt/help-the-kids/issues/comments{/number}","contents_url":"https://api.github.com/repos/radusqrt/help-the-kids/contents/{+path}","compare_url":"https://api.github.com/repos/radusqrt/help-the-kids/compare/{base}...{head}","merges_url":"https://api.github.com/repos/radusqrt/help-the-kids/merges","archive_url":"https://api.github.com/repos/radusqrt/help-the-kids/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/radusqrt/help-the-kids/downloads","issues_url":"https://api.github.com/repos/radusqrt/help-the-kids/issues{/number}","pulls_url":"https://api.github.com/repos/radusqrt/help-the-kids/pulls{/number}","milestones_url":"https://api.github.com/repos/radusqrt/help-the-kids/milestones{/number}","notifications_url":"https://api.github.com/repos/radusqrt/help-the-kids/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/radusqrt/help-the-kids/labels{/name}","releases_url":"https://api.github.com/repos/radusqrt/help-the-kids/releases{/id}","deployments_url":"https://api.github.com/repos/radusqrt/help-the-kids/deployments","created_at":"2017-11-22T23:50:00Z","updated_at":"2018-03-26T20:07:26Z","pushed_at":"2018-03-26T20:24:14Z","git_url":"git://github.com/radusqrt/help-the-kids.git","ssh_url":"git@github.com:radusqrt/help-the-kids.git","clone_url":"https://github.com/radusqrt/help-the-kids.git","svn_url":"https://github.com/radusqrt/help-the-kids","homepage":null,"size":118,"stargazers_count":1,"watchers_count":1,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":16,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":16,"open_issues":2,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18"},"html":{"href":"https://github.com/radusqrt/help-the-kids/pull/18"},"issue":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/issues/18"},"comments":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/issues/18/comments"},"review_comments":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18/comments"},"review_comment":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/pulls/18/commits"},"statuses":{"href":"https://api.github.com/repos/radusqrt/help-the-kids/statuses/a7ddec9a95a3dc974b2cf7a9b5056e8ece96c91e"}},"author_association":"NONE"}}
{"actor":{"display_login":"radusqrt"}}