Skip to content

Electrostatic solver#149

Merged
gituser789 merged 46 commits into
mainfrom
electrostatic_solver
Jul 8, 2025
Merged

Electrostatic solver#149
gituser789 merged 46 commits into
mainfrom
electrostatic_solver

Conversation

@Abujazar
Copy link
Copy Markdown
Contributor

Implementation of electrostatic solver in FEMMT

abujazar added 30 commits October 16, 2024 13:34
…amples basic_inductor_electrostatic and basic_transformer_electrostatic are examples for electrostatic simulation. The Validation of simulation is existed also with FEMM using femm_reference_electrostatic.
…insulation is added but it is now air material. Also the user can choose the air insulation between the turns in every layer in every winding.
Copy link
Copy Markdown
Contributor

@gituser789 gituser789 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As in the comments

Comment thread .gitignore Outdated
Comment thread .gitignore Outdated
Comment thread .gitignore Outdated
Comment thread femmt/component.py Outdated

- Excitation of the electrostatic problem using voltage or charge source.

:param voltage: Values to apply to each turn in each winding as voltages. Example: [[V_turn_1, V_turn_2], [V_turn_3, V_turn_4]]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you make the example more clear?
i think it is maybe
[[V_winding_1_turn_1, V_winding_1_turn_2], [V_winding_2_turn_1, V_winding_2_turn_2]]
?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/component.py Outdated
Comment thread femmt/model.py Outdated
core_cond: list[
float] # list with size 4x1, with respectively isolation of cond_n -> [top_core, bot_core, left_core, right_core]

turn_ins: list[
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in a sigle line please

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/model.py Outdated
the order conductors are added to the winding! Instead, the winding number is important. The conductors are sorted by ascending winding number.
The lowest winding number therefore is combined with index 0. The second lowest with index 1 and so on.
:type inner_winding_insulation: list[list[float]]
:type inner_winding_insulation: List[List[float]]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use lower list

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/model.py Outdated
self.turn_ins = [0.0 for _ in turn_insulation]

def add_insulation_between_layers(self, add_kapton_material: bool=True, thickness: float = 0.0):
"""Add a kapton between layers"""
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

params and types missing in docstring

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
done

Comment thread femmt/model.py Outdated
else:
self.kapton = thickness
if add_kapton_material:
self.draw_kapton = True
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use another word for kapton

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the new added basic examples regarding the electrostatic simulation should also be executed in test_femmt.py to make sure, that the examples are working

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done u can check the test file

Copy link
Copy Markdown
Contributor

@gituser789 gituser789 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as in the comments

Comment thread femmt/mesh.py Outdated
"""
Set the rectangular electrical insulation between layers.

:param p_iso_layer:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing description

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/mesh.py Outdated
:param p_iso_layer:
:type p_iso_layer: List

:return:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missin description

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/model.py Outdated
self.n_strands = int(conductor_radius ** 2 / strand_radius ** 2 * fill_factor)
elif conductor_radius is None:
self.conductor_radius = np.sqrt(number_strands * strand_radius ** 2 / fill_factor)
print(self.conductor_radius)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use logging.info()

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Comment thread femmt/model.py Outdated
# this is the default-case
self.r_outer = fr.calculate_r_outer(self.core_inner_diameter, self.window_w)

# bobbin dimensions
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no code has been added?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the line is deleted

"Turn_4": 2.666067960159697e-11,
"Turn_5": 5.998652910359316e-11,
"Turn_6": 2.399461164143728e-10,
"Turn_7": Infinity
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From where does this "Infinity" occur?

@gituser789 gituser789 merged commit ee34a70 into main Jul 8, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants