collection of material issues
Moderator: bernd
Forum rules
and Helpful information for the FEM forum
and Helpful information for the FEM forum
collection of material issues
This thread is intended to sort out and fix the different material issues.
List of issues:
1. in the material dialog one cannot load all existing material cards. For example we have already many cards for steel, but they don't appear in the dropdown list. One can also not load them via the material editor because they are not listed anywhere.
-> fixed with https://github.com/FreeCAD/FreeCAD/pull/4646
2. in the material dialog one cannot load a custom/own material card
-> Workaround: Call the material editor from within the material dialog and click there on the button 'Open...'
-> WONTFIX: https://forum.freecadweb.org/viewtopic. ... 12#p532854
3. when you use the material editor and save the data as material card, it is not saved as Unicode. Therefore opening the just created file shows you no content. Here is an example of such a file: https://forum.freecadweb.org/download/f ... ?id=147542
-> fixed by https://github.com/FreeCAD/FreeCAD/commit/cfcf8df4cee1
-> Note: old material cards containing Unicode-only characters can now not be opened anymore as they are. To fix this, open the material cards in a text editor, convert the file to Unicode and save it.
4. in the material editor load an existing standard material like e.g. "PET-generic" you get in the author field "PET-Generic" but in the card it is "(c) 2019 Uwe Stöhr (CC-BY 3.0)"
-> fixed by git commit cfcf8df4cee1
5. call the material editor from the material dialog and load an existing card. Close the editor and see that you don't see the card name in the material dialog. There you see "_transient_material" in the field "Material card"
-> commit that fixed this is unknown
6. call the material editor from the material dialog. Then close the material editor with Cancel, finally close the material dialog with OK.
result: FreeCAD is now in a state in which it thinks there is still a task dialog open. So you cannot reopen the material dialog.
fixed by: git commit 011cef1e7bab
7. Select in the material dialog a material. Then call the material editor from the material dialog and Click on the button "Open".
result: the folder of the already load material is not opened but always this folder "*\data\Mod\Material"
fixed for FreeCAD 0.20.3 by: https://github.com/FreeCAD/FreeCAD/pull/8542
8. Create a fluid material and select as Material card "None". Then change the card to "Air". Now open the material editor from within the material dialog
result: the displayed card is empty
fixed for FreeCAD 0.20.3 by: https://github.com/FreeCAD/FreeCAD/pull/8539
9. Create a fluid material and select as Material card "Nitrogen".
result: you don't get the parameters stored in the Nitrogen.FCMat file
-> fixed by git commit 0afa4bd3441a
10. Launch the material card editor and open the existing Air.FCMat material card. Double-click in the card e.g. on the electric conductivity.
result: the value changes to "0,000000001000 mS/m". Double-click now e.g. an the relative permittivity and this value changes to "100059,000000000000"
This bug only occurs when the FC locale is one in which the comma is the decimal sign.
-> fixed by https://github.com/FreeCAD/FreeCAD/pull/8592
List of issues:
1. in the material dialog one cannot load all existing material cards. For example we have already many cards for steel, but they don't appear in the dropdown list. One can also not load them via the material editor because they are not listed anywhere.
-> fixed with https://github.com/FreeCAD/FreeCAD/pull/4646
2. in the material dialog one cannot load a custom/own material card
-> Workaround: Call the material editor from within the material dialog and click there on the button 'Open...'
-> WONTFIX: https://forum.freecadweb.org/viewtopic. ... 12#p532854
3. when you use the material editor and save the data as material card, it is not saved as Unicode. Therefore opening the just created file shows you no content. Here is an example of such a file: https://forum.freecadweb.org/download/f ... ?id=147542
-> fixed by https://github.com/FreeCAD/FreeCAD/commit/cfcf8df4cee1
-> Note: old material cards containing Unicode-only characters can now not be opened anymore as they are. To fix this, open the material cards in a text editor, convert the file to Unicode and save it.
4. in the material editor load an existing standard material like e.g. "PET-generic" you get in the author field "PET-Generic" but in the card it is "(c) 2019 Uwe Stöhr (CC-BY 3.0)"
-> fixed by git commit cfcf8df4cee1
5. call the material editor from the material dialog and load an existing card. Close the editor and see that you don't see the card name in the material dialog. There you see "_transient_material" in the field "Material card"
-> commit that fixed this is unknown
6. call the material editor from the material dialog. Then close the material editor with Cancel, finally close the material dialog with OK.
result: FreeCAD is now in a state in which it thinks there is still a task dialog open. So you cannot reopen the material dialog.
fixed by: git commit 011cef1e7bab
7. Select in the material dialog a material. Then call the material editor from the material dialog and Click on the button "Open".
result: the folder of the already load material is not opened but always this folder "*\data\Mod\Material"
fixed for FreeCAD 0.20.3 by: https://github.com/FreeCAD/FreeCAD/pull/8542
8. Create a fluid material and select as Material card "None". Then change the card to "Air". Now open the material editor from within the material dialog
result: the displayed card is empty
fixed for FreeCAD 0.20.3 by: https://github.com/FreeCAD/FreeCAD/pull/8539
9. Create a fluid material and select as Material card "Nitrogen".
result: you don't get the parameters stored in the Nitrogen.FCMat file
-> fixed by git commit 0afa4bd3441a
10. Launch the material card editor and open the existing Air.FCMat material card. Double-click in the card e.g. on the electric conductivity.
result: the value changes to "0,000000001000 mS/m". Double-click now e.g. an the relative permittivity and this value changes to "100059,000000000000"
This bug only occurs when the FC locale is one in which the comma is the decimal sign.
-> fixed by https://github.com/FreeCAD/FreeCAD/pull/8592
Last edited by uwestoehr on Tue Sep 14, 2021 10:59 am, edited 11 times in total.
Re: collection of material issues
- I load my file: - I get directly this error:
Code: Select all
Error on reading card data. The card data will be empty for card:
G:/FreeCAD-Simu\Graphite.FCMat
Here is a screencast with the bug:
- Attachments
-
- 10lbV6WSdK.gif (872.91 KiB) Viewed 4605 times
Re: collection of material issues
Here is the material card file I try to load:
Here is the error message from the above screencast:
It tells me "G:/FreeCAD-Simu/Graphite.FCMat not found in known cards" but I have it in my material preferences:
Here is the error message from the above screencast:
Code: Select all
01:38:05 -1
01:38:05 Card path: G:/FreeCAD-Simu/Graphite.FCMat not found in known cards.The material parameter only are loaded.
01:38:05 Traceback (most recent call last):
01:38:05 File "D:\FreeCAD-build\Mod\Material\MaterialEditor.py", line 526, in openfile
01:38:05 d = read(self.card_path)
01:38:05 File "D:\FreeCAD-build\Mod\Material\importFCMat.py", line 117, in read
01:38:05 for ln, line in enumerate(f):
01:38:05 File "D:\FreeCAD-build\bin\lib\codecs.py", line 322, in decode
01:38:05 (result, consumed) = self._buffer_decode(data, self.errors, final)
01:38:05 UnicodeDecodeError: 'utf-8' codec can't decode byte 0xf6 in position 20: invalid start byte
Re: collection of material issues
AFAIR: we added not all cards to the rolling dev version. But at the release all cards should be available without this commit. AFAIKuwestoehr wrote: ↑Sun Mar 21, 2021 8:32 pm This thread is intended to sort out and fix the different material issues.
List of issues:
1. in the material dialog one cannot load all existing material cards. For example we have already many cards for steel, but they don't appear in the dropdown list. One can also not load them via the material editor because they are not listed anywhere.
-> Will be fixed with https://github.com/FreeCAD/FreeCAD/pull/4646
Re: collection of material issues
What I mean is that I e.g. have a card named "Methanol". Since I want to simulate the flow of methanol, I add a liquid material but then cannot load my card. The only way is to load the material editor and there open my card. This is unintuitive because one does not want to edit something, just to load an existing card. Therefore there should be a button to load a custom card in the material dialog.
The steels are in the release but I expect most FEM users to use the rolling release. For example I have to use now the rolling 0.20 release always to benefit from the recent fixes and the Gmsh improvements.bernd wrote: ↑Mon Mar 22, 2021 9:21 amAFAIR: we added not all cards to the rolling dev version. But at the release all cards should be available without this commit. AFAIKuwestoehr wrote: ↑Sun Mar 21, 2021 8:32 pm -> Will be fixed with https://github.com/FreeCAD/FreeCAD/pull/4646
Therefore I don't see a good reason why we have the steel materials only in major releases of FC.
-
- Posts: 991
- Joined: Wed Mar 27, 2019 10:45 am
Re: collection of material issues
I may be on the wrong topic to suggest this, but is there a reason we don't make the cards simply .txt and edit them outside of FreeCAD? (i.e. with an automatic opening of Notepadd++ or the user's preferred text editor selected in the FEM --> Materials preference). The properties would be "searched" by the modules instead of pre-parsed in the GUI and the system would be a lot more flexible.
Don't hesitate to ignore this if you want to keep discussing on pure "material issues".
Don't hesitate to ignore this if you want to keep discussing on pure "material issues".
Re: collection of material issues
I have never use the material edittor to edit the cards either. An simple editor does the job very well for me.
You do not need to change the file ending for this. Just tell your operating system it should open fcmat files with your favorite editor.
The parsing is just for the ability to change them very fast for your need. May be to play with them or whatever. For my work analysises I only use swiss standard code materials for structural steel an concrete.
You do not need to change the file ending for this. Just tell your operating system it should open fcmat files with your favorite editor.
The parsing is just for the ability to change them very fast for your need. May be to play with them or whatever. For my work analysises I only use swiss standard code materials for structural steel an concrete.
Re: collection of material issues
I checked out master with my new material cards for nitrogen and argon and I found 2 new bugs:
8. Create a fluid material and select "None". Then change the card to "Air". Now open the material editor from within the material dialog
result: the displayed card is empty
9. Create a fluid material and select "Nitrogen".
result: you don't get the parameters stored in the Nitrogen.FCMat file
Here a screencast showing both issues:
8. Create a fluid material and select "None". Then change the card to "Air". Now open the material editor from within the material dialog
result: the displayed card is empty
9. Create a fluid material and select "Nitrogen".
result: you don't get the parameters stored in the Nitrogen.FCMat file
Here a screencast showing both issues:
Last edited by uwestoehr on Mon Mar 22, 2021 2:47 pm, edited 1 time in total.