Couldn't load image

3D Modelling

Published on: Monday, 01.29.2024
Languages: Java
Version: 1.0

Available on GitHub ⇱


This application allows you to create, view and interact with three-dimensional objects or structures all in one, window. The GUI was made (again) using JFrames.

When you launch the software, you’ll be on the main screen, where you can render and rotate your created structures. There is also a cube structure as a demo.

Rendering Window

On the left side of the screen, you’ll find the rendering area for the structure. You can rotate it using the buttons at the bottom. To create a new structure, click the ‘+ Create structure’ button in the bottom right corner. To select a structure for rendering, select one in the list and press the ’Render’ button.

Structure-Creator Window

After pressing the ’+ Create structure’ button on the main screen, you’ll find yourself on the Creator screen. On this screen, you have the following options:

  1. Naming Your Structure: Upon entering the creator screen, you’ll see a text field labeled ’Name of the new structure’. Here, you can give your structure a unique name.

  2. Adding Nodes: In this software, I refer to vectors or points as ’Nodes’. To add a Node, locate the field inside the graphical representation of the vector/point. Here, you can type in the coordinates of the Node you wish to add. There will be placeholders for the coordinates to help you.

  3. Creating Relations: To create a structure, you’ll have to add relations between Nodes. Remember, a relation can only be made between two Nodes, otherwise an error will be given out. Once you’ve selected two Nodes, you can create a relation between them.

  4. Deleting Nodes and Relations: If you need to remove a Node or a relation, you can do so by selecting them from their respective lists. Once selected, press the ’Delete’ button located at the bottom of each list.

  5. Test Rendering and Rotation: The software allows you to test render your structure. This means you can view your structure as it would appear when rendered. Additionally, you can rotate your structure around the x, y, and z-axis by 10 degrees, similar to the main screen.

Files:


Couldn't load image

TicTacToe

Published on: Thursday, 08.24.2023
Languages: Java
Version: 1.0

Available on GitHub ⇱


This program allows you to play TicTacToe against a computer on a 3x3 board. The user interface is made using JFrames.

Main screen of the game

On the top right, you can select the level of difficulty. It ranges between: Easy, Normal and Hard. If you have selected a difficulty, you can start the game just by selecting a field and making your first move.

You cannot change the difficulty during a game or restart it. You have to finish the game first.

Finished game (tie)

When the game has ended, it'll be indicated by the 'Reset' button, that appears at the bottom of the screen.


Files:


Couldn't load image

Math Function Calculator

Published on: Monday, 06.12.2023
Languages: Java
Version: 2.0.1

Available on GitHub ⇱


This program lets you calculate and draw a mathematical function. The calculator is array-based. The dashboard and drawing interface are built using JFrames.

When you first launch the JAR-File you’ll find yourself on the dashboard:

Dashboard

In the text field, currently with the text „Type…“ you can type in your function. Not every function is supported e.g. sin, cos are not supported. The function calculator is very limited! In the text field, with the „x = “ on the left, you input the value for x. If you mistakenly entered a character, left the field blank or entered a number with a character, you’ll receive an error message as well.

Dashboard with an error displayed

When the function you've put in is accepted, and you press the 'Draw' button, a drawing window will open, displaying the function.

Function drawer window

Note: the window has a size of 500x500 pixels, resulting in 50x50 blocks.


Files:


Couldn't load image

Alphametic riddle solver

Published on: Monday, 06.12.2023
Languages: Java
Version: 1.0

Available on GitHub ⇱


This is the first program, that I've written even before university. It solves an alphametic math riddle, consisting of three variables: v1, v2 and the solution. It does not support more variables! (see constructor).

Here's an example of an alphametic riddle:


  SEND
+ MORE
-------
  MONEY

To solve those puzzles correctly, we have to follow a certain set of rules:

  1. Every letter type can only be assigned to one specific digit, and vice versa

  2. The digits need to range between 0 and 9

  3. The first letter of each word in the equation cannot be zero

For our given puzzle, the correct solution would be:


  9567
+ 1085
--------
  10652

To solve these puzzles, the program uses two Strings:


private String characters = "";
private String numbers = "";

The String characters holds all the letters from this puzzle. For our example, it would be: characters = "SENDMORY". The String numbers distribute the digits to the letters numbers = "10234567". The numbers are distributed according to the rules above.

Now the software forms the numbers according to the two String variables. If the solution is correct, it'll be passed to the console. If not, a normal number will be made out of the numbers-String and raised by one until, there are no duplicate digits in the String or any first letter has now zero assigned. This happens, until all digits of this number have a value of 9.


Files: