Skip to content

Commit

Permalink
Fixed layout and added latex math formulas
Browse files Browse the repository at this point in the history
  • Loading branch information
bmike2047 committed Sep 11, 2024
1 parent 61c0b5b commit 66337f4
Show file tree
Hide file tree
Showing 15 changed files with 91 additions and 75 deletions.
18 changes: 10 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,26 @@ First the following assumptions are made:

Ez formula below contain the classic Ia current, space impedance and decreasing with distance r.<br>
The trigonometric terms are caused by the sinusoidal Ia current distribution on the antenna (doughnut shape).<br>
<img src="assets/images/half-dipole2.gif" width="370px">
<img src="src/main/resources/dipole/rf/calculator/images/half-dipole2.gif" width="380">
<br/>

VOC formula below is the Ez*l but because the receiving antenna also has a sinusoidal current distribution it gets multiplied again by the trigonometric terms above.<br/>
This leads to the tan function squared because of the 2 identical dipoles.<br/>
<img src="assets/images/half-dipole3.gif" width="320px">
<img src="src/main/resources/dipole/rf/calculator/images/half-dipole3.gif" width="300">
<br/>

Pload formula below is constructed from converting to rms and perfectly matching the load to the antenna.<br/>
<img src="assets/images/half-dipole4.gif" width="150px">
<img src="src/main/resources/dipole/rf/calculator/images/half-dipole4.gif" width="140">
<br/>

**Verification 1**<br/>
Friis formula below is use to verify all calculations above.<br/>
### Verification 1 ###
Friis formula below is used to verify all calculations above.<br/>
It takes into consideration both dipole's effective aperture area.<br/>
Given freq=2.4GHz, Ptx=36.54W, r=200m our calculator gives Pload=243nW. Using the Friis formula below we also get Prx=243nW.<br>
<img src="assets/images/half-dipole5.gif" width="210px">
<img src="src/main/resources/dipole/rf/calculator/images/half-dipole5.gif" width="200">
<br/>

**Verification 2**<br/>
### Verification 2 ###
CST studio was used to calculate the electric field for freq=2.4GHz, Ptx=36.54W, r=200m.<br/>
This resulted in 0.2989V/m (screenshot below) while our application returned 0.3V/m (see screenshot at the end of this file) which is pretty good for our sinusoidal current distribution approximation.<br/>
![](assets/images/cst.png)
Expand All @@ -67,10 +67,12 @@ For native OS executable run the command below and check folder: ./build/image/b
sudo apt-get install binutils //only for linux
./gradlew clean jlink
```
> [!TIP]
> Math formulas in latex format can be found in file /formulas.tex
> [!TIP]
> I case you have older JDK version than JDK 17 and you are using IntelliJIDEA as IDE make sure Gradle JVM is set to JDK 17 in:<br/>
> File | Settings | Build, Execution, Deployment | Build Tools | Gradle -> Gradle JVM
### Screenshot
![](assets/images/screenshot1.png)
![](assets/images/screenshot.png)
Binary file added assets/images/screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed assets/images/screenshot1.png
Binary file not shown.
15 changes: 15 additions & 0 deletions formulas.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
\documentclass{article}
\begin{document}
\begin{equation}
E_{z}=\frac{-\frac{\mathrm{j}}{2} \eta I_{a} \left(1-\cos \! \left(\frac{k l}{2}\right)\right) {\mathrm e}^{\mathrm{-j} k r}}{\mathrm{\pi} \sin \! \left(\frac{k l}{2}\right) r}
\end{equation}
\begin{equation}
V_{\mathit{OC}}=\frac{\mathrm{j} \eta I_{a} \tan \! \left(\frac{k l}{4}\right)^{2} {\mathrm e}^{\mathrm{-j} k r}}{\mathrm{\pi} k r}
\end{equation}
\begin{equation}
P_{\mathit{load}}=\frac{V_{\mathit{OC}}^{2}}{8 R_{\mathit{rad}}}
\end{equation}
\begin{equation}
P_{\mathit{rx}}=\frac{P_{\mathit{tx}} G_{\mathit{tx}} G_{\mathit{rx}} \lambda^{2}}{16 \mathrm{\pi}^{2} r^{2}}
\end{equation}
\end{document}
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public class CalculatorApplication extends Application {
public void start(Stage stage) throws IOException {
FXMLLoader fxmlLoader = new FXMLLoader(CalculatorApplication.class.getResource("dipole-view.fxml"));
final String dipoleCss = getClass().getResource("css/dipole.css").toExternalForm();
Scene scene = new Scene(fxmlLoader.load(), 900, 725);
Scene scene = new Scene(fxmlLoader.load(), 900, 640);
scene.getStylesheets().add(dipoleCss);
stage.setTitle("Dipole RF Calculator");
stage.setScene(scene);
Expand Down
131 changes: 65 additions & 66 deletions src/main/resources/dipole/rf/calculator/dipole-view.fxml

Large diffs are not rendered by default.

Binary file modified src/main/resources/dipole/rf/calculator/images/half-dipole1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Binary file not shown.
File renamed without changes
Binary file not shown.
File renamed without changes
Binary file not shown.
File renamed without changes
Binary file not shown.

0 comments on commit 66337f4

Please sign in to comment.