2. pde
torchfsm.pde.Burgers
¤
Burgers(nu: float) -> Operator
Burgers equation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
nu
|
float
|
Viscosity coefficient. |
required |
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Burgers equation. |
Source code in torchfsm/pde.py
19 20 21 22 23 24 25 26 27 28 29 30 31 |
|
torchfsm.pde.KortewegDeVries
¤
KortewegDeVries(
dispersivity: Union[float, Tensor] = -1,
convection_coef: Union[float, Tensor] = 6.0,
) -> Operator
Korteweg-De Vries equation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
dispersivity
|
Union[float, Tensor]
|
Dispersion coefficient. Default is -1. |
-1
|
convection_coef
|
Union[float, Tensor]
|
Convection coefficient. Default is 6.0. |
6.0
|
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Korteweg-De Vries equation. |
Source code in torchfsm/pde.py
149 150 151 152 153 154 155 156 157 158 159 160 161 |
|
torchfsm.pde.KuramotoSivashinsky
¤
KuramotoSivashinsky() -> Operator
1D Kuramoto-Sivashinsky equation
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Kuramoto-Sivashinsky equation. |
Source code in torchfsm/pde.py
33 34 35 36 37 38 39 40 41 42 43 44 45 |
|
torchfsm.pde.KuramotoSivashinskyHighDim
¤
KuramotoSivashinskyHighDim() -> Operator
High dimensional Kuramoto-Sivashinsky equation
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Kuramoto-Sivashinsky equation. |
Source code in torchfsm/pde.py
47 48 49 50 51 52 53 54 55 |
|
torchfsm.pde.NavierStokesVorticity
¤
NavierStokesVorticity(
Re: Union[float, Tensor],
force: Optional[Operator] = None,
) -> Operator
Parameters:
Name | Type | Description | Default |
---|---|---|---|
Re
|
float
|
Reynolds number. |
required |
force
|
Optional[Operator]
|
Optional external force term. Default is None. If provided, it will be added to the vorticity equation. Note that the provided force should be \(\nabla \times \mathbf{f}\) rather than \(\mathbf{f}\) itself. |
None
|
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Navier-Stokes equation in vorticity form. |
Source code in torchfsm/pde.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
|
torchfsm.pde.NavierStokes
¤
NavierStokes(
Re: Union[float, Tensor],
force: Optional[Operator] = None,
) -> Operator
Parameters:
Name | Type | Description | Default |
---|---|---|---|
Re
|
float
|
Reynolds number. |
required |
force
|
Optional[Operator]
|
Optional external force term. Default is None. If provided, it will be added to the vorticity equation. |
None
|
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Navier-Stokes equation. |
Source code in torchfsm/pde.py
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 |
|
torchfsm.pde.GrayScott
¤
GrayScott(
nu_0: Union[float, Tensor],
nu_1: Union[float, Tensor],
feed_rate: Union[float, Tensor],
kill_rate: Union[float, Tensor],
de_aliasing_rate: float = 0.5,
) -> Operator
Gray-Scott equation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
nu_0
|
Union[float, Tensor]
|
Diffusion coefficient for \(\phi_0\). |
required |
nu_1
|
Union[float, Tensor]
|
Diffusion coefficient for \(\phi_1\). |
required |
feed_rate
|
Union[float, Tensor]
|
Feed rate \(f\). |
required |
kill_rate
|
Union[float, Tensor]
|
Kill rate \(k\). |
required |
de_aliasing_rate
|
float
|
De-aliasing rate for the operator. Default is 0.5 due to the cubic nonlinearity. |
0.5
|
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Gray-Scott equation. |
Source code in torchfsm/pde.py
121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 |
|
torchfsm.pde.KPPFisher
¤
KPPFisher(
nu: Union[float, Tensor], r: Union[float, Tensor]
) -> Operator
Fisher-KPP equation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
nu
|
Union[float, Tensor]
|
Diffusion coefficient. |
required |
r
|
Union[float, Tensor]
|
Growth rate. |
required |
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Fisher-KPP equation. |
Source code in torchfsm/pde.py
93 94 95 96 97 98 99 100 101 102 103 104 105 106 |
|
torchfsm.pde.SwiftHohenberg
¤
SwiftHohenberg(r: Union[float, Tensor]) -> Operator
Swift-Hohenberg equation
Parameters:
Name | Type | Description | Default |
---|---|---|---|
r
|
Union[float, Tensor]
|
Control parameter. |
required |
Returns:
Name | Type | Description |
---|---|---|
Operator |
Operator
|
The operator representing the Swift-Hohenberg equation. |
Source code in torchfsm/pde.py
108 109 110 111 112 113 114 115 116 117 118 119 |
|