Code owners
Assign users and groups as approvers for specific file changes. Learn more.
fsolve_8c.html 11.58 KiB
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.16"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>RcdMathLib_doc: fsolve.c File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(document).ready(initResizable);
/* @license-end */</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">RcdMathLib_doc
</div>
<div id="projectbrief">Open Source Library for Linear and Non-linear Algebra</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.16 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
<div id="nav-tree">
<div id="nav-tree-contents">
<div id="nav-sync" class="sync"></div>
</div>
</div>
<div id="splitbar" style="-moz-user-select:none;"
class="ui-resizable-handle">
</div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('fsolve_8c.html','');});
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div class="header">
<div class="summary">
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">fsolve.c File Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Solve multi-variant nonlinear equation systems.
<a href="#details">More...</a></p>
<div class="textblock"><code>#include "<a class="el" href="vector_8h_source.html">vector.h</a>"</code><br />
<code>#include "<a class="el" href="matrix_8h_source.html">matrix.h</a>"</code><br />
<code>#include "<a class="el" href="fsolve_8h_source.html">fsolve.h</a>"</code><br />
<code>#include "<a class="el" href="newton__raphson_8h_source.html">newton_raphson.h</a>"</code><br />
<code>#include "<a class="el" href="damped__newton__raphson_8h_source.html">damped_newton_raphson.h</a>"</code><br />
</div>
<p><a href="fsolve_8c_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:a690a05654627b94634ffed0893946ba7"><td class="memItemLeft" align="right" valign="top">uint8_t </td><td class="memItemRight" valign="bottom"><a class="el" href="fsolve_8c.html#a690a05654627b94634ffed0893946ba7">fsolve</a> (uint8_t f_length, uint8_t x0_length, <a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> x0_arr[], enum <a class="el" href="fsolve_8h.html#a806eab83c4b4a937b86ebcfd984f9206">NON_LIN_ALGORITHM</a> algo, <a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> est_x_arr[], void(*get_non_lin_sys)(<a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> x_arr[], <a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> f_vec[]), void(*get_jacobian)(<a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> x_arr[], <a class="el" href="matrix_8h.html#af38ac6b76d645fea9abd6caeb4d9dd31">matrix_t</a> J[][x0_length]))</td></tr>
<tr class="memdesc:a690a05654627b94634ffed0893946ba7"><td class="mdescLeft"> </td><td class="mdescRight">Solve systems of multi-variant nonlinear equations. <a href="fsolve_8c.html#a690a05654627b94634ffed0893946ba7">More...</a><br /></td></tr>
<tr class="separator:a690a05654627b94634ffed0893946ba7"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Solve multi-variant nonlinear equation systems. </p>
<p>The multi-variant nonlinear equation systems are solved using damped or the Newton–Raphson algorithms.</p>
<dl class="section author"><dt>Author</dt><dd>Zakaria Kasmi <a href="#" onclick="location.href='mai'+'lto:'+'zka'+'sm'+'i@i'+'nf'+'.fu'+'-b'+'erl'+'in'+'.de'; return false;">zkasm<span style="display: none;">.nosp@m.</span>i@in<span style="display: none;">.nosp@m.</span>f.fu-<span style="display: none;">.nosp@m.</span>berl<span style="display: none;">.nosp@m.</span>in.de</a> </dd></dl>
<p class="definition">Definition in file <a class="el" href="fsolve_8c_source.html">fsolve.c</a>.</p>
</div><h2 class="groupheader">Function Documentation</h2>
<a id="a690a05654627b94634ffed0893946ba7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a690a05654627b94634ffed0893946ba7">◆ </a></span>fsolve()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">uint8_t fsolve </td>
<td>(</td>
<td class="paramtype">uint8_t </td>
<td class="paramname"><em>f_length</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">uint8_t </td>
<td class="paramname"><em>x0_length</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> </td>
<td class="paramname"><em>x0_arr</em>[], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">enum <a class="el" href="fsolve_8h.html#a806eab83c4b4a937b86ebcfd984f9206">NON_LIN_ALGORITHM</a> </td>
<td class="paramname"><em>algo</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> </td>
<td class="paramname"><em>est_x_arr</em>[], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void(*)(<a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> x_arr[], <a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> f_vec[]) </td>
<td class="paramname"><em>get_non_lin_sys</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">void(*)(<a class="el" href="vector_8h.html#acb41430bc5720dda7d1c45d91a0b0221">vector_t</a> x_arr[], <a class="el" href="matrix_8h.html#af38ac6b76d645fea9abd6caeb4d9dd31">matrix_t</a> J[][x0_length]) </td>
<td class="paramname"><em>get_jacobian</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Solve systems of multi-variant nonlinear equations. </p>
<p>The user should provide pointers to non-linear equation systems and Jacobian functions. The user can choose between the damped or the Newton–Raphson algorithms.</p>
<dl class="section note"><dt>Note</dt><dd>This function is generally implemented.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramdir">[in]</td><td class="paramname">f_length</td><td>length of the error functions vector. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">x0_length</td><td>length of the start vector. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">x0_arr[]</td><td>start vector. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">algo</td><td>damped or the Newton–Raphson algorithm. </td></tr>
<tr><td class="paramdir">[in,out]</td><td class="paramname">est_x_arr[]</td><td>estimated (solution) vector. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">(*get_non_lin_sys)</td><td>pointer to non-linear equation systems. </td></tr>
<tr><td class="paramdir">[in]</td><td class="paramname">(*get_jacobian)</td><td>pointer to the Jacobian matrix.</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>required iteration number. </dd></dl>
<p class="definition">Definition at line <a class="el" href="fsolve_8c_source.html#l00029">29</a> of file <a class="el" href="fsolve_8c_source.html">fsolve.c</a>.</p>
<p class="reference">References <a class="el" href="damped__newton__raphson_8c_source.html#l00032">damped_newton_raphson()</a>, <a class="el" href="fsolve_8h_source.html#l00032">Damped_Newton_Raphson</a>, <a class="el" href="fsolve_8h_source.html#l00031">Newton_Raphson</a>, and <a class="el" href="newton__raphson_8c_source.html#l00028">newton_raphson()</a>.</p>
<p class="reference">Referenced by <a class="el" href="fsolve__test_8c_source.html#l00245">fsolve_test()</a>.</p>
</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
<ul>
<li class="navelem"><a class="el" href="dir_943f05c9b1835bace55f73b49add4eb5.html">non_linear_algebra</a></li><li class="navelem"><a class="el" href="dir_96fb3641df0eaf7ad29b2346d426a787.html">solve_non_linear_equations</a></li><li class="navelem"><a class="el" href="fsolve_8c.html">fsolve.c</a></li>
<li class="footer">Generated by
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.16 </li>
</ul>
</div>
</body>
</html>