MATLAB: Create PDF of Live Script produces broken PDF file

java errorslive scriptMATLABmbp 15" 2017os x high sierrapdf generation

I am running MATLAB 2017a, on a MacBook Pro (2017, 15"), under OS X 10.13.1. When I try to save a Live Script as PDF, I get about 1000 java errors. The PDF is still generated, BUT the PDF file is broken – Acrobat will not open it.
When I open the same Live Script, under the same OS, but on my 2013 MBA, the PDF is generated with a thousand JAVA errors, BUT the PDF is not broken. Adobe Acrobat will open the PDF.
So it would appear that there is some interaction between the new crop of MBPs and MATLAB that is a problem. My MBP is Model Name: MacBook Pro Model Identifier: MacBookPro14,3 Processor Name: Intel Core i7 Processor Speed: 3.1 GHz Number of Processors: 1 Total Number of Cores: 4 L2 Cache (per Core): 256 KB L3 Cache: 8 MB Memory: 16 GB Display: 15.4-inch (2880 x 1800) Graphics: Radeon Pro 560 4 GB …
My version of Java is current. I typically run with an external Thunderbolt display, but that is not the issue – I get the same result on the MBP if I run only the laptop screen.
For me, and I would guess anyone that is trying to use Live Scripts as a way to generate class-ready materials as PDF that this is a significant problem.
I would add – whether a good PDF is generated or not… seeing all those JAVA errors is disconcerting, and puzzling.
Best, —jon—

Best Answer

Martin,
THANKS! Increasing the Java heap size by 50% did correct the problem on the LiveScript I was working with. Since you indicate that this problem was on some machines with the most recent Sierra (which is High Sierra, 10.13.1, I thoought you might want to know more characteristics of my machine. (Below - if more would be useful let me know.)
I really appreciate the responsiveness of the MathWorks in times like this!
---jon---
Hardware Overview:
Model Name: MacBook Pro
Model Identifier: MacBookPro14,3
Processor Name: Intel Core i7
Processor Speed: 3.1 GHz
Number of Processors: 1
Total Number of Cores: 4
L2 Cache (per Core): 256 KB
L3 Cache: 8 MB
Memory: 16 GB
Boot ROM Version: MBP143.0167.B00
SMC Version (system): 2.45f0
Serial Number (system): <snip>
Hardware UUID: <snip>
Video Cards
Intel HD Graphics 630: Chipset Model: Intel HD Graphics 630 Type: GPU Bus: Built-In VRAM (Dynamic, Max): 1536 MB Vendor: Intel Device ID: <snip> Revision ID: 0x0004 Automatic Graphics Switching: Supported gMux Version: 4.0.29 [3.2.8] Metal: Supported, feature set macOS GPUFamily1 v3
Radeon Pro 560: Chipset Model: Radeon Pro 560 Type: GPU Bus: PCIe PCIe Lane Width: x8 VRAM (Total): 4 GB Vendor: AMD (0x1002) Device ID: <snip> Revision ID: 0x00c0 ROM Revision: 113-C980AJ-927 VBIOS Version: 113-C9801AU-A02 EFI Driver Version: 01.00.927 Automatic Graphics Switching: Supported gMux Version: 4.0.29 [3.2.8] Metal: Supported, feature set macOS GPUFamily1 v3 Displays: Color LCD: Display Type: Built-In Retina LCD Resolution: 2880 x 1800 Retina Framebuffer Depth: 30-Bit Color (ARGB2101010) Mirror: Off Online: Yes Rotation: Supported Automatically Adjust Brightness: No Thunderbolt Display: Display Type: LCD Resolution: 2560 x 1440 Framebuffer Depth: 30-Bit Color (ARGB2101010) Display Serial Number: <snip> Main Display: Yes Mirror: Off Online: Yes Rotation: Supported Automatically Adjust Brightness: No Connection Type: DisplayPort
Related Question