Cantera
Loading...
Searching...
No Matches
ctkin.h
Go to the documentation of this file.
1/**
2 * CTKIN - Generated CLib %Cantera interface library.
3 *
4 * @file ctkin.h
5 *
6 * Generated CLib API for %Cantera's Kinetics class.
7 *
8 * This library of functions is designed to encapsulate %Cantera functionality
9 * and make it available for use in languages and applications other than C++.
10 * A set of library functions is provided that are declared "extern C". All
11 * %Cantera objects are stored and referenced by integers - no pointers are
12 * passed to or from the calling application.
13 *
14 * This file was generated by sourcegen. It will be re-generated by the
15 * %Cantera build process. Do not manually edit.
16 *
17 * @warning This library is an experimental part of the %Cantera API and
18 * may be changed without notice.
19 */
20
21// This file is part of Cantera. See License.txt in the top-level directory or
22// at https://cantera.org/license.txt for license and copyright information.
23
24#ifndef CTKIN_H
25#define CTKIN_H
26
27#include <stdint.h> // for 32-bit int32_t / 64-bit int64_t
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
33 /**
34 * @defgroup CAPIctkin ctkin Library
35 * Generated CLib API for %Cantera's Kinetics class.
36 *
37 * @warning This library is an experimental part of the %Cantera API and
38 * may be changed or removed without notice.
39 *
40 * @ingroup CAPIindex
41 */
42
43 /**
44 * @addtogroup CAPIctkin
45 * @{
46 */
47
48 /**
49 * Identifies the Kinetics manager type.
50 *
51 * Wraps C++ getter: `virtual string Kinetics::kineticsType()`
52 *
53 * @param handle Handle to queried Kinetics object.
54 * @param[in] bufLen Length of reserved array.
55 * @param[out] buf Returned string value.
56 * @returns Actual length of string including string-terminating null byte, \0, or -1 for exception handling.
57 */
58 int32_t kin_kineticsType(int32_t handle, int32_t bufLen, char* buf);
59
60 /**
61 * Number of reactions in the reaction mechanism.
62 *
63 * Wraps C++ getter: `size_t Kinetics::nReactions()`
64 *
65 * @param handle Handle to queried Kinetics object.
66 */
67 int32_t kin_nReactions(int32_t handle);
68
69 /**
70 * Return the Reaction object for reaction *i*.
71 *
72 * Wraps C++ accessor: `shared_ptr<Reaction> Kinetics::reaction(size_t)`
73 *
74 * Uses:
75 * - `size_t Kinetics::nReactions()`
76 *
77 * @param handle Handle to queried Kinetics object.
78 * @param i Undocumented.
79 * @returns Handle to stored Reaction object or -1 for exception handling.
80 */
81 int32_t kin_reaction(int32_t handle, int32_t i);
82
83 /**
84 * The number of phases participating in the reaction mechanism.
85 *
86 * Wraps C++ getter: `size_t Kinetics::nPhases()`
87 *
88 * @param handle Handle to queried Kinetics object.
89 */
90 int32_t kin_nPhases(int32_t handle);
91
92 /**
93 * Return pointer to phase associated with Kinetics by index.
94 *
95 * Wraps C++ accessor: `shared_ptr<ThermoPhase> Kinetics::phase(size_t)`
96 *
97 * Uses:
98 * - `size_t Kinetics::nPhases()`
99 *
100 * @param handle Handle to queried Kinetics object.
101 * @param n Index of the ThermoPhase being sought.
102 * @returns Handle to stored ThermoPhase object or -1 for exception handling.
103 */
104 int32_t kin_phase(int32_t handle, int32_t n);
105
106 /**
107 * Return pointer to phase where the reactions occur.
108 *
109 * Wraps C++ accessor: `shared_ptr<ThermoPhase> Kinetics::reactionPhase()`
110 *
111 * @param handle Handle to queried Kinetics object.
112 * @returns Handle to stored ThermoPhase object or -1 for exception handling.
113 */
114 int32_t kin_reactionPhase(int32_t handle);
115
116 /**
117 * Return the phase index of a phase in the list of phases defined within the object.
118 *
119 * Wraps C++ method: `custom code`
120 *
121 * Uses:
122 * - ` phaseIndex(const string&, bool)`
123 *
124 * @param handle Handle to queried Kinetics object.
125 * @param ph string name of the phase
126 */
127 int32_t kin_phaseIndex(int32_t handle, const char* ph);
128
129 /**
130 * The total number of species in all phases participating in the kinetics mechanism.
131 *
132 * Wraps C++ getter: `size_t Kinetics::nTotalSpecies()`
133 *
134 * @param handle Handle to queried Kinetics object.
135 */
136 int32_t kin_nTotalSpecies(int32_t handle);
137
138 /**
139 * Stoichiometric coefficient of species k as a reactant in reaction i.
140 *
141 * Wraps C++ method: `virtual double Kinetics::reactantStoichCoeff(size_t, size_t)`
142 *
143 * @param handle Handle to queried Kinetics object.
144 * @param k kinetic species index
145 * @param i reaction index
146 */
147 double kin_reactantStoichCoeff(int32_t handle, int32_t k, int32_t i);
148
149 /**
150 * Stoichiometric coefficient of species k as a product in reaction i.
151 *
152 * Wraps C++ method: `virtual double Kinetics::productStoichCoeff(size_t, size_t)`
153 *
154 * @param handle Handle to queried Kinetics object.
155 * @param k kinetic species index
156 * @param i reaction index
157 */
158 double kin_productStoichCoeff(int32_t handle, int32_t k, int32_t i);
159
160 /**
161 * Return the forward rates of progress of the reactions.
162 *
163 * Wraps C++ getter: `virtual void Kinetics::getFwdRatesOfProgress(span<double>)`
164 *
165 * @param handle Handle to queried Kinetics object.
166 * @param[in] fwdROPLen Length of vector reserved for fwdROP.
167 * @param fwdROP Output vector containing forward rates of progress of the reactions. Length: nReactions().
168 */
169 int32_t kin_getFwdRatesOfProgress(int32_t handle, int32_t fwdROPLen, double* fwdROP);
170
171 /**
172 * Return the Reverse rates of progress of the reactions.
173 *
174 * Wraps C++ getter: `virtual void Kinetics::getRevRatesOfProgress(span<double>)`
175 *
176 * @param handle Handle to queried Kinetics object.
177 * @param[in] revROPLen Length of vector reserved for revROP.
178 * @param revROP Output vector containing reverse rates of progress of the reactions. Length: nReactions().
179 */
180 int32_t kin_getRevRatesOfProgress(int32_t handle, int32_t revROPLen, double* revROP);
181
182 /**
183 * Net rates of progress.
184 *
185 * Wraps C++ getter: `virtual void Kinetics::getNetRatesOfProgress(span<double>)`
186 *
187 * @param handle Handle to queried Kinetics object.
188 * @param[in] netROPLen Length of vector reserved for netROP.
189 * @param netROP Output vector of the net ROP. Length: nReactions().
190 */
191 int32_t kin_getNetRatesOfProgress(int32_t handle, int32_t netROPLen, double* netROP);
192
193 /**
194 * Get the vector of equilibrium constants in concentration units.
195 *
196 * Wraps C++ getter: `virtual void Kinetics::getEquilibriumConstants(span<double>)`
197 *
198 * @param handle Handle to queried Kinetics object.
199 * @param[in] kcLen Length of vector reserved for kc.
200 * @param[out] kc Vector of equilibrium constants in concentration units; length nReactions().
201 */
202 int32_t kin_getEquilibriumConstants(int32_t handle, int32_t kcLen, double* kc);
203
204 /**
205 * Return the forward rate constants.
206 *
207 * Wraps C++ getter: `virtual void Kinetics::getFwdRateConstants(span<double>)`
208 *
209 * @param handle Handle to queried Kinetics object.
210 * @param[in] kfwdLen Length of vector reserved for kfwd.
211 * @param kfwd Output vector containing the forward reaction rate constants. Length: nReactions().
212 */
213 int32_t kin_getFwdRateConstants(int32_t handle, int32_t kfwdLen, double* kfwd);
214
215 /**
216 * Return the reverse rate constants.
217 *
218 * Wraps C++ method: `virtual void Kinetics::getRevRateConstants(span<double>, bool)`
219 *
220 * @param handle Handle to queried Kinetics object.
221 * @param[in] krevLen Length of vector reserved for krev.
222 * @param krev Output vector of reverse rate constants
223 * @param doIrreversible boolean indicating whether irreversible reactions should be included.
224 */
225 int32_t kin_getRevRateConstants(int32_t handle, int32_t krevLen, double* krev, int32_t doIrreversible);
226
227 /**
228 * Species creation rates [kmol/m^3/s or kmol/m^2/s].
229 *
230 * Wraps C++ getter: `virtual void Kinetics::getCreationRates(span<double>)`
231 *
232 * @param handle Handle to queried Kinetics object.
233 * @param[in] cdotLen Length of vector reserved for cdot.
234 * @param cdot Output vector of creation rates. Length: m_kk.
235 */
236 int32_t kin_getCreationRates(int32_t handle, int32_t cdotLen, double* cdot);
237
238 /**
239 * Species destruction rates [kmol/m^3/s or kmol/m^2/s].
240 *
241 * Wraps C++ getter: `virtual void Kinetics::getDestructionRates(span<double>)`
242 *
243 * @param handle Handle to queried Kinetics object.
244 * @param[in] ddotLen Length of vector reserved for ddot.
245 * @param ddot Output vector of destruction rates. Length: m_kk.
246 */
247 int32_t kin_getDestructionRates(int32_t handle, int32_t ddotLen, double* ddot);
248
249 /**
250 * Species net production rates [kmol/m^3/s or kmol/m^2/s].
251 *
252 * Wraps C++ getter: `virtual void Kinetics::getNetProductionRates(span<double>)`
253 *
254 * @param handle Handle to queried Kinetics object.
255 * @param[in] wdotLen Length of vector reserved for wdot.
256 * @param wdot Output vector of net production rates. Length: m_kk.
257 */
258 int32_t kin_getNetProductionRates(int32_t handle, int32_t wdotLen, double* wdot);
259
260 /**
261 * Calculate derivatives for forward rates-of-progress with respect to temperature at constant pressure, molar concentration and mole fractions.
262 *
263 * Wraps C++ getter: `virtual void Kinetics::getFwdRatesOfProgress_ddT(span<double>)`
264 *
265 * @param handle Handle to queried Kinetics object.
266 * @param[in] dropLen Length of vector reserved for drop.
267 * @param[out] drop Output vector of derivatives. Length: nReactions().
268 */
269 int32_t kin_getFwdRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double* drop);
270
271 /**
272 * Calculate derivatives for forward rates-of-progress with respect to pressure at constant temperature, molar concentration and mole fractions.
273 *
274 * Wraps C++ getter: `virtual void Kinetics::getFwdRatesOfProgress_ddP(span<double>)`
275 *
276 * @param handle Handle to queried Kinetics object.
277 * @param[in] dropLen Length of vector reserved for drop.
278 * @param[out] drop Output vector of derivatives. Length: nReactions().
279 */
280 int32_t kin_getFwdRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double* drop);
281
282 /**
283 * Calculate derivatives for forward rates-of-progress with respect to molar concentration at constant temperature, pressure and mole fractions.
284 *
285 * Wraps C++ getter: `virtual void Kinetics::getFwdRatesOfProgress_ddC(span<double>)`
286 *
287 * @param handle Handle to queried Kinetics object.
288 * @param[in] dropLen Length of vector reserved for drop.
289 * @param[out] drop Output vector of derivatives. Length: nReactions().
290 */
291 int32_t kin_getFwdRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double* drop);
292
293 /**
294 * Calculate derivatives for reverse rates-of-progress with respect to temperature at constant pressure, molar concentration and mole fractions.
295 *
296 * Wraps C++ getter: `virtual void Kinetics::getRevRatesOfProgress_ddT(span<double>)`
297 *
298 * @param handle Handle to queried Kinetics object.
299 * @param[in] dropLen Length of vector reserved for drop.
300 * @param[out] drop Output vector of derivatives. Length: nReactions().
301 */
302 int32_t kin_getRevRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double* drop);
303
304 /**
305 * Calculate derivatives for reverse rates-of-progress with respect to pressure at constant temperature, molar concentration and mole fractions.
306 *
307 * Wraps C++ getter: `virtual void Kinetics::getRevRatesOfProgress_ddP(span<double>)`
308 *
309 * @param handle Handle to queried Kinetics object.
310 * @param[in] dropLen Length of vector reserved for drop.
311 * @param[out] drop Output vector of derivatives. Length: nReactions().
312 */
313 int32_t kin_getRevRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double* drop);
314
315 /**
316 * Calculate derivatives for reverse rates-of-progress with respect to molar concentration at constant temperature, pressure and mole fractions.
317 *
318 * Wraps C++ getter: `virtual void Kinetics::getRevRatesOfProgress_ddC(span<double>)`
319 *
320 * @param handle Handle to queried Kinetics object.
321 * @param[in] dropLen Length of vector reserved for drop.
322 * @param[out] drop Output vector of derivatives. Length: nReactions().
323 */
324 int32_t kin_getRevRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double* drop);
325
326 /**
327 * Calculate derivatives for net rates-of-progress with respect to temperature at constant pressure, molar concentration and mole fractions.
328 *
329 * Wraps C++ getter: `virtual void Kinetics::getNetRatesOfProgress_ddT(span<double>)`
330 *
331 * @param handle Handle to queried Kinetics object.
332 * @param[in] dropLen Length of vector reserved for drop.
333 * @param[out] drop Output vector of derivatives. Length: nReactions().
334 */
335 int32_t kin_getNetRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double* drop);
336
337 /**
338 * Calculate derivatives for net rates-of-progress with respect to pressure at constant temperature, molar concentration and mole fractions.
339 *
340 * Wraps C++ getter: `virtual void Kinetics::getNetRatesOfProgress_ddP(span<double>)`
341 *
342 * @param handle Handle to queried Kinetics object.
343 * @param[in] dropLen Length of vector reserved for drop.
344 * @param[out] drop Output vector of derivatives. Length: nReactions().
345 */
346 int32_t kin_getNetRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double* drop);
347
348 /**
349 * Calculate derivatives for net rates-of-progress with respect to molar concentration at constant temperature, pressure and mole fractions.
350 *
351 * Wraps C++ getter: `virtual void Kinetics::getNetRatesOfProgress_ddC(span<double>)`
352 *
353 * @param handle Handle to queried Kinetics object.
354 * @param[in] dropLen Length of vector reserved for drop.
355 * @param[out] drop Output vector of derivatives. Length: nReactions().
356 */
357 int32_t kin_getNetRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double* drop);
358
359 /**
360 * Calculate derivatives for species creation rates with respect to temperature at constant pressure, molar concentration and mole fractions.
361 *
362 * Wraps C++ getter: `void Kinetics::getCreationRates_ddT(span<double>)`
363 *
364 * @param handle Handle to queried Kinetics object.
365 * @param[in] dwdotLen Length of vector reserved for dwdot.
366 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
367 */
368 int32_t kin_getCreationRates_ddT(int32_t handle, int32_t dwdotLen, double* dwdot);
369
370 /**
371 * Calculate derivatives for species creation rates with respect to pressure at constant temperature, molar concentration and mole fractions.
372 *
373 * Wraps C++ getter: `void Kinetics::getCreationRates_ddP(span<double>)`
374 *
375 * @param handle Handle to queried Kinetics object.
376 * @param[in] dwdotLen Length of vector reserved for dwdot.
377 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
378 */
379 int32_t kin_getCreationRates_ddP(int32_t handle, int32_t dwdotLen, double* dwdot);
380
381 /**
382 * Calculate derivatives for species creation rates with respect to molar concentration at constant temperature, pressure and mole fractions.
383 *
384 * Wraps C++ getter: `void Kinetics::getCreationRates_ddC(span<double>)`
385 *
386 * @param handle Handle to queried Kinetics object.
387 * @param[in] dwdotLen Length of vector reserved for dwdot.
388 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
389 */
390 int32_t kin_getCreationRates_ddC(int32_t handle, int32_t dwdotLen, double* dwdot);
391
392 /**
393 * Calculate derivatives for species destruction rates with respect to temperature at constant pressure, molar concentration and mole fractions.
394 *
395 * Wraps C++ getter: `void Kinetics::getDestructionRates_ddT(span<double>)`
396 *
397 * @param handle Handle to queried Kinetics object.
398 * @param[in] dwdotLen Length of vector reserved for dwdot.
399 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
400 */
401 int32_t kin_getDestructionRates_ddT(int32_t handle, int32_t dwdotLen, double* dwdot);
402
403 /**
404 * Calculate derivatives for species destruction rates with respect to pressure at constant temperature, molar concentration and mole fractions.
405 *
406 * Wraps C++ getter: `void Kinetics::getDestructionRates_ddP(span<double>)`
407 *
408 * @param handle Handle to queried Kinetics object.
409 * @param[in] dwdotLen Length of vector reserved for dwdot.
410 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
411 */
412 int32_t kin_getDestructionRates_ddP(int32_t handle, int32_t dwdotLen, double* dwdot);
413
414 /**
415 * Calculate derivatives for species destruction rates with respect to molar concentration at constant temperature, pressure and mole fractions.
416 *
417 * Wraps C++ getter: `void Kinetics::getDestructionRates_ddC(span<double>)`
418 *
419 * @param handle Handle to queried Kinetics object.
420 * @param[in] dwdotLen Length of vector reserved for dwdot.
421 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
422 */
423 int32_t kin_getDestructionRates_ddC(int32_t handle, int32_t dwdotLen, double* dwdot);
424
425 /**
426 * Calculate derivatives for species net production rates with respect to temperature at constant pressure, molar concentration and mole fractions.
427 *
428 * Wraps C++ getter: `void Kinetics::getNetProductionRates_ddT(span<double>)`
429 *
430 * @param handle Handle to queried Kinetics object.
431 * @param[in] dwdotLen Length of vector reserved for dwdot.
432 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
433 */
434 int32_t kin_getNetProductionRates_ddT(int32_t handle, int32_t dwdotLen, double* dwdot);
435
436 /**
437 * Calculate derivatives for species net production rates with respect to pressure at constant temperature, molar concentration and mole fractions.
438 *
439 * Wraps C++ getter: `void Kinetics::getNetProductionRates_ddP(span<double>)`
440 *
441 * @param handle Handle to queried Kinetics object.
442 * @param[in] dwdotLen Length of vector reserved for dwdot.
443 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
444 */
445 int32_t kin_getNetProductionRates_ddP(int32_t handle, int32_t dwdotLen, double* dwdot);
446
447 /**
448 * Calculate derivatives for species net production rates with respect to molar concentration at constant temperature, pressure and mole fractions.
449 *
450 * Wraps C++ getter: `void Kinetics::getNetProductionRates_ddC(span<double>)`
451 *
452 * @param handle Handle to queried Kinetics object.
453 * @param[in] dwdotLen Length of vector reserved for dwdot.
454 * @param[out] dwdot Output vector of derivatives. Length: m_kk.
455 */
456 int32_t kin_getNetProductionRates_ddC(int32_t handle, int32_t dwdotLen, double* dwdot);
457
458 /**
459 * Dense composition Jacobian d(net production rate)/dX, column-major (n x n).
460 *
461 * Wraps C++ method: `custom code`
462 *
463 * @param handle Handle to queried Kinetics object.
464 * @param bufLen Length of the reserved array; must be at least nTotalSpecies squared.
465 * @param buf Output buffer, filled column-major with the dense Jacobian.
466 */
467 int32_t kin_getNetProductionRates_ddX(int32_t handle, int32_t bufLen, double* buf);
468
469 /**
470 * Dense reaction composition Jacobian d(net rate of progress)/dX, column-major.
471 *
472 * Wraps C++ method: `custom code`
473 *
474 * @param handle Handle to queried Kinetics object.
475 * @param bufLen Length of the reserved array; must be at least nReactions times nTotalSpecies.
476 * @param buf Output buffer, filled column-major with the dense Jacobian.
477 */
478 int32_t kin_getNetRatesOfProgress_ddX(int32_t handle, int32_t bufLen, double* buf);
479
480 /**
481 * The current value of the multiplier for reaction i.
482 *
483 * Wraps C++ method: `double Kinetics::multiplier(size_t)`
484 *
485 * @param handle Handle to queried Kinetics object.
486 * @param i index of the reaction
487 */
488 double kin_multiplier(int32_t handle, int32_t i);
489
490 /**
491 * Set the multiplier for reaction i to f.
492 *
493 * Wraps C++ method: `virtual void Kinetics::setMultiplier(size_t, double)`
494 *
495 * @param handle Handle to queried Kinetics object.
496 * @param i index of the reaction
497 * @param f value of the multiplier.
498 */
499 int32_t kin_setMultiplier(int32_t handle, int32_t i, double f);
500
501 /**
502 * True if reaction i has been declared to be reversible.
503 *
504 * Wraps C++ method: `bool Kinetics::isReversible(size_t)`
505 *
506 * @param handle Handle to queried Kinetics object.
507 * @param i reaction index
508 */
509 int32_t kin_isReversible(int32_t handle, int32_t i);
510
511 /**
512 * Return the index of a species within the phases participating in this kinetic mechanism.
513 *
514 * Wraps C++ method: `custom code`
515 *
516 * Uses:
517 * - ` kineticsSpeciesIndex(const string&, bool)`
518 *
519 * @param handle Handle to queried Kinetics object.
520 * @param nm name of the species
521 */
522 int32_t kin_kineticsSpeciesIndex(int32_t handle, const char* nm);
523
524 /**
525 * Advance the surface coverages in time.
526 *
527 * Wraps C++ setter: `void InterfaceKinetics::advanceCoverages(double)`
528 *
529 * @param handle Handle to queried InterfaceKinetics object.
530 * @param tstep Time value to advance the surface coverages
531 */
532 int32_t kin_advanceCoverages(int32_t handle, double tstep);
533
534 /**
535 * Return the vector of values for the reactions change in enthalpy.
536 *
537 * Wraps C++ getter: `virtual void Kinetics::getDeltaEnthalpy(span<double>)`
538 *
539 * @param handle Handle to queried Kinetics object.
540 * @param[in] deltaHLen Length of vector reserved for deltaH.
541 * @param deltaH Output vector of deltaH's for reactions Length: nReactions().
542 */
543 int32_t kin_getDeltaEnthalpy(int32_t handle, int32_t deltaHLen, double* deltaH);
544
545 /**
546 * Return the vector of values for the reaction Gibbs free energy change.
547 *
548 * Wraps C++ getter: `virtual void Kinetics::getDeltaGibbs(span<double>)`
549 *
550 * @param handle Handle to queried Kinetics object.
551 * @param[in] deltaGLen Length of vector reserved for deltaG.
552 * @param deltaG Output vector of deltaG's for reactions Length: nReactions().
553 */
554 int32_t kin_getDeltaGibbs(int32_t handle, int32_t deltaGLen, double* deltaG);
555
556 /**
557 * Return the vector of values for the reactions change in entropy.
558 *
559 * Wraps C++ getter: `virtual void Kinetics::getDeltaEntropy(span<double>)`
560 *
561 * @param handle Handle to queried Kinetics object.
562 * @param[in] deltaSLen Length of vector reserved for deltaS.
563 * @param deltaS Output vector of deltaS's for reactions Length: nReactions().
564 */
565 int32_t kin_getDeltaEntropy(int32_t handle, int32_t deltaSLen, double* deltaS);
566
567 /**
568 * Return the vector of values for the change in the standard state enthalpies of reaction.
569 *
570 * Wraps C++ getter: `virtual void Kinetics::getDeltaSSEnthalpy(span<double>)`
571 *
572 * @param handle Handle to queried Kinetics object.
573 * @param[in] deltaHLen Length of vector reserved for deltaH.
574 * @param deltaH Output vector of ss deltaH's for reactions Length: nReactions().
575 */
576 int32_t kin_getDeltaSSEnthalpy(int32_t handle, int32_t deltaHLen, double* deltaH);
577
578 /**
579 * Return the vector of values for the reaction standard state Gibbs free energy change.
580 *
581 * Wraps C++ getter: `virtual void Kinetics::getDeltaSSGibbs(span<double>)`
582 *
583 * @param handle Handle to queried Kinetics object.
584 * @param[in] deltaGLen Length of vector reserved for deltaG.
585 * @param deltaG Output vector of ss deltaG's for reactions Length: nReactions().
586 */
587 int32_t kin_getDeltaSSGibbs(int32_t handle, int32_t deltaGLen, double* deltaG);
588
589 /**
590 * Return the vector of values for the change in the standard state entropies for each reaction.
591 *
592 * Wraps C++ getter: `virtual void Kinetics::getDeltaSSEntropy(span<double>)`
593 *
594 * @param handle Handle to queried Kinetics object.
595 * @param[in] deltaSLen Length of vector reserved for deltaS.
596 * @param deltaS Output vector of ss deltaS's for reactions Length: nReactions().
597 */
598 int32_t kin_getDeltaSSEntropy(int32_t handle, int32_t deltaSLen, double* deltaS);
599
600 /**
601 * Delete Kinetics object.
602 *
603 * Wraps C++ destructor: `undefined`
604 *
605 * @param handle Handle to Kinetics object.
606 * @returns Zero for success and -1 for exception handling.
607 */
608 int32_t kin_del(int32_t handle);
609
610 /**
611 * Return size of Kinetics storage.
612 *
613 * Wraps C++ reserved CLib function: `custom code`
614 *
615 * @returns Size or -1 for exception handling.
616 */
617 int32_t kin_cabinetSize();
618
619 /**
620 * @}
621 */
622
623#ifdef __cplusplus
624}
625#endif
626
627#endif // CTKIN_H
int32_t kin_getNetRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for net rates-of-progress with respect to molar concentration at constant tempe...
Definition ctkin.cpp:394
int32_t kin_getDeltaGibbs(int32_t handle, int32_t deltaGLen, double *deltaG)
Return the vector of values for the reaction Gibbs free energy change.
Definition ctkin.cpp:659
int32_t kin_setMultiplier(int32_t handle, int32_t i, double f)
Set the multiplier for reaction i to f.
Definition ctkin.cpp:600
int32_t kin_getRevRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for reverse rates-of-progress with respect to pressure at constant temperature,...
Definition ctkin.cpp:338
int32_t kin_getDestructionRates_ddC(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species destruction rates with respect to molar concentration at constant t...
Definition ctkin.cpp:478
int32_t kin_getNetProductionRates_ddT(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species net production rates with respect to temperature at constant pressu...
Definition ctkin.cpp:492
int32_t kin_del(int32_t handle)
Delete Kinetics object.
Definition ctkin.cpp:729
int32_t kin_reaction(int32_t handle, int32_t i)
Return the Reaction object for reaction i.
Definition ctkin.cpp:69
int32_t kin_getCreationRates_ddT(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species creation rates with respect to temperature at constant pressure,...
Definition ctkin.cpp:408
int32_t kin_nPhases(int32_t handle)
The number of phases participating in the reaction mechanism.
Definition ctkin.cpp:82
int32_t kin_reactionPhase(int32_t handle)
Return pointer to phase where the reactions occur.
Definition ctkin.cpp:105
int32_t kin_getFwdRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for forward rates-of-progress with respect to molar concentration at constant t...
Definition ctkin.cpp:310
double kin_productStoichCoeff(int32_t handle, int32_t k, int32_t i)
Stoichiometric coefficient of species k as a product in reaction i.
Definition ctkin.cpp:147
int32_t kin_getEquilibriumConstants(int32_t handle, int32_t kcLen, double *kc)
Get the vector of equilibrium constants in concentration units.
Definition ctkin.cpp:199
int32_t kin_getRevRatesOfProgress(int32_t handle, int32_t revROPLen, double *revROP)
Return the Reverse rates of progress of the reactions.
Definition ctkin.cpp:171
int32_t kin_getRevRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for reverse rates-of-progress with respect to temperature at constant pressure,...
Definition ctkin.cpp:324
int32_t kin_getDestructionRates(int32_t handle, int32_t ddotLen, double *ddot)
Species destruction rates [kmol/m^3/s or kmol/m^2/s].
Definition ctkin.cpp:254
int32_t kin_getNetProductionRates_ddX(int32_t handle, int32_t bufLen, double *buf)
Dense composition Jacobian d(net production rate)/dX, column-major (n x n).
Definition ctkin.cpp:534
int32_t kin_advanceCoverages(int32_t handle, double tstep)
Advance the surface coverages in time.
Definition ctkin.cpp:634
int32_t kin_getDestructionRates_ddT(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species destruction rates with respect to temperature at constant pressure,...
Definition ctkin.cpp:450
int32_t kin_phase(int32_t handle, int32_t n)
Return pointer to phase associated with Kinetics by index.
Definition ctkin.cpp:92
int32_t kin_getRevRateConstants(int32_t handle, int32_t krevLen, double *krev, int32_t doIrreversible)
Return the reverse rate constants.
Definition ctkin.cpp:227
int32_t kin_getNetProductionRates_ddP(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species net production rates with respect to pressure at constant temperatu...
Definition ctkin.cpp:506
int32_t kin_getDeltaEntropy(int32_t handle, int32_t deltaSLen, double *deltaS)
Return the vector of values for the reactions change in entropy.
Definition ctkin.cpp:673
int32_t kin_getCreationRates_ddP(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species creation rates with respect to pressure at constant temperature,...
Definition ctkin.cpp:422
int32_t kin_getDeltaEnthalpy(int32_t handle, int32_t deltaHLen, double *deltaH)
Return the vector of values for the reactions change in enthalpy.
Definition ctkin.cpp:645
int32_t kin_kineticsType(int32_t handle, int32_t bufLen, char *buf)
Identifies the Kinetics manager type.
Definition ctkin.cpp:47
int32_t kin_getCreationRates(int32_t handle, int32_t cdotLen, double *cdot)
Species creation rates [kmol/m^3/s or kmol/m^2/s].
Definition ctkin.cpp:240
int32_t kin_getNetRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for net rates-of-progress with respect to pressure at constant temperature,...
Definition ctkin.cpp:380
int32_t kin_phaseIndex(int32_t handle, const char *ph)
Return the phase index of a phase in the list of phases defined within the object.
Definition ctkin.cpp:115
int32_t kin_getDeltaSSEnthalpy(int32_t handle, int32_t deltaHLen, double *deltaH)
Return the vector of values for the change in the standard state enthalpies of reaction.
Definition ctkin.cpp:687
int32_t kin_getDeltaSSGibbs(int32_t handle, int32_t deltaGLen, double *deltaG)
Return the vector of values for the reaction standard state Gibbs free energy change.
Definition ctkin.cpp:701
int32_t kin_getNetRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for net rates-of-progress with respect to temperature at constant pressure,...
Definition ctkin.cpp:366
int32_t kin_getFwdRatesOfProgress_ddP(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for forward rates-of-progress with respect to pressure at constant temperature,...
Definition ctkin.cpp:296
int32_t kin_getDestructionRates_ddP(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species destruction rates with respect to pressure at constant temperature,...
Definition ctkin.cpp:464
int32_t kin_getNetProductionRates(int32_t handle, int32_t wdotLen, double *wdot)
Species net production rates [kmol/m^3/s or kmol/m^2/s].
Definition ctkin.cpp:268
double kin_reactantStoichCoeff(int32_t handle, int32_t k, int32_t i)
Stoichiometric coefficient of species k as a reactant in reaction i.
Definition ctkin.cpp:137
int32_t kin_getFwdRatesOfProgress(int32_t handle, int32_t fwdROPLen, double *fwdROP)
Return the forward rates of progress of the reactions.
Definition ctkin.cpp:157
int32_t kin_getDeltaSSEntropy(int32_t handle, int32_t deltaSLen, double *deltaS)
Return the vector of values for the change in the standard state entropies for each reaction.
Definition ctkin.cpp:715
int32_t kin_getNetRatesOfProgress(int32_t handle, int32_t netROPLen, double *netROP)
Net rates of progress.
Definition ctkin.cpp:185
int32_t kin_isReversible(int32_t handle, int32_t i)
True if reaction i has been declared to be reversible.
Definition ctkin.cpp:611
int32_t kin_getNetRatesOfProgress_ddX(int32_t handle, int32_t bufLen, double *buf)
Dense reaction composition Jacobian d(net rate of progress)/dX, column-major.
Definition ctkin.cpp:562
int32_t kin_getNetProductionRates_ddC(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species net production rates with respect to molar concentration at constan...
Definition ctkin.cpp:520
int32_t kin_nTotalSpecies(int32_t handle)
The total number of species in all phases participating in the kinetics mechanism.
Definition ctkin.cpp:127
int32_t kin_nReactions(int32_t handle)
Number of reactions in the reaction mechanism.
Definition ctkin.cpp:59
int32_t kin_kineticsSpeciesIndex(int32_t handle, const char *nm)
Return the index of a species within the phases participating in this kinetic mechanism.
Definition ctkin.cpp:622
int32_t kin_getRevRatesOfProgress_ddC(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for reverse rates-of-progress with respect to molar concentration at constant t...
Definition ctkin.cpp:352
int32_t kin_getFwdRateConstants(int32_t handle, int32_t kfwdLen, double *kfwd)
Return the forward rate constants.
Definition ctkin.cpp:213
int32_t kin_getCreationRates_ddC(int32_t handle, int32_t dwdotLen, double *dwdot)
Calculate derivatives for species creation rates with respect to molar concentration at constant temp...
Definition ctkin.cpp:436
int32_t kin_getFwdRatesOfProgress_ddT(int32_t handle, int32_t dropLen, double *drop)
Calculate derivatives for forward rates-of-progress with respect to temperature at constant pressure,...
Definition ctkin.cpp:282
int32_t kin_cabinetSize()
Return size of Kinetics storage.
Definition ctkin.cpp:740
double kin_multiplier(int32_t handle, int32_t i)
The current value of the multiplier for reaction i.
Definition ctkin.cpp:590