LMCAS
Lamina Computer Algebra System
载入中...
搜索中...
未找到
vector_calculus_integral_api.cpp
浏览该文件的文档.
5#include "integration.hpp"
6#include <stdexcept>
7
8namespace LMCAS {
9
10using namespace vector_calculus_detail;
11
13 const std::shared_ptr<SymbolicExpr>& P,
14 const std::shared_ptr<SymbolicExpr>& Q,
15 const std::vector<std::string>& vars,
16 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
17 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds,
19{
20 detail::RewriteBudget transform_budget(context, context.limits().max_recursion_depth,
21 context.limits().max_ast_nodes, "greens_theorem");
22 const std::string operation = "greens_theorem";
23 auto vars_valid = vector_calculus_validate_distinct_vars(vars, 2, context, operation);
24 if (!vars_valid) {
25 return VectorCalculusExprResult::failure(vars_valid.error());
26 }
27 if (!P || !LMCAS::detail::node(P) || !Q || !LMCAS::detail::node(Q)) {
30 "Green's theorem vector-field components cannot be null",
31 operation);
32 }
33 auto x_valid = vector_calculus_validate_bound_pair(x_bounds, context, operation, "x");
34 if (!x_valid) {
35 return VectorCalculusExprResult::failure(x_valid.error());
36 }
37 auto y_valid = vector_calculus_validate_bound_pair(y_bounds, context, operation, "y");
38 if (!y_valid) {
39 return VectorCalculusExprResult::failure(y_valid.error());
40 }
41 auto step = context.consume_steps(10, operation);
42 if (!step) {
43 return VectorCalculusExprResult::failure(step.error());
44 }
45
46 try {
47 return greens_theorem_strict(P, Q, vars, x_bounds, y_bounds, context, operation, transform_budget);
48 } catch (const CasError& error) {
50 } catch (const std::bad_alloc&) {
52 "Green's theorem allocation failed",
53 operation);
54 } catch (const std::length_error& error) {
55 return VectorCalculusExprResult::failure(CasErrc::ResourceLimit, error.what(), operation);
56 } catch (const std::exception& e) {
58 }
59}
60
62 const std::shared_ptr<SymbolicExpr>& P,
63 const std::shared_ptr<SymbolicExpr>& Q,
64 const std::vector<std::string>& vars,
65 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
66 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds)
67{
70}
71
72std::shared_ptr<SymbolicExpr> greens_theorem(
73 const std::shared_ptr<SymbolicExpr>& P,
74 const std::shared_ptr<SymbolicExpr>& Q,
75 const std::vector<std::string>& vars,
76 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
77 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds)
78{
80 detail::RewriteBudget transform_budget(context, (context).limits().max_recursion_depth,
81 (context).limits().max_ast_nodes, "transform");
82 if (!P || !Q) {
83 throw std::invalid_argument("greens_theorem: P and Q must not be null");
84 }
85 if (vars.size() != 2) {
86 throw std::invalid_argument("greens_theorem: vars must have exactly 2 elements");
87 }
88 if (!x_bounds.first || !x_bounds.second ||
89 !y_bounds.first || !y_bounds.second) {
90 throw std::invalid_argument("greens_theorem: bounds must not be null");
91 }
92
93 const std::string& x_var = vars[0];
94 const std::string& y_var = vars[1];
95
96 /// 计算被积函数: ∂Q/∂x - ∂P/∂y
97 auto dQ_dx = detail::make_expression_ptr(detail::differentiate_node(detail::node(Q), x_var, transform_budget));
98 auto dP_dy = detail::make_expression_ptr(detail::differentiate_node(detail::node(P), y_var, transform_budget));
99
100 if (!dQ_dx) dQ_dx = SymbolicExpr::number(0);
101 if (!dP_dy) dP_dy = SymbolicExpr::number(0);
102
103 dQ_dx = detail::make_expression_ptr(detail::normalize_node(detail::node(dQ_dx), transform_budget));
104 dP_dy = detail::make_expression_ptr(detail::normalize_node(detail::node(dP_dy), transform_budget));
105
106 auto integrand = SymbolicExpr::add(
107 dQ_dx,
108 SymbolicExpr::multiply(SymbolicExpr::number(-1), dP_dy));
109 integrand = detail::make_expression_ptr(detail::normalize_node(detail::node(integrand), transform_budget));
110
111 Integrator integrator;
112
113 std::vector<IntegrationStep> steps = {
114 {y_var, y_bounds.first, y_bounds.second},
115 {x_var, x_bounds.first, x_bounds.second},
116 };
117 auto result = integrate_multiple_checked(*integrand, steps, integrator, context);
118 if (!result) throw result.error();
119 return LMCAS::detail::make_expression_ptr(result.value());
120}
121
122
125 const std::string& t,
126 const std::shared_ptr<SymbolicExpr>& a,
127 const std::shared_ptr<SymbolicExpr>& b,
129{
130 detail::RewriteBudget transform_budget(context, context.limits().max_recursion_depth,
131 context.limits().max_ast_nodes, "greens_theorem_area");
132 const std::string operation = "greens_theorem_area";
134 parametrization, t, a, b, context, operation);
135 if (!valid) {
136 return VectorCalculusExprResult::failure(valid.error());
137 }
138 if (parametrization.size() != 2) {
141 "Green's area parametrization must be two-dimensional",
142 operation);
143 }
144 auto step = context.consume_steps(10, operation);
145 if (!step) {
146 return VectorCalculusExprResult::failure(step.error());
147 }
148
149 try {
150 return greens_theorem_area_strict(parametrization, t, a, b, context, operation, transform_budget);
151 } catch (const CasError& error) {
153 } catch (const std::bad_alloc&) {
155 "Green's area allocation failed",
156 operation);
157 } catch (const std::length_error& error) {
158 return VectorCalculusExprResult::failure(CasErrc::ResourceLimit, error.what(), operation);
159 } catch (const std::exception& e) {
161 }
162}
163
166 const std::string& t,
167 const std::shared_ptr<SymbolicExpr>& a,
168 const std::shared_ptr<SymbolicExpr>& b)
169{
172}
173
174std::shared_ptr<SymbolicExpr> greens_theorem_area(
176 const std::string& t,
177 const std::shared_ptr<SymbolicExpr>& a,
178 const std::shared_ptr<SymbolicExpr>& b)
179{
180 if (parametrization.size() != 2) {
181 throw std::invalid_argument(
182 "greens_theorem_area: parametrization must have 2 components (x(t), y(t))");
183 }
184 if (!a || !b) {
185 throw std::invalid_argument("greens_theorem_area: bounds must not be null");
186 }
187
188 auto x_t = parametrization[0];
189 auto y_t = parametrization[1];
190
191 if (!x_t || !y_t) {
192 throw std::invalid_argument("greens_theorem_area: parametrization components must not be null");
193 }
194
196 auto area = greens_theorem_area_checked(
198 if (!area && area.error().code != CasErrc::Inconclusive &&
199 area.error().code != CasErrc::UnsupportedExpression &&
200 area.error().code != CasErrc::DomainError) {
201 throw area.error();
202 }
203 return area ? std::move(area.value()) : nullptr;
204}
205
206
208 const VectorField& F,
209 const std::vector<std::string>& vars,
210 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
211 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds,
212 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& z_bounds,
214{
215 detail::RewriteBudget transform_budget(context, context.limits().max_recursion_depth,
216 context.limits().max_ast_nodes, "divergence_theorem");
217 const std::string operation = "divergence_theorem";
218 auto field_valid = vector_calculus_validate_field_vars(F, vars, context, operation);
219 if (!field_valid) {
220 return VectorCalculusExprResult::failure(field_valid.error());
221 }
222 auto vars_valid = vector_calculus_validate_distinct_vars(vars, 3, context, operation);
223 if (!vars_valid) {
224 return VectorCalculusExprResult::failure(vars_valid.error());
225 }
226 auto x_valid = vector_calculus_validate_bound_pair(x_bounds, context, operation, "x");
227 if (!x_valid) {
228 return VectorCalculusExprResult::failure(x_valid.error());
229 }
230 auto y_valid = vector_calculus_validate_bound_pair(y_bounds, context, operation, "y");
231 if (!y_valid) {
232 return VectorCalculusExprResult::failure(y_valid.error());
233 }
234 auto z_valid = vector_calculus_validate_bound_pair(z_bounds, context, operation, "z");
235 if (!z_valid) {
236 return VectorCalculusExprResult::failure(z_valid.error());
237 }
238 auto step = context.consume_steps(14, operation);
239 if (!step) {
240 return VectorCalculusExprResult::failure(step.error());
241 }
242
243 try {
244 return divergence_theorem_strict(F, vars, x_bounds, y_bounds, z_bounds, context, operation, transform_budget);
245 } catch (const CasError& error) {
247 } catch (const std::bad_alloc&) {
249 "divergence theorem allocation failed",
250 operation);
251 } catch (const std::length_error& error) {
252 return VectorCalculusExprResult::failure(CasErrc::ResourceLimit, error.what(), operation);
253 } catch (const std::exception& e) {
255 }
256}
257
259 const VectorField& F,
260 const std::vector<std::string>& vars,
261 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
262 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds,
263 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& z_bounds)
264{
267}
268
269std::shared_ptr<SymbolicExpr> divergence_theorem(
270 const VectorField& F,
271 const std::vector<std::string>& vars,
272 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& x_bounds,
273 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& y_bounds,
274 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& z_bounds)
275{
277 detail::RewriteBudget transform_budget(context, context.limits().max_recursion_depth,
278 context.limits().max_ast_nodes, "divergence_theorem");
279 if (F.size() != 3) {
280 throw std::invalid_argument("divergence_theorem: F must have 3 components");
281 }
282 if (vars.size() != 3) {
283 throw std::invalid_argument("divergence_theorem: vars must have exactly 3 elements");
284 }
285 if (!x_bounds.first || !x_bounds.second ||
286 !y_bounds.first || !y_bounds.second ||
287 !z_bounds.first || !z_bounds.second) {
288 throw std::invalid_argument("divergence_theorem: bounds must not be null");
289 }
290
291 /// 计算散度 ∇·F = ∂F₁/∂x + ∂F₂/∂y + ∂F₃/∂z
292 auto div_F = divergence_impl(F, vars, transform_budget);
293
294 Integrator integrator;
295 std::vector<IntegrationStep> steps = {
296 {vars[2], z_bounds.first, z_bounds.second},
297 {vars[1], y_bounds.first, y_bounds.second},
298 {vars[0], x_bounds.first, x_bounds.second},
299 };
300 auto result = integrate_multiple_checked(*div_F, steps, integrator, context);
301 if (!result) throw result.error();
302 return LMCAS::detail::make_expression_ptr(result.value());
303}
304
305
307 const VectorField& F,
308 const std::vector<std::string>& vars,
310 const std::string& u, const std::string& v,
311 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& u_bounds,
312 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& v_bounds,
314{
315 detail::RewriteBudget transform_budget(context, context.limits().max_recursion_depth,
316 context.limits().max_ast_nodes, "stokes_theorem");
317 const std::string operation = "stokes_theorem";
318 auto field_valid = vector_calculus_validate_field_vars(F, vars, context, operation);
319 if (!field_valid) {
320 return VectorCalculusExprResult::failure(field_valid.error());
321 }
322 auto vars_valid = vector_calculus_validate_distinct_vars(vars, 3, context, operation);
323 if (!vars_valid) {
324 return VectorCalculusExprResult::failure(vars_valid.error());
325 }
327 parametrization, u, v, u_bounds.first, u_bounds.second,
328 v_bounds.first, v_bounds.second, context, operation);
329 if (!param_valid) {
330 return VectorCalculusExprResult::failure(param_valid.error());
331 }
332 auto step = context.consume_steps(18, operation);
333 if (!step) {
334 return VectorCalculusExprResult::failure(step.error());
335 }
336
337 try {
338 return stokes_theorem_strict(F, vars, parametrization, u, v, u_bounds, v_bounds, context, operation, transform_budget);
339 } catch (const CasError& error) {
341 } catch (const std::bad_alloc&) {
343 "Stokes theorem allocation failed",
344 operation);
345 } catch (const std::length_error& error) {
346 return VectorCalculusExprResult::failure(CasErrc::ResourceLimit, error.what(), operation);
347 } catch (const std::exception& e) {
349 }
350}
351
353 const VectorField& F,
354 const std::vector<std::string>& vars,
356 const std::string& u, const std::string& v,
357 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& u_bounds,
358 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& v_bounds)
359{
363}
364
365std::shared_ptr<SymbolicExpr> stokes_theorem(
366 const VectorField& F,
367 const std::vector<std::string>& vars,
369 const std::string& u, const std::string& v,
370 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& u_bounds,
371 const std::pair<std::shared_ptr<SymbolicExpr>, std::shared_ptr<SymbolicExpr>>& v_bounds)
372{
374 detail::RewriteBudget transform_budget(context, (context).limits().max_recursion_depth,
375 (context).limits().max_ast_nodes, "transform");
376 if (F.size() != 3) {
377 throw std::invalid_argument("stokes_theorem: F must have 3 components");
378 }
379 if (vars.size() != 3) {
380 throw std::invalid_argument("stokes_theorem: vars must have exactly 3 elements");
381 }
382 if (parametrization.size() != 3) {
383 throw std::invalid_argument(
384 "stokes_theorem: parametrization must have 3 components");
385 }
386 if (!u_bounds.first || !u_bounds.second ||
387 !v_bounds.first || !v_bounds.second) {
388 throw std::invalid_argument("stokes_theorem: bounds must not be null");
389 }
390
391 /// 计算旋度 ∇×F
392 auto curl_F = curl_impl(F, vars, transform_budget);
393
394 /// 计算 r_u × r_v(曲面法向量)
395 auto cross = vector_calculus_cross_product_partials(parametrization, u, v, transform_budget);
396
397 /// 将 (∇×F) 中的坐标变量替换为参数化表达式,然后计算 (∇×F)·(r_u × r_v)
398 std::shared_ptr<SymbolicExpr> dot_product = nullptr;
399
400 for (size_t i = 0; i < 3; ++i) {
401 if (!curl_F[i]) {
402 continue;
403 }
404
405 /// 将 (∇×F)ᵢ 中的坐标变量替换为参数化表达式
406 auto curl_i_composed = curl_F[i];
407 for (size_t j = 0; j < 3; ++j) {
408 curl_i_composed = detail::make_expression_ptr(detail::substitute_node(detail::node(curl_i_composed), vars[j], detail::node(parametrization[j]), transform_budget));
409 }
410 curl_i_composed = detail::make_expression_ptr(detail::normalize_node(detail::node(curl_i_composed), transform_budget));
411
412 /// (∇×F)ᵢ(r(u,v)) · (r_u × r_v)ᵢ
413 auto term = SymbolicExpr::multiply(curl_i_composed, cross[i]);
414 term = detail::make_expression_ptr(detail::normalize_node(detail::node(term), transform_budget));
415
416 if (!dot_product) {
417 dot_product = term;
418 } else {
419 dot_product = SymbolicExpr::add(dot_product, term);
421 }
422 }
423
424 if (!dot_product) {
425 return SymbolicExpr::number(0);
426 }
427
428 Integrator integrator;
429
430 std::vector<IntegrationStep> steps = {
431 {v, v_bounds.first, v_bounds.second},
432 {u, u_bounds.first, u_bounds.second},
433 };
435 if (!result) throw result.error();
436 return LMCAS::detail::make_expression_ptr(result.value());
437}
438
439}
static Result failure(CasErrc code, std::string message, std::string operation={})
Symbolic integration APIs.
SymbolicNodePtr differentiate_node(const SymbolicNodePtr &node, const std::string &variable, RewriteBudget &budget, const FactsQuery &facts, Domain domain)
std::shared_ptr<::LMCAS::SymbolicExpr > make_expression_ptr(SymbolicNodePtr root)
const SymbolicNodePtr & node(const ::LMCAS::SymbolicExpr &expression) noexcept
SymbolicNodePtr normalize_node(const SymbolicNodePtr &node, RewriteBudget &budget, const FactsQuery &facts, Domain domain)
SymbolicNodePtr substitute_node(const SymbolicNodePtr &node, const std::string &variable, const SymbolicNodePtr &replacement, RewriteBudget &budget, const FactsQuery &facts, Domain domain)
VectorField vector_calculus_cross_product_partials(const VectorField &parametrization, const std::string &u, const std::string &v, detail::RewriteBudget &transform_budget)
Result< void > vector_calculus_validate_distinct_vars(const std::vector< std::string > &vars, std::size_t expected, ComputationContext &context, const std::string &operation)
Result< void > vector_calculus_validate_surface_parametrization(const VectorField &parametrization, const std::string &u, const std::string &v, const std::shared_ptr< SymbolicExpr > &u_lower, const std::shared_ptr< SymbolicExpr > &u_upper, const std::shared_ptr< SymbolicExpr > &v_lower, const std::shared_ptr< SymbolicExpr > &v_upper, ComputationContext &context, const std::string &operation)
VectorCalculusExprResult greens_theorem_area_strict(const VectorField &parametrization, const std::string &parameter, const std::shared_ptr< SymbolicExpr > &lower, const std::shared_ptr< SymbolicExpr > &upper, ComputationContext &context, const std::string &operation, detail::RewriteBudget &transform_budget)
std::shared_ptr< SymbolicExpr > divergence_impl(const VectorField &F, const std::vector< std::string > &vars, detail::RewriteBudget &transform_budget)
Result< void > vector_calculus_validate_curve_parametrization(const VectorField &parametrization, const std::string &t, const std::shared_ptr< SymbolicExpr > &a, const std::shared_ptr< SymbolicExpr > &b, ComputationContext &context, const std::string &operation)
VectorCalculusExprResult stokes_theorem_strict(const VectorField &field, const std::vector< std::string > &variables, const VectorField &parametrization, const std::string &u, const std::string &v, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &u_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &v_bounds, ComputationContext &context, const std::string &operation, detail::RewriteBudget &transform_budget)
VectorCalculusExprResult greens_theorem_strict(const std::shared_ptr< SymbolicExpr > &p, const std::shared_ptr< SymbolicExpr > &q, const std::vector< std::string > &variables, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds, ComputationContext &context, const std::string &operation, detail::RewriteBudget &transform_budget)
Result< void > vector_calculus_validate_bound_pair(const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &bounds, ComputationContext &context, const std::string &operation, const std::string &label)
Result< void > vector_calculus_validate_field_vars(const VectorField &field, const std::vector< std::string > &vars, ComputationContext &context, const std::string &operation)
VectorField curl_impl(const VectorField &F, const std::vector< std::string > &vars, detail::RewriteBudget &transform_budget)
VectorCalculusExprResult divergence_theorem_strict(const VectorField &field, const std::vector< std::string > &variables, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &z_bounds, ComputationContext &context, const std::string &operation, detail::RewriteBudget &transform_budget)
ExprResult e()
__attribute__((visibility("default"))) VectorCalculusExprResult surface_integral_scalar_checked(const std __attribute__((visibility("default"))) VectorCalculusExprResult surface_integral_scalar_checked(const std __attribute__((visibility("default"))) std const VectorField const std::string const std::string & v
const std::vector< Polynomial< BigInt > > const BigInt ComputationContext & context
__attribute__((visibility("default"))) VectorCalculusFieldResult gradient_checked(const std __attribute__((visibility("default"))) VectorCalculusFieldResult gradient_checked(const std __attribute__((visibility("default"))) VectorField gradient(const std const std::vector< std::string > & vars
std::shared_ptr< SymbolicExpr > divergence_theorem(const VectorField &F, const std::vector< std::string > &vars, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &z_bounds)
std::shared_ptr< SymbolicExpr > greens_theorem(const std::shared_ptr< SymbolicExpr > &P, const std::shared_ptr< SymbolicExpr > &Q, const std::vector< std::string > &vars, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds)
VectorCalculusExprResult greens_theorem_area_checked(const VectorField &parametrization, const std::string &t, const std::shared_ptr< SymbolicExpr > &a, const std::shared_ptr< SymbolicExpr > &b, ComputationContext &context)
const MultiPoly & b
std::shared_ptr< SymbolicExpr > stokes_theorem(const VectorField &F, const std::vector< std::string > &vars, const VectorField &parametrization, const std::string &u, const std::string &v, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &u_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &v_bounds)
VectorCalculusExprResult greens_theorem_checked(const std::shared_ptr< SymbolicExpr > &P, const std::shared_ptr< SymbolicExpr > &Q, const std::vector< std::string > &vars, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds, ComputationContext &context)
__attribute__((visibility("default"))) std const std::vector< std::string > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > & z_bounds
VectorCalculusExprResult divergence_theorem_checked(const VectorField &F, const std::vector< std::string > &vars, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &x_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &y_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &z_bounds, ComputationContext &context)
__attribute__((visibility("default"))) std const std::vector< std::string > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > & x_bounds
__attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) std const VectorField const std::string const std::shared_ptr< SymbolicExpr > & a
std::vector< std::shared_ptr< SymbolicExpr > > VectorField
向量场由标量表达式组成。
std::shared_ptr< SymbolicExpr > greens_theorem_area(const VectorField &parametrization, const std::string &t, const std::shared_ptr< SymbolicExpr > &a, const std::shared_ptr< SymbolicExpr > &b)
__attribute__((visibility("default"))) std const std::vector< std::string > const VectorField const std::string const std::string const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > & u_bounds
__attribute__((visibility("default"))) std const std::vector< std::string > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > & y_bounds
__attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) std const VectorField & parametrization
Result< SymbolicExpr > integrate_multiple_checked(const SymbolicExpr &integrand, const std::vector< IntegrationStep > &steps, Integrator &integrator, ComputationContext &context)
Result< std::shared_ptr< SymbolicExpr > > VectorCalculusExprResult
VectorCalculusExprResult stokes_theorem_checked(const VectorField &F, const std::vector< std::string > &vars, const VectorField &parametrization, const std::string &u, const std::string &v, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &u_bounds, const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > &v_bounds, ComputationContext &context)
__attribute__((visibility("default"))) std const std::vector< std::string > const VectorField const std::string const std::string const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > const std::pair< std::shared_ptr< SymbolicExpr >, std::shared_ptr< SymbolicExpr > > & v_bounds
__attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) VectorCalculusExprResult curve_integral_scalar_checked(const std __attribute__((visibility("default"))) std const VectorField const std::string & t
const std::vector< IntegrationStep > Integrator & integrator
VectorCalculusExprResult dot_product(const VectorField &a, const VectorField &b)
__attribute__((visibility("default"))) VectorCalculusExprResult surface_integral_scalar_checked(const std __attribute__((visibility("default"))) VectorCalculusExprResult surface_integral_scalar_checked(const std __attribute__((visibility("default"))) std const VectorField const std::string & u